Skip to contentSkip to conversation

2.4.23-pre7 build problems

DISCUSSION Eyal Lebedinsky 4 participants 4 messages Oct 10, 2003 – Oct 11, 2003

lore
Share & tools
lore
#0 lore raw

I dropped off the list for a few days so am not sure what was already reported, neither did I find anything in the archives about -pre7.

already reported:

gcc -D__KERNEL__ -I/data2/usr/local/src/linux-2.4-pre/include -Wall -Wstrict-pro
totypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -fomit-frame-pointer
-pipe -mpreferred-stack-boundary=2 -march=i686 -malign-functions=4
-DMODULE -DM
ODVERSIONS -include /data2/usr/local/src/linux-2.4-pre/include/linux/modversions .h -nostdinc -iwithprefix include -DKBUILD_BASENAME=megaraid2 -c -o megaraid2.
o megaraid2.c
megaraid2.c: In function `mega_find_card':
megaraid2.c:403: structure has no member named `lock' make[2]: *** [megaraid2.o] Error 1
make[2]: Leaving directory `/data2/usr/local/src/linux-2.4-pre/drivers/scsi'

no report found:

gcc -D__KERNEL__ -I/data2/usr/local/src/linux-2.4-pre/include -Wall -Wstrict-pro
totypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -fomit-frame-pointer
-pipe -mpreferred-stack-boundary=2 -march=i686 -malign-functions=4
-DMODULE -DM
ODVERSIONS -include /data2/usr/local/src/linux-2.4-pre/include/linux/modversions .h -nostdinc -iwithprefix include -DKBUILD_BASENAME=nsp32 -c -o nsp32.o nsp32.
c
In file included from nsp32.c:56:
nsp32.h:645: redefinition of `irqreturn_t' /data2/usr/local/src/linux-2.4-pre/include/linux/interrupt.h:16:
`irqreturn_t' previously declared here
make[2]: *** [nsp32.o] Error 1
make[2]: Leaving directory `/data2/usr/local/src/linux-2.4-pre/drivers/scsi'

--
Eyal Lebedinsky ([email protected]) <http://samba.org/eyal/>

#1 lore raw

Hi !

Quoted 5 lines

megaraid2.c: In function `mega_find_card':
megaraid2.c:403: structure has no member named `lock' make[2]: *** [megaraid2.o] Error 1
make[2]: Leaving directory `/data2/usr/local/src/linux-2.4-pre/drivers/scsi'

wouldn't this patch fix it ? : megaraid-2009-wo-hostlock.patch

megaraid2.c +1 -3
diff -Naur megaraid-2009/megaraid2.c megaraid-2009-wo-hostlock/megaraid2.c
@@ -398,9 +398,7 @@
 		// replace adapter->lock with io_request_lock for kernels w/o
 		// per host lock and delete the line which tries to initialize
 		// the lock in host structure.
-		adapter->host_lock = &adapter->lock;
-
-		host->lock = adapter->host_lock;
+		adapter->host_lock = &io_request_lock;
 
 		host->cmd_per_lun = max_cmd_per_lun;
 		host->max_sectors = max_sectors_per_io;
Quoted 7 lines

In file included from nsp32.c:56:
nsp32.h:645: redefinition of `irqreturn_t' /data2/usr/local/src/linux-2.4-pre/include/linux/interrupt.h:16:
`irqreturn_t' previously declared here
make[2]: *** [nsp32.o] Error 1
make[2]: Leaving directory `/data2/usr/local/src/linux-2.4-pre/drivers/scsi'

looking though pre6-pre7 changes, it seems as other drivers backported from 2.5 might be affected too :
- qla1280 (typedef)
- net2280 (#define)

The clear should be to simply remove the local definition from the driver. Willy

#2 lore raw
In reply to Eyal Lebedinsky
Quoted 2 lines · Eyal Lebedinsky

I dropped off the list for a few days so am not sure what was already reported, neither did I find anything in the archives about -pre7.

I have the fix for the nsp driver but not for the megaraid2.

Please stop using [email protected]. Use my new email address.

#3 lore raw
Quoted 1 line

I have the fix for the nsp driver but not for the megaraid2.

ftp://ftp.lsil.com/pub/linux-megaraid/drivers/version-2.00.9/megaraid-2009-wo-hostlock.patch.gz ftp://ftp.lsil.com/pub/linux-megaraid/drivers/version-2.00.9/megaraid-2009-wo-hostlock.patch.gz.sig

and appended. Done by Atul Mukker @ LSIL.

Signature · 19 lines
Matt Domsch
Sr. Software Engineer, Lead Engineer
Dell Linux Solutions www.dell.com/linux
Linux on Dell mailing lists @ http://lists.us.dell.com

diff -Naur linux/drivers/scsi/megaraid2.c linux/drivers/scsi/megaraid2.c
--- linux/drivers/scsi/megaraid2.c	2003-09-09 15:31:43.000000000 -0400
+++ linux/drivers/scsi/megaraid2.c	2003-09-09 15:32:03.000000000 -0400
@@ -398,9 +398,7 @@
 		// replace adapter->lock with io_request_lock for kernels w/o
 		// per host lock and delete the line which tries to initialize
 		// the lock in host structure.
-		adapter->host_lock = &adapter->lock;
-
-		host->lock = adapter->host_lock;
+		adapter->host_lock = &io_request_lock;
 
 		host->cmd_per_lun = max_cmd_per_lun;
 		host->max_sectors = max_sectors_per_io;