From 3e9014b7ae2e05b53552f6524a2efd5d22a20400 Mon Sep 17 00:00:00 2001 From: Nick Piggin Date: Fri, 29 Jan 2010 15:38:29 -0800 Subject: fs-inode_lock-scale-5 Protect inodes_stat statistics with atomic ops rather than inode_lock. Signed-off-by: Nick Piggin Signed-off-by: John Stultz Signed-off-by: Thomas Gleixner --- include/linux/fs.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/linux/fs.h b/include/linux/fs.h index 659579634f9a..fc4222374cd7 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h @@ -8,6 +8,7 @@ #include #include +#include /* * It's silly to have NR_OPEN bigger than NR_FILE, but you can change @@ -39,8 +40,8 @@ struct files_stat_struct { }; struct inodes_stat_t { - int nr_inodes; - int nr_unused; + atomic_t nr_inodes; + atomic_t nr_unused; int dummy[5]; /* padding for sysctl ABI compatibility */ }; -- cgit v1.2.3