lkml.org 
[lkml]   [2003]   [Aug]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
SubjectRe: [PATCH] PCI fixes for 2.6.0-test3
From
Date
ChangeSet 1.1123.21.2, 2003/08/13 17:42:56-07:00, janiceg@us.ibm.com

[PATCH] PCI: testing for probe errors in pci-driver.c

Currently if __pci_device_probe locates the correct
device driver, but receives an error from the static
drv->probe function, this error is not reported.

The attached patch reports the above error condition
to the caller. Only when a match for the device in
the static tables is not found, is the dynamic driver
table searched.


drivers/pci/pci-driver.c | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)


diff -Nru a/drivers/pci/pci-driver.c b/drivers/pci/pci-driver.c
--- a/drivers/pci/pci-driver.c Thu Aug 21 10:22:52 2003
+++ b/drivers/pci/pci-driver.c Thu Aug 21 10:22:52 2003
@@ -122,10 +122,8 @@

if (!pci_dev->driver && drv->probe) {
error = pci_device_probe_static(drv, pci_dev);
- if (error >= 0)
- return error;
-
- error = pci_device_probe_dynamic(drv, pci_dev);
+ if (error == -ENODEV)
+ error = pci_device_probe_dynamic(drv, pci_dev);
}
return error;
}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:47    [W:0.271 / U:0.124 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site