patch-2.3.22 linux/drivers/scsi/aha152x.c

Next file: linux/drivers/scsi/dec_esp.c
Previous file: linux/drivers/scsi/Config.in
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.21/linux/drivers/scsi/aha152x.c linux/drivers/scsi/aha152x.c
@@ -344,6 +344,8 @@
 #include <linux/ioport.h>
 #include <linux/proc_fs.h>
 #include <linux/interrupt.h>
+#include <linux/init.h>
+#include <linux/kernel.h>
 
 #include "aha152x.h"
 #include <linux/stat.h>
@@ -714,6 +716,7 @@
 	}
 }
 
+#if 0
 /* called from init/main.c */
 void aha152x_setup(char *str, int *ints)
 {
@@ -742,6 +745,29 @@
 	} else
 		setup_count++;
 }
+#endif
+
+static int __init do_aha152x_setup (char * str)
+{
+	if (setup_count > 2) {
+		printk(KERN_ERR"aha152x: you can only configure up to two
+controllers\n");
+	return 0;
+	}
+
+	setup[setup_count].conf = str;
+	get_option(&str,&setup[setup_count].io_port);
+	get_option(&str,&setup[setup_count].irq);
+	get_option(&str,&setup[setup_count].scsiid);
+	get_option(&str,&setup[setup_count].reconnect);
+	
+	setup_count++;
+	return 1;
+}
+
+#ifndef MODULE
+__setup("aha152x=",do_aha152x_setup);
+#endif
 
 /*
  * Test, if port_base is valid.

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