diff options
author | Vadim Lobanov <vlobanov@speakeasy.net> | 2006-12-22 04:10:43 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.osdl.org> | 2006-12-22 11:55:50 -0500 |
commit | 01b2d93ca4c495f056471189ac6c4e6ac4cbbccb (patch) | |
tree | 86aa1aabae8207e693e31ee68b526376388a36a3 /fs/file.c | |
parent | 31fccf7fe4097e62f038bdfe8f4f68ecaea8ebe7 (diff) |
[PATCH] fdtable: Provide free_fdtable() wrapper
Christoph Hellwig has expressed concerns that the recent fdtable changes
expose the details of the RCU methodology used to release no-longer-used
fdtable structures to the rest of the kernel. The trivial patch below
addresses these concerns by introducing the appropriate free_fdtable()
calls, which simply wrap the release RCU usage. Since free_fdtable() is a
one-liner, it makes sense to promote it to an inline helper.
Signed-off-by: Vadim Lobanov <vlobanov@speakeasy.net>
Cc: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/file.c')
-rw-r--r-- | fs/file.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -206,7 +206,7 @@ static int expand_fdtable(struct files_struct *files, int nr) | |||
206 | copy_fdtable(new_fdt, cur_fdt); | 206 | copy_fdtable(new_fdt, cur_fdt); |
207 | rcu_assign_pointer(files->fdt, new_fdt); | 207 | rcu_assign_pointer(files->fdt, new_fdt); |
208 | if (cur_fdt->max_fds > NR_OPEN_DEFAULT) | 208 | if (cur_fdt->max_fds > NR_OPEN_DEFAULT) |
209 | call_rcu(&cur_fdt->rcu, free_fdtable_rcu); | 209 | free_fdtable(cur_fdt); |
210 | } else { | 210 | } else { |
211 | /* Somebody else expanded, so undo our attempt */ | 211 | /* Somebody else expanded, so undo our attempt */ |
212 | free_fdarr(new_fdt); | 212 | free_fdarr(new_fdt); |