From b2232cae46573dddde16ad4c7a326c3379aebfeb Mon Sep 17 00:00:00 2001 From: Kulikov Vasiliy Date: Tue, 3 Aug 2010 19:42:30 +0400 Subject: [PATCH] --- yaml --- r: 205187 b: refs/heads/master c: 46cfc58a77de5fc8385ad87077f4dc14633e57a7 h: refs/heads/master i: 205185: b6d33465c39fdaf97b7d571403473f89519334ec 205183: 2b2bbeedcf7a18f1d26579cc6e75f35d5277a906 v: v3 --- [refs] | 2 +- trunk/drivers/char/agp/efficeon-agp.c | 22 +++++++++++----------- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/[refs] b/[refs] index cf4a1f27acf0..cfc4a9c06458 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 58374713c9dfb4d231f8c56cac089f6fbdedc2ec +refs/heads/master: 46cfc58a77de5fc8385ad87077f4dc14633e57a7 diff --git a/trunk/drivers/char/agp/efficeon-agp.c b/trunk/drivers/char/agp/efficeon-agp.c index aa109cbe0e6e..d607f53d8afc 100644 --- a/trunk/drivers/char/agp/efficeon-agp.c +++ b/trunk/drivers/char/agp/efficeon-agp.c @@ -371,6 +371,17 @@ static int __devinit agp_efficeon_probe(struct pci_dev *pdev, bridge->dev = pdev; bridge->capndx = cap_ptr; + /* + * If the device has not been properly setup, the following will catch + * the problem and should stop the system from crashing. + * 20030610 - hamish@zot.org + */ + if (pci_enable_device(pdev)) { + printk(KERN_ERR PFX "Unable to Enable PCI device\n"); + agp_put_bridge(bridge); + return -ENODEV; + } + /* * The following fixes the case where the BIOS has "forgotten" to * provide an address range for the GART. @@ -385,17 +396,6 @@ static int __devinit agp_efficeon_probe(struct pci_dev *pdev, } } - /* - * If the device has not been properly setup, the following will catch - * the problem and should stop the system from crashing. - * 20030610 - hamish@zot.org - */ - if (pci_enable_device(pdev)) { - printk(KERN_ERR PFX "Unable to Enable PCI device\n"); - agp_put_bridge(bridge); - return -ENODEV; - } - /* Fill in the mode register */ if (cap_ptr) { pci_read_config_dword(pdev,