From e1df4805368b1976055031287bb5e7b9040bc6cc Mon Sep 17 00:00:00 2001 From: Oleg Drokin Date: Fri, 27 Jan 2012 20:26:53 -0500 Subject: [PATCH] LU-1048 ldiskfs: fix dynlock cache entry freeing Update to rhel6.2 broke dynlocks patch and the last hunk was ignored by quilt/patch. This commit rediffs the proper patch against 2.6.32-220.el6 Change-Id: If9020458d07c7c2dc714b3e38587f66c4846f806 Signed-off-by: Oleg Drokin Reviewed-on: http://review.whamcloud.com/2034 Tested-by: Hudson Reviewed-by: Andreas Dilger --- .../patches/ext4-dynlocks-common-rhel6.patch | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/ldiskfs/kernel_patches/patches/ext4-dynlocks-common-rhel6.patch b/ldiskfs/kernel_patches/patches/ext4-dynlocks-common-rhel6.patch index 1a2675d..e47037d 100644 --- a/ldiskfs/kernel_patches/patches/ext4-dynlocks-common-rhel6.patch +++ b/ldiskfs/kernel_patches/patches/ext4-dynlocks-common-rhel6.patch @@ -122,7 +122,7 @@ Index: linux-stage/fs/ext4/dynlocks.c + goto found; + } + spin_unlock(&dl->dl_list_lock); -+ ++ + /* lock not found and we haven't allocated lock yet. allocate it */ + nhl = kmem_cache_alloc(dynlock_cachep, gfp); + if (nhl == NULL) @@ -179,7 +179,7 @@ Index: linux-stage/fs/ext4/dynlocks.c +void dynlock_unlock(struct dynlock *dl, struct dynlock_handle *hl) +{ + int wakeup = 0; -+ ++ + BUG_ON(dl == NULL); + BUG_ON(hl == NULL); + BUG_ON(dl->dl_magic != DYNLOCK_LIST_MAGIC); @@ -295,7 +295,7 @@ Index: linux-stage/fs/ext4/super.c =================================================================== --- linux-stage.orig/fs/ext4/super.c +++ linux-stage/fs/ext4/super.c -@@ -4125,20 +4125,23 @@ static int __init init_ext4_fs(void) +@@ -4620,20 +4620,23 @@ static int __init init_ext4_fs(void) return err; ext4_kset = kset_create_and_add("ext4", NULL, fs_kobj); if (!ext4_kset) @@ -303,7 +303,7 @@ Index: linux-stage/fs/ext4/super.c + goto out5; ext4_proc_root = proc_mkdir("fs/ext4", NULL); - err = ext4_init_feat_adverts(); + err = ext4_init_feat_adverts(); err = init_ext4_mballoc(); if (err) @@ -320,10 +320,10 @@ Index: linux-stage/fs/ext4/super.c + err = dynlock_cache_init(); + if (err) goto out1; - - ext4_li_info = NULL; -@@ -4125,14 +4125,16 @@ static int __init init_ext4_fs(void) - goto out; + err = register_filesystem(&ext4_fs_type); + if (err) +@@ -4643,16 +4646,18 @@ static int __init init_ext4_fs(void) + mutex_init(&ext4_li_mtx); return 0; out: - destroy_inodecache(); @@ -337,7 +337,7 @@ Index: linux-stage/fs/ext4/super.c out3: + exit_ext4_mballoc(); +out4: - ext4_exit_feat_adverts(); + ext4_exit_feat_adverts(); remove_proc_entry("fs/ext4", NULL); kset_unregister(ext4_kset); -out4: @@ -345,9 +345,9 @@ Index: linux-stage/fs/ext4/super.c exit_ext4_system_zone(); return err; } -@@ -4158,6 +4163,7 @@ out4: - static void __exit exit_ext4_fs(void) +@@ -4661,6 +4666,7 @@ static void __exit exit_ext4_fs(void) { + ext4_destroy_lazyinit_thread(); unregister_filesystem(&ext4_fs_type); + dynlock_cache_exit(); destroy_inodecache(); -- 1.8.3.1