1

I am trying to build the kernel module for Ubuntu 13.04 but not having any luck, I have had this card working perfectly fine with 12.10 and the 3.5.0-27-generic kernel but since upgrading to 13.04 none of the new kernels will build the module.

# dkms build rr2680/1.9 -k 3.8.0-25-generic

Kernel preparation unnecessary for this kernel.  Skipping...

Building module:
cleaning build area....
make KERNELRELEASE=3.8.0-25-generic -C product/rr2680/linux/ KERNELDIR=/lib/modules/3.8.0-25-generic/build....(bad exit status: 2)
ERROR (dkms apport): binary package for rr2680: 1.9 not found
Error! Bad return status for module build on kernel: 3.8.0-25-generic (x86_64)
Consult /var/lib/dkms/rr2680/1.9/build/make.log for more information.

Here is make.log:

DKMS make.log for rr2680-1.9 for kernel 3.8.0-25-generic (x86_64)
Fri Jun 14 22:09:56 CST 2013
grep: /lib/modules/3.8.0-25-generic/build/include/linux/version.h: No such file or directory
expr: syntax error
grep: /lib/modules/3.8.0-25-generic/build/include/linux/version.h: No such file or directory
expr: syntax error
make: Entering directory `/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux'
../../../inc/linux_32mpa/Makefile.def:87: *** Only kernel 2.4/2.6/3.x is supported but you use ..  Stop.
make: Leaving directory `/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux'

How I built the module in 12.10: http://www.sudoseth.com/blog/2013/01/highpoint-raid-we-meet-again/

Does anyone have some pointers?

The first answer helped a bit but not over the hill, I swapped $(KERNELDIR)/include/linux/version.h for $(KERNELDIR)/include/generated/uapi/linux/version.h which then produced this error:

DKMS make.log for rr2680-1.9 for kernel 3.8.0-26-generic (x86_64)
Mon Jul  8 14:55:11 CST 2013
make: Entering directory `/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux'
make[1]: Entering directory `/usr/src/linux-headers-3.8.0-26-generic'
CC [M]  /var/lib/dkms/rr2680/1.9/build/product/rr2680/linux/.build/os_linux.o
CC [M]  /var/lib/dkms/rr2680/1.9/build/product/rr2680/linux/.build/osm_linux.o
/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux/.build/osm_linux.c: In function ‘scsicmd_buf_get’:
/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux/.build/osm_linux.c:452:39: error: ‘KM_BIO_SRC_IRQ’ undeclared (first use in this function)
/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux/.build/osm_linux.c:452:39: note: each undeclared identifier is reported only once for each function it appears in
/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux/.build/osm_linux.c:452:2: error: too many arguments to function ‘kmap_atomic’
In file included from include/linux/pagemap.h:10:0,
from include/linux/blkdev.h:13,
from /var/lib/dkms/rr2680/1.9/build/osm/linux/osm_linux.h:61,
from /var/lib/dkms/rr2680/1.9/build/product/rr2680/linux/.build/osm_linux.c:6:
include/linux/highmem.h:66:21: note: declared here
/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux/.build/osm_linux.c: In function ‘scsicmd_buf_put’:
/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux/.build/osm_linux.c:482:55: error: macro "kunmap_atomic" passed 2 arguments, but takes just 1
/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux/.build/osm_linux.c:482:2: error: ‘kunmap_atomic’ undeclared (first use in this function)
make[2]: *** [/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux/.build/osm_linux.o] Error 1
make[1]: *** [_module_/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux/.build] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.8.0-26-generic'
make: *** [rr2680.ko] Error 2
make: Leaving directory `/var/lib/dkms/rr2680/1.9/build/product/rr2680/linux'

Cheers!

2 Answers2

1

Got the same problem with my rr2320! It seems like the location of version.h file has changed. But changing that line in the Makefile to the new location (/lib/modules/3.8.0-25-generic/build/include/generated/uapi/linux/version.h) doesn't do the trick.

Found a solution for my problem! Have a look here: Updated Highpoint RocketRAID 2230 patch.

slm
  • 7,615
  • 16
  • 56
  • 76
Oliver
  • 11
  • 2
  • Thanks for the hint, that patch changes a bunch of stuff which seems very specific to your 2230 card. I updated the question as it did help out a bit. – Sam Hamilton Jul 08 '13 at 07:16
1

The answer can be found here: http://ubuntuforums.org/showthread.php?t=2158769&p=12746043 The short answer is you need to remove the second parameter passed to 'kmap_atomic'. These are all the constant 'HPT_KMAP_TYPE'. The function is called in osm_linux.c and os_linux.c and HPT_KMAP_TYPE is defined in osm_linux.h, this can be removed also.

logan
  • 26
  • 1