Re: [patch] smarter atime updates

OGAWA Hirofumi
2001-11-30T10:41:34Z

Andrew Morton <akpm@zip.com.au> writes:

> OGAWA Hirofumi wrote:
> >
> > #define UPDATE_ATIME(inode) \
> > do { \
> > if ((inode)->i_atime != CURRENT_TIME) \
> > update_atime (inode); \
> > } while (0)
> >
>
> yes, that'd be fine. The more conventional approach
> would be to blow away the strange UPPER CASE name and:
>
> static inline void update_atime(struct inode *inode)
> {
> if (inode->i_atime != CURRENT_TIME)
> __update_atime(inode);
> }
>
> But that would be a bigger patch, and I rather like shaving
> off three quarters of the sys_read() overhead with a two-liner ;)

Umm, I think only fs/autofs4/root.c use update_atime() directly.
--
OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>