Re: [PATCH] cpqarray update

From: Hollis Blanchard
Date: Wed Jan 28 2004 - 11:13:55 EST


On Jan 26, 2004, at 2:15 PM, Jeff Garzik wrote:

Linux Kernel Mailing List wrote:
ChangeSet 1.1288, 2004/01/26 16:58:21-02:00, francis.wiran@xxxxxx
@@ -616,7 +623,7 @@
/* detect controllers */
printk(DRIVER_NAME "\n");
- pci_register_driver(&cpqarray_pci_driver);
+ pci_module_init(&cpqarray_pci_driver);
cpqarray_eisa_detect();
for(i=0; i< MAX_CTLR; i++) {

You need to check the return value of pci_module_init() for errors.

I'm defining a new bus and had copied pci_module_init() to vio_module_init(). Here's what Greg KH had to say about that:
Eeek! I want to fix that code in pci_module_init() so it doesn't do
this at all. Please don't copy that horrible function. Just register
the driver with a call to vio_register_driver() and drop the whole
vio_module_init() completly. I'll be doing that for pci soon, and
there's no reason you want to duplicate this broken logic (you always
want your module probe to succeed, for lots of reasons...)

So there's no need for the quoted patch hunk at all.

--
Hollis Blanchard
IBM Linux Technology Center

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/