]> git.karo-electronics.de Git - karo-tx-linux.git/commit
brlocks/lglocks: cleanups
authorAndi Kleen <ak@linux.intel.com>
Thu, 3 May 2012 05:43:29 +0000 (15:43 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Thu, 3 May 2012 05:46:20 +0000 (15:46 +1000)
commitdcea7e20d7e450dab660a6693f7acd1d25995e24
treea01351cf13bd8b8d44050fba9066cc8cf1beb491
parentc94d5e4d07ac4a10ebbb3ec4a6333ed030b75eb1
brlocks/lglocks: cleanups

lglocks and brlocks are currently generated with some complicated macros
in lglock.h.  But there's no reason to not just use common utility
functions and put all the data into a common data structure.

Since there are at least two users it makes sense to share this code in a
library.  This is also easier maintainable than a macro forest.

This will also make it later possible to dynamically allocate lglocks and
also use them in modules (this would both still need some additional, but
now straightforward, code)

In general the users now look more like normal function calls with
pointers, not magic macros.

The patch is rather large because I move over all users in one go to keep
it bisectable.  This impacts the VFS somewhat in terms of lines changed.
But no actual behaviour change.

[akpm@linux-foundation.org: checkpatch fixes]
[levinsasha928@gmail.com: fix dup_mnt_ns()]
Signed-off-by: Andi Kleen <ak@linux.intel.com>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Sasha Levin <levinsasha928@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
fs/dcache.c
fs/file_table.c
fs/internal.h
fs/namei.c
fs/namespace.c
fs/pnode.c
fs/proc_namespace.c
include/linux/lglock.h
kernel/Makefile
kernel/lglock.c [new file with mode: 0644]