summaryrefslogtreecommitdiff
path: root/linux-core
diff options
context:
space:
mode:
authorJesse Barnes <jbarnes@hobbes.virtuousgeek.org>2007-04-12 18:30:36 -0700
committerJesse Barnes <jbarnes@hobbes.virtuousgeek.org>2007-04-12 18:30:36 -0700
commit9f0f6509f5278b5d46a282acf40e7b69790892a6 (patch)
treee73154539e1ee749cee07b6bd444d2e91319be29 /linux-core
parent79b7a588bb685459d51527e7ac6877696fe392a3 (diff)
Move driver load call to after AGP init, in case the load routine needs AGP stuff.
Diffstat (limited to 'linux-core')
-rw-r--r--linux-core/drm_stub.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/linux-core/drm_stub.c b/linux-core/drm_stub.c
index f4da7dac..13652ebd 100644
--- a/linux-core/drm_stub.c
+++ b/linux-core/drm_stub.c
@@ -113,10 +113,6 @@ static int drm_fill_in_dev(drm_device_t * dev, struct pci_dev *pdev,
dev->driver = driver;
- if (dev->driver->load)
- if ((retcode = dev->driver->load(dev, ent->driver_data)))
- goto error_out_unreg;
-
if (drm_core_has_AGP(dev)) {
if (drm_device_is_agp(dev))
dev->agp = drm_agp_init(dev);
@@ -136,6 +132,11 @@ static int drm_fill_in_dev(drm_device_t * dev, struct pci_dev *pdev,
}
}
+
+ if (dev->driver->load)
+ if ((retcode = dev->driver->load(dev, ent->driver_data)))
+ goto error_out_unreg;
+
retcode = drm_ctxbitmap_init(dev);
if (retcode) {
DRM_ERROR("Cannot allocate memory for context bitmap.\n");