Skip to contentSkip to conversation

2.4.23-pre8: link error with both megaraid drivers

PATCH In review Xose Vazquez Perez 2 participants 3 messages Oct 23, 2003 – Oct 24, 2003 SCSI

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 2.4.23-pre8: link error with both megaraid drivers

Quoted 2 lines · Adrian Bunk

The patch below fixes this issue by disalllowing the static inclusion of both drivers at the same time.

IMO this patch makes a better job. It only allows one in kernel, and it allows two modules at same time.

xconfig and menuconfig work ok.

-thanks-
--
HTML mails are going to trash automatically

drivers/scsi/Config.in +8 -2
@@ -66,8 +66,14 @@
 dep_tristate 'AdvanSys SCSI support' CONFIG_SCSI_ADVANSYS $CONFIG_SCSI
 dep_tristate 'Always IN2000 SCSI support' CONFIG_SCSI_IN2000 $CONFIG_SCSI
 dep_tristate 'AM53/79C974 PCI SCSI support' CONFIG_SCSI_AM53C974 $CONFIG_SCSI $CONFIG_PCI
-dep_tristate 'AMI MegaRAID support' CONFIG_SCSI_MEGARAID $CONFIG_SCSI
-dep_tristate 'AMI MegaRAID2 support' CONFIG_SCSI_MEGARAID2 $CONFIG_SCSI
+
+if [ "$CONFIG_SCSI_MEGARAID2" != "y" ]; then
+	dep_tristate 'AMI MegaRAID support' CONFIG_SCSI_MEGARAID $CONFIG_SCSI
+fi
+
+if [ "$CONFIG_SCSI_MEGARAID" != "y" ]; then
+	dep_tristate 'AMI MegaRAID2 support' CONFIG_SCSI_MEGARAID2 $CONFIG_SCSI
+fi
 
 dep_tristate 'BusLogic SCSI support' CONFIG_SCSI_BUSLOGIC $CONFIG_SCSI
 if [ "$CONFIG_SCSI_BUSLOGIC" != "n" ]; then
#1 lore raw
Quoted 8 lines · Xose Vazquez Perez
Quoted 2 lines · Adrian Bunk

The patch below fixes this issue by disalllowing the static inclusion of both drivers at the same time.

IMO this patch makes a better job. It only allows one in kernel, and it allows two modules at same time.
...

My patch allows this, too, or what did I miss?

Quoted 11 lines
(quoted diff) +0 -1
-thanks-
drivers/scsi/Config.in +1 -2
@@ -66,8 +66,14 @@
 dep_tristate 'AdvanSys SCSI support' CONFIG_SCSI_ADVANSYS $CONFIG_SCSI
 dep_tristate 'Always IN2000 SCSI support' CONFIG_SCSI_IN2000 $CONFIG_SCSI
 dep_tristate 'AM53/79C974 PCI SCSI support' CONFIG_SCSI_AM53C974 $CONFIG_SCSI $CONFIG_PCI
-dep_tristate 'AMI MegaRAID support' CONFIG_SCSI_MEGARAID $CONFIG_SCSI
-dep_tristate 'AMI MegaRAID2 support' CONFIG_SCSI_MEGARAID2 $CONFIG_SCSI
+

drivers/scsi/Config.in line 79

Quoted 10 lines
drivers/scsi/Config.in +7 -0
+if [ "$CONFIG_SCSI_MEGARAID2" != "y" ]; then
+	dep_tristate 'AMI MegaRAID support' CONFIG_SCSI_MEGARAID $CONFIG_SCSI
+fi
+
+if [ "$CONFIG_SCSI_MEGARAID" != "y" ]; then
+	dep_tristate 'AMI MegaRAID2 support' CONFIG_SCSI_MEGARAID2 $CONFIG_SCSI
+fi
 
 dep_tristate 'BusLogic SCSI support' CONFIG_SCSI_BUSLOGIC $CONFIG_SCSI
 if [ "$CONFIG_SCSI_BUSLOGIC" != "n" ]; then

The difference between your and my patch is that your patch doesn't allow one in kernel plus the other one modular.

cu
Adrian

Signature · 4 lines
       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed
#2 lore raw
Quoted 6 lines · Adrian Bunk
Quoted 2 lines · Xose Vazquez Perez

IMO this patch makes a better job. It only allows one in kernel, and it allows two modules at same time.

My patch allows this, too, or what did I miss?

Nothing. But your patch adds too much complex code to do a single thing ;-)

Quoted 2 lines

The difference between your and my patch is that your patch doesn't allow one in kernel plus the other one modular.

Yes. And IMO there is not need to build a module when you get the other statically inside the kernel. I can not imagine what will happen if one is statically inside the kernel and someone try to load a module :-)

--
HTML mails are going to trash automatically