From 4152605ea174291f469c0c8a6fc433fd90194e71 Mon Sep 17 00:00:00 2001 From: Jon Smirl Date: Wed, 22 Jun 2005 05:49:56 +0000 Subject: Get the power management hooks into the right place so that everything gets freed correctly. --- linux-core/drm_stub.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'linux-core/drm_stub.c') diff --git a/linux-core/drm_stub.c b/linux-core/drm_stub.c index cb6d6c69..2f9a2c32 100644 --- a/linux-core/drm_stub.c +++ b/linux-core/drm_stub.c @@ -67,9 +67,6 @@ static int fill_in_dev(drm_device_t * dev, struct pci_dev *pdev, dev->pdev = pdev; - if (drm_fb_loaded) - drm_pm_setup( dev ); - #ifdef __alpha__ dev->hose = pdev->sysdata; dev->pci_domain = dev->hose->bus->number; @@ -97,6 +94,10 @@ static int fill_in_dev(drm_device_t * dev, struct pci_dev *pdev, dev->driver = driver; + if (drm_fb_loaded) + if ((retcode = drm_pm_setup( dev ))) + goto error_out_unreg; + if (dev->driver->preinit) if ((retcode = dev->driver->preinit(dev, ent->driver_data))) goto error_out_unreg; -- cgit v1.2.3