All of lore.kernel.org
 help / color / mirror / Atom feed
* [patch] 2.4.23-pre8: link error with both megaraid drivers
@ 2003-10-23 15:27 Xose Vazquez Perez
  2003-10-23 19:52 ` Adrian Bunk
  0 siblings, 1 reply; 6+ messages in thread
From: Xose Vazquez Perez @ 2003-10-23 15:27 UTC (permalink / raw)
  To: Marcelo Tosatti, linux-kernel, linux-scsi

[-- Attachment #1: Type: text/plain, Size: 324 bytes --]

Adrian Bunk wrote:

> 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

[-- Attachment #2: config-megaraid.diff --]
[-- Type: text/plain, Size: 906 bytes --]

--- linux/drivers/scsi/Config.in	2003-10-23 16:56:13.000000000 +0200
+++ new/drivers/scsi/Config.in	2003-10-23 17:00:51.000000000 +0200
@@ -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


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [patch] 2.4.23-pre8: link error with both megaraid drivers
  2003-10-23 15:27 [patch] 2.4.23-pre8: link error with both megaraid drivers Xose Vazquez Perez
@ 2003-10-23 19:52 ` Adrian Bunk
  2003-10-24  3:27   ` Xose Vazquez Perez
  0 siblings, 1 reply; 6+ messages in thread
From: Adrian Bunk @ 2003-10-23 19:52 UTC (permalink / raw)
  To: Xose Vazquez Perez; +Cc: Marcelo Tosatti, linux-kernel, linux-scsi

On Thu, Oct 23, 2003 at 05:27:25PM +0200, Xose Vazquez Perez wrote:
> Adrian Bunk wrote:
> 
> > 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?

> -thanks-
> 
> --- linux/drivers/scsi/Config.in	2003-10-23 16:56:13.000000000 +0200
> +++ new/drivers/scsi/Config.in	2003-10-23 17:00:51.000000000 +0200
> @@ -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

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

cu
Adrian

-- 

       "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


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [patch] 2.4.23-pre8: link error with both megaraid drivers
  2003-10-23 19:52 ` Adrian Bunk
@ 2003-10-24  3:27   ` Xose Vazquez Perez
  0 siblings, 0 replies; 6+ messages in thread
From: Xose Vazquez Perez @ 2003-10-24  3:27 UTC (permalink / raw)
  To: Adrian Bunk; +Cc: Marcelo Tosatti, linux-kernel, linux-scsi

Adrian Bunk wrote:

> On Thu, Oct 23, 2003 at 05:27:25PM +0200, Xose Vazquez Perez wrote:

>> 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 ;-)

> 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


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [patch] 2.4.23-pre8: link error with both megaraid drivers
  2003-10-23 14:18   ` Matthew Wilcox
@ 2003-10-23 19:42     ` Adrian Bunk
  0 siblings, 0 replies; 6+ messages in thread
From: Adrian Bunk @ 2003-10-23 19:42 UTC (permalink / raw)
  To: Matthew Wilcox; +Cc: Marcelo Tosatti, Matt Domsch, linux-scsi, linux-kernel

On Thu, Oct 23, 2003 at 03:18:12PM +0100, Matthew Wilcox wrote:
> On Thu, Oct 23, 2003 at 04:07:43PM +0200, Adrian Bunk wrote:
> > --- linux-2.4.23-pre7-full/drivers/scsi/Config.in.old	2003-10-11 17:00:47.000000000 +0200
> > +++ linux-2.4.23-pre7-full/drivers/scsi/Config.in	2003-10-11 17:24:00.000000000 +0200
> > -dep_tristate 'AMI MegaRAID2 support' CONFIG_SCSI_MEGARAID2 $CONFIG_SCSI
> > +if [ "$CONFIG_SCSI_MEGARAID" != "y" ]; then
> > +  define_tristate CONFIG_SCSI_MEGARAID2_DEP $CONFIG_SCSI
> > +else
> > +  define_tristate CONFIG_SCSI_MEGARAID2_DEP m $CONFIG_SCSI
> > +fi
> > +dep_tristate 'AMI MegaRAID2 support' CONFIG_SCSI_MEGARAID2 $CONFIG_SCSI_MEGARAID2_DEP
> 
> define_tristate?!  Did you actually try this?

Yes, I tried it.

What exactly isn't working for you?

cu
Adrian

-- 

       "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


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [patch] 2.4.23-pre8: link error with both megaraid drivers
  2003-10-23 14:07 ` [patch] 2.4.23-pre8: link error with both megaraid drivers Adrian Bunk
@ 2003-10-23 14:18   ` Matthew Wilcox
  2003-10-23 19:42     ` Adrian Bunk
  0 siblings, 1 reply; 6+ messages in thread
From: Matthew Wilcox @ 2003-10-23 14:18 UTC (permalink / raw)
  To: Adrian Bunk; +Cc: Marcelo Tosatti, Matt Domsch, linux-scsi, linux-kernel

