Linux Headquarters
[ Register ]
[ About us ] [ Home Page ]

Advertisement
[ Kernel ] [ Documentation ] [ Links ] [ Books ]

Advertisement

Kernel v2.6.24 /fs/ext4/dir.c

Filename:/fs/ext4/dir.c
Lines Added:2
Lines Deleted:9
Also changed in: (Previous) 2.6.24-rc8  2.6.24-rc7  2.6.24-rc6  2.6.24-rc5  2.6.24-rc4  2.6.24-rc3 
(Following) 2.6.24-git6  2.6.24-git7  2.6.24-git8  2.6.24-git9  2.6.24-git10  2.6.24-git11 

Location
[  2.6.24
  [  fs
    [  ext4
       o  dir.c

Patch

diff --git a/fs/ext4/dir.c b/fs/ext4/dir.c
index 3ab01c0..f612bef 100644
--- a/fs/ext4/dir.c
+++ b/fs/ext4/dir.c
@@ -47,9 +47,7 @@ const struct file_operations ext4_dir_operations = {
    .compat_ioctl   = ext4_compat_ioctl,
 #endif
    .fsync      = ext4_sync_file,   /* BKL held */
-#ifdef CONFIG_EXT4_INDEX
    .release   = ext4_release_dir,
-#endif
 };
 
 
@@ -107,7 +105,6 @@ static int ext4_readdir(struct file * filp,
 
    sb = inode->i_sb;
 
-#ifdef CONFIG_EXT4_INDEX
    if (EXT4_HAS_COMPAT_FEATURE(inode->i_sb,
                 EXT4_FEATURE_COMPAT_DIR_INDEX) &&
        ((EXT4_I(inode)->i_flags & EXT4_INDEX_FL) ||
@@ -123,7 +120,6 @@ static int ext4_readdir(struct file * filp,
        */
       EXT4_I(filp->f_path.dentry->d_inode)->i_flags &= ~EXT4_INDEX_FL;
    }
-#endif
    stored = 0;
    offset = filp->f_pos & (sb->s_blocksize - 1);
 
@@ -142,7 +138,7 @@ static int ext4_readdir(struct file * filp,
                sb->s_bdev->bd_inode->i_mapping,
                &filp->f_ra, filp,
                index, 1);
-         filp->f_ra.prev_index = index;
+         filp->f_ra.prev_pos = (loff_t)index << PAGE_CACHE_SHIFT;
          bh = ext4_bread(NULL, inode, blk, 0, &err);
       }
 
@@ -210,7 +206,7 @@ revalidate:
              * not the directory has been modified
              * during the copy operation.
              */
-            unsigned long version = filp->f_version;
+            u64 version = filp->f_version;
 
             error = filldir(dirent, de->name,
                   de->name_len,
@@ -232,7 +228,6 @@ out:
    return ret;
 }
 
-#ifdef CONFIG_EXT4_INDEX
 /*
  * These functions convert from the major/minor hash to an f_pos
  * value.
@@ -518,5 +513,3 @@ static int ext4_release_dir (struct inode * inode, struct file * filp)
 
    return 0;
 }
-
-#endif


Comments: webmaster (at) linuxhq.com.
Advertising: banners (at) linuxhq.com.
Compilation ©1998-2008 Linux Headquarters, Inc.