diff options
author | Eric Paris <eparis@redhat.com> | 2010-10-25 14:42:19 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-10-26 14:37:19 -0400 |
commit | 196f518128d2ee6e0028b50e6fec0313640db142 (patch) | |
tree | 43a1d76bee477dbaa682233979e86f58a98369f0 /include/linux/fs.h | |
parent | 64c62f06bef8314a64d3189cb9c78062d54169b3 (diff) |
IMA: explicit IMA i_flag to remove global lock on inode_delete
Currently for every removed inode IMA must take a global lock and search
the IMA rbtree looking for an associated integrity structure. Instead
we explicitly mark an inode when we add an integrity structure so we
only have to take the global lock and do the removal if it exists.
Signed-off-by: Eric Paris <eparis@redhat.com>
Acked-by: Mimi Zohar <zohar@linux.vnet.ibm.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/fs.h')
-rw-r--r-- | include/linux/fs.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h index 01e3a0047fed..bb77843de9d6 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -235,6 +235,7 @@ struct inodes_stat_t { | |||
235 | #define S_NOCMTIME 128 /* Do not update file c/mtime */ | 235 | #define S_NOCMTIME 128 /* Do not update file c/mtime */ |
236 | #define S_SWAPFILE 256 /* Do not truncate: swapon got its bmaps */ | 236 | #define S_SWAPFILE 256 /* Do not truncate: swapon got its bmaps */ |
237 | #define S_PRIVATE 512 /* Inode is fs-internal */ | 237 | #define S_PRIVATE 512 /* Inode is fs-internal */ |
238 | #define S_IMA 1024 /* Inode has an associated IMA struct */ | ||
238 | 239 | ||
239 | /* | 240 | /* |
240 | * Note that nosuid etc flags are inode-specific: setting some file-system | 241 | * Note that nosuid etc flags are inode-specific: setting some file-system |
@@ -269,6 +270,7 @@ struct inodes_stat_t { | |||
269 | #define IS_NOCMTIME(inode) ((inode)->i_flags & S_NOCMTIME) | 270 | #define IS_NOCMTIME(inode) ((inode)->i_flags & S_NOCMTIME) |
270 | #define IS_SWAPFILE(inode) ((inode)->i_flags & S_SWAPFILE) | 271 | #define IS_SWAPFILE(inode) ((inode)->i_flags & S_SWAPFILE) |
271 | #define IS_PRIVATE(inode) ((inode)->i_flags & S_PRIVATE) | 272 | #define IS_PRIVATE(inode) ((inode)->i_flags & S_PRIVATE) |
273 | #define IS_IMA(inode) ((inode)->i_flags & S_IMA) | ||
272 | 274 | ||
273 | /* the read-only stuff doesn't really belong here, but any other place is | 275 | /* the read-only stuff doesn't really belong here, but any other place is |
274 | probably as bad and I don't want to create yet another include file. */ | 276 | probably as bad and I don't want to create yet another include file. */ |