On Fri, 11 Feb 2005, Brad Boyer wrote:

On Sat, Feb 12, 2005 at 04:04:49PM +1100, Finn Thain wrote:
Having finally looked at the definition of the __devexit_p macro, it seems
to me that the release method is supposed to be a null pointer. So
Noah's patch is not the problem at all, but it is not the entire solution
either. This patch is needed as well.

I'm not sure this will get accepted in the mainline. In one sense, it's the right fix, because the release function being NULL only matters in the module case. However, it seems kind of messy.

Yes. Here is another way, which is cleaner since there's no need for a run-time test in some cases.



--- linux-2.6.10/drivers/scsi/scsi_module.c 2004-12-25 08:34:29.000000000 +1100 +++ /Volumes/Linux/btc/build/linux-2.6.10/drivers/scsi/scsi_module.c 2005-02-13 20:45:33.677591385 +1100 @@ -21,12 +21,14 @@ struct list_head *l; int error;

+#if defined(MODULE) || defined(CONFIG_HOTPLUG)
        if (!sht->release) {
                printk(KERN_ERR
                    "scsi HBA driver %s didn't set a release method.\n",
                    sht->name);
                return -EINVAL;
        }
+#endif

        sht->module = THIS_MODULE;
        INIT_LIST_HEAD(&sht->legacy_hosts);
-
To unsubscribe from this list: send the line "unsubscribe linux-m68k" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to