summaryrefslogtreecommitdiff
path: root/drivers/char/agp
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2012-06-07 13:55:58 (GMT)
committerDaniel Vetter <daniel.vetter@ffwll.ch>2012-06-12 20:18:54 (GMT)
commit7e8f6306fe155d6fc3fe99d666be95b4ed24427d (patch)
tree34ab363540937a898b828e05e48fbd6667f77491 /drivers/char/agp
parentdd2757f8b557ab2030154896eac9b2285557dda6 (diff)
downloadlinux-7e8f6306fe155d6fc3fe99d666be95b4ed24427d.tar.xz
agp/intel-gtt: don't require the agp bridge on setup
We only need it to fake the agp interface and don't actually use it in the driver anywhere. Hence conditionalize that. This is just a prep patch to eventually disable the fake agp driver on gen6+. Reviewed-by: Jani Nikula <jani.nikula@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/char/agp')
-rw-r--r--drivers/char/agp/intel-gtt.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/char/agp/intel-gtt.c b/drivers/char/agp/intel-gtt.c
index 2aab0a0..5e6c89e 100644
--- a/drivers/char/agp/intel-gtt.c
+++ b/drivers/char/agp/intel-gtt.c
@@ -1539,9 +1539,11 @@ int intel_gmch_probe(struct pci_dev *pdev,
if (!intel_private.driver)
return 0;
- bridge->driver = &intel_fake_agp_driver;
- bridge->dev_private_data = &intel_private;
- bridge->dev = pdev;
+ if (bridge) {
+ bridge->driver = &intel_fake_agp_driver;
+ bridge->dev_private_data = &intel_private;
+ bridge->dev = pdev;
+ }
intel_private.bridge_dev = pci_dev_get(pdev);