On Thu, Oct 23, 2003 at 04:07:43PM +0200, Adrian Bunk wrote:
> --- linux-2.4.23-pre7-full/drivers/scsi/Config.in.old	2003-10-11 17:00:47.000000000 +0200
> +++ linux-2.4.23-pre7-full/drivers/scsi/Config.in	2003-10-11 17:24:00.000000000 +0200
> -dep_tristate 'AMI MegaRAID2 support' CONFIG_SCSI_MEGARAID2 $CONFIG_SCSI
> +if [ "$CONFIG_SCSI_MEGARAID" != "y" ]; then
> +  define_tristate CONFIG_SCSI_MEGARAID2_DEP $CONFIG_SCSI
> +else
> +  define_tristate CONFIG_SCSI_MEGARAID2_DEP m $CONFIG_SCSI
> +fi
> +dep_tristate 'AMI MegaRAID2 support' CONFIG_SCSI_MEGARAID2 $CONFIG_SCSI_MEGARAID2_DEP

define_tristate?!  Did you actually try this?

-- 
"It's not Hollywood.  War is real, war is primarily not about defeat or
victory, it is about death.  I've seen thousands and thousands of dead bodies.
Do you think I want to have an academic debate on this subject?" -- Robert Fisk

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [patch] 2.4.23-pre8: link error with both megaraid drivers
  2003-10-22 23:24 Linux 2.4.23-pre8 Marcelo Tosatti
@ 2003-10-23 14:07 ` Adrian Bunk
  2003-10-23 14:18   ` Matthew Wilcox
  0 siblings, 1 reply; 6+ messages in thread
From: Adrian Bunk @ 2003-10-23 14:07 UTC (permalink / raw)
  To: Marcelo Tosatti, Matt Domsch, linux-scsi; +Cc: linux-kernel

On Wed, Oct 22, 2003 at 09:24:17PM -0200, Marcelo Tosatti wrote:
>...
> Summary of changes from v2.4.23-pre7 to v2.4.23-pre8
> ============================================
>...
> Matt Domsch:
>   o Fix megaraid2 compilation problems
>...

Trying to compile both megaraid drivers statically into the kernel still 
fails with the following link error:

<--  snip  -->

...
ld -m elf_i386  -r -o scsidrv.o scsi_mod.o sim710.o advansys.o pci2000.o 
pci2220i.o psi240i.o BusLogic.o dpt_i2o.o u14-34f.o ultrastor.o aha152x.o 
aha1542.o aha1740.o aacraid/aacraid.o aic7xxx/aic7xxx.o aic7xxx/aic79xx.o ips.o 
fd_mcs.o fdomain.o in2000.o g_NCR5380.o NCR53c406a.o NCR_D700.o 53c700.o sym53c416.o 
qlogicfas.o qlogicisp.o qlogicfc.o qla1280.o pas16.o seagate.o t128.o dmx3191d.o 
dtc.o 53c7,8xx.o sym53c8xx_2/sym53c8xx_2.o eata_dma.o eata_pio.o wd7000.o 
NCR53C9x.o mca_53c9x.o ibmmca.o eata.o tmscsim.o AM53C974.o megaraid.o megaraid2.o 
atp870u.o gdth.o initio.o a100u2w.o ide-scsi.o 3w-xxxx.o ppa.o imm.o scsi_debug.o 
cpqfc.o nsp32.o st.o osst.o sd_mod.o sr_mod.o sg.o
megaraid2.o(.text+0x1ff0): In function `megaraid_info':
: multiple definition of `megaraid_info'
megaraid.o(.text+0x29f8): first defined here
ld: Warning: size of symbol `megaraid_info' changed from 67 in 
megaraid.o to 57 in megaraid2.o
make[3]: *** [scsidrv.o] Error 1
make[3]: Leaving directory `/home/bunk/linux/kernel-2.4/linux/kernel-2.4/linux-2.4.23-pre8-full/drivers/scsi'

<--  snip  -->

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

cu
Adrian

--- linux-2.4.23-pre7-full/drivers/scsi/Config.in.old	2003-10-11 17:00:47.000000000 +0200
+++ linux-2.4.23-pre7-full/drivers/scsi/Config.in	2003-10-11 17:24:00.000000000 +0200
@@ -67,7 +67,12 @@
 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_MEGARAID" != "y" ]; then
+  define_tristate CONFIG_SCSI_MEGARAID2_DEP $CONFIG_SCSI
+else
+  define_tristate CONFIG_SCSI_MEGARAID2_DEP m $CONFIG_SCSI
+fi
+dep_tristate 'AMI MegaRAID2 support' CONFIG_SCSI_MEGARAID2 $CONFIG_SCSI_MEGARAID2_DEP
 
 dep_tristate 'BusLogic SCSI support' CONFIG_SCSI_BUSLOGIC $CONFIG_SCSI
 if [ "$CONFIG_SCSI_BUSLOGIC" != "n" ]; then

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2003-10-24  8:26 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-10-23 15:27 [patch] 2.4.23-pre8: link error with both megaraid drivers Xose Vazquez Perez
2003-10-23 19:52 ` Adrian Bunk
2003-10-24  3:27   ` Xose Vazquez Perez
  -- strict thread matches above, loose matches on Subject: below --
2003-10-22 23:24 Linux 2.4.23-pre8 Marcelo Tosatti
2003-10-23 14:07 ` [patch] 2.4.23-pre8: link error with both megaraid drivers Adrian Bunk
2003-10-23 14:18   ` Matthew Wilcox
2003-10-23 19:42     ` Adrian Bunk

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.