Ian (and others), here's a three-patch series that uses the doubly linked list to do your mlock() case hopefully correctly. NOTE! It's untested. The first patch (which is the slightly scary one) is tested to some degree, the two other ones I checked that they compile, but that's it. I'm not going to apply them to my main tree unless they get testing and acks. And as mentioned, I've not done any of the changes that having a vm_prev pointer can allow in other places. Comments? Fixes? Braindamage? Linus