patch-2.4.3 linux/drivers/scsi/AM53C974.c

Next file: linux/drivers/scsi/ChangeLog.ncr53c8xx
Previous file: linux/drivers/scsi/3w-xxxx.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.2/linux/drivers/scsi/AM53C974.c linux/drivers/scsi/AM53C974.c
@@ -676,6 +676,10 @@
 #endif
 
 	instance = scsi_register(tpnt, sizeof(struct AM53C974_hostdata));
+	if (!instance) {
+		printk(KERN_WARNING "AM53C974: Unable to register host, aborting.\n");
+		return 0;
+	}
 	hostdata = (struct AM53C974_hostdata *) instance->hostdata;
 	instance->base = 0;
 	instance->io_port = pci_resource_start(pdev, 0);

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)