@@ -331,11 +331,11 @@ MODULE_LICENSE("GPL");
#if !defined(PCMCIA)
#if defined(MODULE)
static int io[] = {0, 0};
-module_param_array(io, int, NULL, 0);
+module_param_hw_array(io, int, ioport, NULL, 0);
MODULE_PARM_DESC(io,"base io address of controller");
static int irq[] = {0, 0};
-module_param_array(irq, int, NULL, 0);
+module_param_hw_array(irq, int, irq, NULL, 0);
MODULE_PARM_DESC(irq,"interrupt for controller");
static int scsiid[] = {7, 7};
@@ -31,7 +31,7 @@ module_param(isapnp, bool, 0);
MODULE_PARM_DESC(isapnp, "enable PnP support (default=1)");
static int io[MAXBOARDS] = { 0x330, 0x334, 0, 0 };
-module_param_array(io, int, NULL, 0);
+module_param_hw_array(io, int, ioport, NULL, 0);
MODULE_PARM_DESC(io, "base IO address of controller (0x130,0x134,0x230,0x234,0x330,0x334, default=0x330,0x334)");
/* time AHA spends on the AT-bus during data transfer */
@@ -75,6 +75,7 @@
#include <scsi/scsi_host.h>
#include "g_NCR5380.h"
#include "NCR5380.h"
+#include <linux/module.h>
#include <linux/stat.h>
#include <linux/init.h>
#include <linux/ioport.h>
@@ -174,6 +175,9 @@ static int __init do_NCR5380_setup(char *str)
{
int ints[10];
+ if (secure_modules())
+ return -EPERM;
+
get_options(str, ARRAY_SIZE(ints), ints);
internal_setup(BOARD_NCR5380, str, ints);
return 1;
@@ -192,6 +196,9 @@ static int __init do_NCR53C400_setup(char *str)
{
int ints[10];
+ if (secure_modules())
+ return -EPERM;
+
get_options(str, ARRAY_SIZE(ints), ints);
internal_setup(BOARD_NCR53C400, str, ints);
return 1;
@@ -210,6 +217,9 @@ static int __init do_NCR53C400A_setup(char *str)
{
int ints[10];
+ if (secure_modules())
+ return -EPERM;
+
get_options(str, ARRAY_SIZE(ints), ints);
internal_setup(BOARD_NCR53C400A, str, ints);
return 1;
@@ -228,6 +238,9 @@ static int __init do_DTC3181E_setup(char *str)
{
int ints[10];
+ if (secure_modules())
+ return -EPERM;
+
get_options(str, ARRAY_SIZE(ints), ints);
internal_setup(BOARD_DTC3181E, str, ints);
return 1;
@@ -717,9 +730,9 @@ static struct scsi_host_template driver_template = {
#include <linux/module.h>
#include "scsi_module.c"
-module_param(ncr_irq, int, 0);
+module_param_hw(ncr_irq, int, irq, 0);
module_param(ncr_dma, int, 0);
-module_param(ncr_addr, int, 0);
+module_param_hw(ncr_addr, int, ioport, 0);
module_param(ncr_5380, int, 0);
module_param(ncr_53c400, int, 0);
module_param(ncr_53c400a, int, 0);
@@ -353,7 +353,7 @@ static int probe_eisa_isa = 0;
static int force_dma32 = 0;
/* parameters for modprobe/insmod */
-module_param_array(irq, int, NULL, 0);
+module_param_hw_array(irq, int, irq, NULL, 0);
module_param(disable, int, 0);
module_param(reserve_mode, int, 0);
module_param_array(reserve_list, int, NULL, 0);
@@ -137,8 +137,8 @@ err:
static struct qlogicfas408_priv *cards;
static int iobase[MAX_QLOGICFAS];
static int irq[MAX_QLOGICFAS] = { [0 ... MAX_QLOGICFAS-1] = -1 };
-module_param_array(iobase, int, NULL, 0);
-module_param_array(irq, int, NULL, 0);
+module_param_hw_array(iobase, int, ioport, NULL, 0);
+module_param_hw_array(irq, int, irq, NULL, 0);
MODULE_PARM_DESC(iobase, "I/O address");
MODULE_PARM_DESC(irq, "IRQ");