LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   help compiling drivers for HPT RocketRaid 2720 on 3.8 (https://www.linuxquestions.org/questions/linux-hardware-18/help-compiling-drivers-for-hpt-rocketraid-2720-on-3-8-a-4175453307/)

nickgw 03-08-2013 02:43 PM

help compiling drivers for HPT RocketRaid 2720 on 3.8
 
Hi, I'm trying to build a driver for the Highpoint RR 2720 on the new Linux kernel 3.8

I've downloaded the drivers from the highpoint site: http://highpoint-tech.com/USA_new/pr...pport_sas6.htm (I used the Linux Open Source 1.4 driver.) I had the card working on 3.5.0-21 but now when I run make the makefile yells at me saying it only works on 2.4, 2.6 and 3.0 ...

Anybody have any expertise or can I provide some more info?

Thanks!

Ser Olmy 03-08-2013 05:10 PM

The problematic code is in rr272x_1x-linux-src-v1.4/inc/linux_64mpa/Makefile.def. It's supposed to detect the major and minor kernel versions, but it depends on a kernel header file called "version.h" which no longer exists.

It's possible to work around that problem but there are a few other incompatibilities as well. Unless someone knowledgeable updates the source code, the driver just won't compile.

nickgw 03-08-2013 05:13 PM

Thanks for the reply. If I modified makefile.def to not check for the header version, would it build (albeit not necessarily correctly)? I did get it to build for 3.5, but I don't remember exactly what mods I made to get it to work...

Ser Olmy 03-08-2013 05:19 PM

You can fudge the version detection by manually defining KERNEL_VER_MAJOR and KERNEL_VER_MINOR in Makefile.def.

I tried compiling under 3.7.3 and got this:
Code:

  CC [M]  /usr/src/rr272x_1x-linux-src-v1.4/product/rr272x/linux/.build/os_linux.o
/usr/src/rr272x_1x-linux-src-v1.4/product/rr272x/linux/.build/os_linux.c: In function 'os_kmap_sgptr':
/usr/src/rr272x_1x-linux-src-v1.4/product/rr272x/linux/.build/os_linux.c:206:31: error: 'KM_BIO_SRC_IRQ' undeclared (first use in this function)
/usr/src/rr272x_1x-linux-src-v1.4/product/rr272x/linux/.build/os_linux.c:206:31: note: each undeclared identifier is reported only once for each function it appears in
/usr/src/rr272x_1x-linux-src-v1.4/product/rr272x/linux/.build/os_linux.c:206:5: error: too many arguments to function 'kmap_atomic'
In file included from include/linux/highmem.h:34:0,
                from include/linux/pagemap.h:10,
                from include/linux/blkdev.h:13,
                from /usr/src/rr272x_1x-linux-src-v1.4/osm/linux/osm_linux.h:61,
                from /usr/src/rr272x_1x-linux-src-v1.4/product/rr272x/linux/.build/os_linux.c:6:
/usr/src/linux-3.7.3/arch/x86/include/asm/highmem.h:64:7: note: declared here
/usr/src/rr272x_1x-linux-src-v1.4/product/rr272x/linux/.build/os_linux.c: In function 'os_kunmap_sgptr':
/usr/src/rr272x_1x-linux-src-v1.4/product/rr272x/linux/.build/os_linux.c:216:35: error: macro "kunmap_atomic" passed 2 arguments, but takes just 1
/usr/src/rr272x_1x-linux-src-v1.4/product/rr272x/linux/.build/os_linux.c:216:3: error: 'kunmap_atomic' undeclared (first use in this function)
make[2]: *** [/usr/src/rr272x_1x-linux-src-v1.4/product/rr272x/linux/.build/os_linux.o] Error 1
make[1]: *** [_module_/usr/src/rr272x_1x-linux-src-v1.4/product/rr272x/linux/.build] Error 2
make[1]: Leaving directory `/usr/src/linux-3.7.3'
make: *** [rr272x_1x.ko] Error 2


nickgw 03-08-2013 05:21 PM

fudge... Can I take the compiled driver from 3.5.0-21 and use it in 3.8 without recompiling? I see it in /lib/modules/3.5.0-21-generic/kernel/driver/scsi/ but I think I need to apply it to initrd, which I'm unsure of...

Ser Olmy 03-08-2013 05:33 PM

You could try, but it's not very likely to work. If you can successfully insmod the old module in a more recent kernel, it could be worth a shot.


All times are GMT -5. The time now is 09:06 AM.