diff options
author | Eric Dumazet <dada1@cosmosbay.com> | 2007-02-10 04:44:49 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-02-11 13:51:25 -0500 |
commit | 37756ced1f145aec18917812c3b8a96dbb47990d (patch) | |
tree | a293813e3dce24a161c2cf029c4139086a23d978 /include | |
parent | 4ba4d4c0c52201009232fe9e781a281054a24e75 (diff) |
[PATCH] avoid one conditional branch in touch_atime()
I added IS_NOATIME(inode) macro definition in include/linux/fs.h, true if
the inode superblock is marked readonly or noatime.
This new macro is then used in touch_atime() instead of separatly testing
MS_RDONLY and MS_NOATIME
Signed-off-by: Eric Dumazet <dada1@cosmosbay.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/fs.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h index 1410e5330c8d..822c545c7209 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -169,6 +169,7 @@ extern int dir_notify_enable; | |||
169 | #define IS_DIRSYNC(inode) (__IS_FLG(inode, MS_SYNCHRONOUS|MS_DIRSYNC) || \ | 169 | #define IS_DIRSYNC(inode) (__IS_FLG(inode, MS_SYNCHRONOUS|MS_DIRSYNC) || \ |
170 | ((inode)->i_flags & (S_SYNC|S_DIRSYNC))) | 170 | ((inode)->i_flags & (S_SYNC|S_DIRSYNC))) |
171 | #define IS_MANDLOCK(inode) __IS_FLG(inode, MS_MANDLOCK) | 171 | #define IS_MANDLOCK(inode) __IS_FLG(inode, MS_MANDLOCK) |
172 | #define IS_NOATIME(inode) __IS_FLG(inode, MS_RDONLY|MS_NOATIME) | ||
172 | 173 | ||
173 | #define IS_NOQUOTA(inode) ((inode)->i_flags & S_NOQUOTA) | 174 | #define IS_NOQUOTA(inode) ((inode)->i_flags & S_NOQUOTA) |
174 | #define IS_APPEND(inode) ((inode)->i_flags & S_APPEND) | 175 | #define IS_APPEND(inode) ((inode)->i_flags & S_APPEND) |