NixOS/nixpkgs — pull request #2090 by thoughtpolice (2014-04-01 06:23:21+00:00)
Title: kernel: remove 3.11 series (EOL'd), add new lockdep tool from Linux 3.14

This kills the now-EOL'd 3.11 series, and adds an awesome new userspace tool called `lockdep` for validation of user-space locks, based on the kernel implementation.

As a demo:

```
$ nix-build -A linuxPackages_3_14.lockdep
...
$ cat > test1.c
#include

void main(void)
{
pthread_mutex_t a;

pthread_mutex_init(&a, NULL);

pthread_mutex_lock(&a);
pthread_mutex_unlock(&a);
pthread_mutex_unlock(&a);
}
$ gcc test1.c
$ ./result/bin/lockdep ./a.out
0x7f31e37c49d0

=====================================
[ BUG: bad unlock balance detected! ]
liblockdep 0.0.1
-------------------------------------
a.out/25692 is trying to release lock (0x7fff1eca7470) at:
./a.out() [0x4006a9]
but there are no more locks to release!

other info that might help us debug this:
no locks held by a.out/25692.

stack backtrace:
/nix/store/nyn7zxklxhmq7ddmcm0vmnxb0h9k4ani-lockdep-linux-3.14/lib/liblockdep.so(+0x2648)[0x7f31e3da3648]
/nix/store/nyn7zxklxhmq7ddmcm0vmnxb0h9k4ani-lockdep-linux-3.14/lib/liblockdep.so(+0x59a0)[0x7f31e3da69a0]
/nix/store/nyn7zxklxhmq7ddmcm0vmnxb0h9k4ani-lockdep-linux-3.14/lib/liblockdep.so(+0x59f5)[0x7f31e3da69f5]
/nix/store/nyn7zxklxhmq7ddmcm0vmnxb0h9k4ani-lockdep-linux-3.14/lib/liblockdep.so(+0x60f0)[0x7f31e3da70f0]
/nix/store/nyn7zxklxhmq7ddmcm0vmnxb0h9k4ani-lockdep-linux-3.14/lib/liblockdep.so(lock_release+0x56)[0x7f31e3da7331]
/nix/store/nyn7zxklxhmq7ddmcm0vmnxb0h9k4ani-lockdep-linux-3.14/lib/liblockdep.so(pthread_mutex_unlock+0x39)[0x7f31e3da8282]
./a.out[0x4006a9]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf5)[0x7f31e39fade5]
./a.out[0x400599]
```