From 3d50a76fe4f8ce211e84e60257bfc3694aa46f5f Mon Sep 17 00:00:00 2001 From: "Aneesh Kumar K.V" Date: Tue, 29 Apr 2008 08:11:12 -0400 Subject: [PATCH] --- yaml --- r: 95024 b: refs/heads/master c: e65187e6d0d541f992e684f88a7e090dcff1aac8 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/fs/ext4/ialloc.c | 4 ++-- trunk/fs/ext4/namei.c | 2 ++ 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index dc4cd10ba362..aee73c5295b5 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 95c3889cb88ca4833096553c12cde9e7eb792f4c +refs/heads/master: e65187e6d0d541f992e684f88a7e090dcff1aac8 diff --git a/trunk/fs/ext4/ialloc.c b/trunk/fs/ext4/ialloc.c index 486e46a3918d..cb14646117f0 100644 --- a/trunk/fs/ext4/ialloc.c +++ b/trunk/fs/ext4/ialloc.c @@ -750,8 +750,8 @@ struct inode *ext4_new_inode(handle_t *handle, struct inode * dir, int mode) goto fail_free_drop; } if (test_opt(sb, EXTENTS)) { - /* set extent flag only for directory and file */ - if (S_ISDIR(mode) || S_ISREG(mode)) { + /* set extent flag only for diretory, file and normal symlink*/ + if (S_ISDIR(mode) || S_ISREG(mode) || S_ISLNK(mode)) { EXT4_I(inode)->i_flags |= EXT4_EXTENTS_FL; ext4_ext_tree_init(handle, inode); err = ext4_update_incompat_feature(handle, sb, diff --git a/trunk/fs/ext4/namei.c b/trunk/fs/ext4/namei.c index 28aa2ed4297e..68611945687d 100644 --- a/trunk/fs/ext4/namei.c +++ b/trunk/fs/ext4/namei.c @@ -2217,6 +2217,8 @@ static int ext4_symlink (struct inode * dir, goto out_stop; } } else { + /* clear the extent format for fast symlink */ + EXT4_I(inode)->i_flags &= ~EXT4_EXTENTS_FL; inode->i_op = &ext4_fast_symlink_inode_operations; memcpy((char*)&EXT4_I(inode)->i_data,symname,l); inode->i_size = l-1;