[Intel-gfx] [PATCH] drm/i915: don't check intel_agp_enabled any more
Daniel Vetter
daniel.vetter at ffwll.ch
Tue Jun 12 13:24:05 CEST 2012
We won't enabled agp unconditionally. Furthermore we do have
the right checks for agp support in place in our ->load
function.
The only thing this variable still does is enforce the module
load order we want (and I'm not even sure whether it succeeds
for that). Hence just use it in a harmless place somewhere.
v2: Fixup rebase.
Signed-off-by: Daniel Vetter <daniel.vetter at ffwll.ch>
---
drivers/gpu/drm/i915/i915_dma.c | 6 +++++-
drivers/gpu/drm/i915/i915_drv.c | 6 ------
2 files changed, 5 insertions(+), 7 deletions(-)
diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c
index a8f8477..6290aea 100644
--- a/drivers/gpu/drm/i915/i915_dma.c
+++ b/drivers/gpu/drm/i915/i915_dma.c
@@ -1404,6 +1404,8 @@ i915_mtrr_setup(struct drm_i915_private *dev_priv, unsigned long base,
}
}
+extern int intel_agp_enabled;
+
/**
* i915_driver_load - setup chip and create an initial config
* @dev: DRM device
@@ -1451,7 +1453,9 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags)
goto free_priv;
if (!dev->agp) {
- DRM_ERROR("Cannot initialize the agpgart module.\n");
+ DRM_ERROR("Cannot initialize the agpgart module,"
+ "intel_agp_enabled: %i.\n",
+ intel_agp_enabled);
ret = -EINVAL;
goto free_priv;
}
diff --git a/drivers/gpu/drm/i915/i915_drv.c b/drivers/gpu/drm/i915/i915_drv.c
index 3390213..e4df5a0 100644
--- a/drivers/gpu/drm/i915/i915_drv.c
+++ b/drivers/gpu/drm/i915/i915_drv.c
@@ -119,7 +119,6 @@ MODULE_PARM_DESC(i915_enable_ppgtt,
"Enable PPGTT (default: true)");
static struct drm_driver driver;
-extern int intel_agp_enabled;
#define INTEL_VGA_DEVICE(id, info) { \
.class = PCI_BASE_CLASS_DISPLAY << 16, \
@@ -1093,11 +1092,6 @@ static struct pci_driver i915_pci_driver = {
static int __init i915_init(void)
{
- if (!intel_agp_enabled) {
- DRM_ERROR("drm/i915 can't work without intel_agp module!\n");
- return -ENODEV;
- }
-
driver.num_ioctls = i915_max_ioctl;
/*
--
1.7.7.6
More information about the Intel-gfx
mailing list