Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I'm trying to compile an open source driver for my new USB Rosewill RNX-MiniN2 wireless adapter, and I'm running into the following error:

make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/3.0.0-14-generic/build M=/home/rfkrocktk/Desktop/RTL8192CU_8188CUS_8188CE-VAU_linux_v3.1.2590.20110922/driver/rtl8192_8188CU_linux_v3.1.2590.20110922  modules
make[1]: Entering directory `/usr/src/linux-headers-3.0.0-14-generic'
  CC [M]  /home/rfkrocktk/Desktop/RTL8192CU_8188CUS_8188CE-VAU_linux_v3.1.2590.20110922/driver/rtl8192_8188CU_linux_v3.1.2590.20110922/core/rtw_cmd.o
In file included from /home/rfkrocktk/Desktop/RTL8192CU_8188CUS_8188CE-VAU_linux_v3.1.2590.20110922/driver/rtl8192_8188CU_linux_v3.1.2590.20110922/core/rtw_cmd.c:24:0:
/home/rfkrocktk/Desktop/RTL8192CU_8188CUS_8188CE-VAU_linux_v3.1.2590.20110922/driver/rtl8192_8188CU_linux_v3.1.2590.20110922/include/osdep_service.h:49:29: fatal error: linux/smp_lock.h: No such file or directory
compilation terminated.
make[2]: *** [/home/rfkrocktk/Desktop/RTL8192CU_8188CUS_8188CE-VAU_linux_v3.1.2590.20110922/driver/rtl8192_8188CU_linux_v3.1.2590.20110922/core/rtw_cmd.o] Error 1
make[1]: *** [_module_/home/rfkrocktk/Desktop/RTL8192CU_8188CUS_8188CE-VAU_linux_v3.1.2590.20110922/driver/rtl8192_8188CU_linux_v3.1.2590.20110922] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.0.0-14-generic'
make: *** [modules] Error 2
Compile make driver error: 2, Please check error Mesg

Evidently, due to recent kernel changes, smp_lock.h doesn't exist anymore.

How can I kludge this together and make it work? I just paid for this USB stick and I'd like to be able to use it and not have to ship it back.

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

Just needed to create a fake smp_lock.h file in /usr/src/linux-headers-$(uname -r)/include/linux/:

sudo touch "/usr/src/linux-headers-$(uname -r)/include/linux/smp_lock.h

It works!

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.