diff options
author | Evgeniy Dushistov <dushistov@mail.ru> | 2006-06-25 05:47:25 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-25 10:01:03 -0700 |
commit | dd187a2603d9904ddc410441348f0cfc558a5233 (patch) | |
tree | a3859f88d1f458a18d31a231f03c955393282255 /fs/ufs/inode.c | |
parent | abf5d15fd2e52517dd56a17a846d5a1f900b7db4 (diff) | |
download | linux-stable-dd187a2603d9904ddc410441348f0cfc558a5233.tar.gz linux-stable-dd187a2603d9904ddc410441348f0cfc558a5233.tar.bz2 linux-stable-dd187a2603d9904ddc410441348f0cfc558a5233.zip |
[PATCH] ufs: little directory lookup optimization
This patch make little optimization of ufs_find_entry like "ext2" does. Save
number of page and reuse it again in the next call.
Signed-off-by: Evgeniy Dushistov <dushistov@mail.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/ufs/inode.c')
-rw-r--r-- | fs/ufs/inode.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/ufs/inode.c b/fs/ufs/inode.c index 01f754462341..c57612d443d0 100644 --- a/fs/ufs/inode.c +++ b/fs/ufs/inode.c @@ -628,12 +628,12 @@ void ufs_read_inode (struct inode * inode) ufsi->i_shadow = fs32_to_cpu(sb, ufs_inode->ui_u3.ui_sun.ui_shadow); ufsi->i_oeftflag = fs32_to_cpu(sb, ufs_inode->ui_u3.ui_sun.ui_oeftflag); ufsi->i_lastfrag = (inode->i_size + uspi->s_fsize - 1) >> uspi->s_fshift; + ufsi->i_dir_start_lookup = 0; if (S_ISCHR(mode) || S_ISBLK(mode) || inode->i_blocks) { for (i = 0; i < (UFS_NDADDR + UFS_NINDIR); i++) ufsi->i_u1.i_data[i] = ufs_inode->ui_u2.ui_addr.ui_db[i]; - } - else { + } else { for (i = 0; i < (UFS_NDADDR + UFS_NINDIR) * 4; i++) ufsi->i_u1.i_symlink[i] = ufs_inode->ui_u2.ui_symlink[i]; } |