Welcome, Guest

Author Topic: Unknown symbol mutex_lock_interruptible  (Read 3268 times)

Chris

  • Newbie
  • *
  • Posts: 28
  • Karma: +0/-0
Unknown symbol mutex_lock_interruptible
« on: September 28, 2015, 08:03:43 PM »
I'm stuck with a stange kernel error. I successfully built a wifi driver for my rtl8188eu, but it won't load:
Code: [Select]
>insmod 8188eu.ko
Error: could not insert module 8188eu.ko: Unknown symbol in module

>dmesg | tail -n 1
8188eu: Unknown symbol mutex_lock_interruptible (err 0)

AFAIK mutex_lock_interruptible is a kernel function (defined in kernel/locking/mutex.c) since 2.6.x and I'm driving a 4.1.4 kernel (and verified that mutex_lock_interruptible is still existing there). Why the f*** does the driver not find that symbol?? :o
« Last Edit: September 28, 2015, 08:20:05 PM by Chris »

MBR

  • Sr. Member
  • ****
  • Posts: 256
  • Karma: +19/-0
Re: Unknown symbol mutex_lock_interruptible
« Reply #1 on: September 29, 2015, 04:51:43 AM »
Probably the mutex_lock_interruptible function was replaced by someting new, maybe during the Big Kernel Lock removal or someting like that (there was a lot of kernel development between 2.6.x and 4.1.x). There is almost surely a function which does the same work, but with a different name.

I am not a kernel programmer (I wrote some simple device drivers, but in the distant mists of age of kernel 2.4 :-) ), but it seems that the the mutex_lock_interruptible was replacetd by mutex_lock_interruptible_nested, try looking into the krenel header file include/linux/mutex.h for more informations.

BTW: Are you including the right set of kernel include files? If I read the header files correctly, the old name-new name transitions is corrected by a macro, so if you include the right set, the symbols should be automagicaly changed to mutex_lock_interruptible_nested.

Chris

  • Newbie
  • *
  • Posts: 28
  • Karma: +0/-0
Re: Unknown symbol mutex_lock_interruptible
« Reply #2 on: September 29, 2015, 08:48:13 PM »
Thanks for your kind advice - yes, the linux headers caused the problem. I used prebuilt headers downloaded from the archlinuxarm repository - probably not compatible. Now I use the headers from my own kernel build, and get no more unknown symbols.
So it's always a good idea to only trust what you have built by yourself!  ;)
« Last Edit: September 30, 2015, 01:41:21 AM by Chris »