OK, so I got this far, although I stuffed two patches in the middle (which I should probably pull to the beginning and did this one patch differently.
I've not really tested the result yet, will attempt to do so tomorrow. Please have a look at the current state of things here: git://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git locking/core