diff options
author | Matt Fleming <matt.fleming@intel.com> | 2014-03-05 17:22:57 +0000 |
---|---|---|
committer | Matt Fleming <matt.fleming@intel.com> | 2014-03-05 17:31:41 +0000 |
commit | 4fd69331ad227a4d8de26592d017b73e00caca9f (patch) | |
tree | bfd95ed518ff0cb44318715432d321a92a7b9a0c /fs/fscache/object-list.c | |
parent | 69e608411473ac56358ef35277563982d0565381 (diff) | |
parent | 0ac09f9f8cd1fb028a48330edba6023d347d3cea (diff) | |
download | lwn-4fd69331ad227a4d8de26592d017b73e00caca9f.tar.gz lwn-4fd69331ad227a4d8de26592d017b73e00caca9f.zip |
Merge remote-tracking branch 'tip/x86/urgent' into efi-for-mingo
Conflicts:
arch/x86/include/asm/efi.h
Diffstat (limited to 'fs/fscache/object-list.c')
-rw-r--r-- | fs/fscache/object-list.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/fscache/object-list.c b/fs/fscache/object-list.c index e1959efad64f..b5ebc2d7d80d 100644 --- a/fs/fscache/object-list.c +++ b/fs/fscache/object-list.c @@ -50,6 +50,8 @@ void fscache_objlist_add(struct fscache_object *obj) struct fscache_object *xobj; struct rb_node **p = &fscache_object_list.rb_node, *parent = NULL; + ASSERT(RB_EMPTY_NODE(&obj->objlist_link)); + write_lock(&fscache_object_list_lock); while (*p) { @@ -75,6 +77,9 @@ void fscache_objlist_add(struct fscache_object *obj) */ void fscache_objlist_remove(struct fscache_object *obj) { + if (RB_EMPTY_NODE(&obj->objlist_link)) + return; + write_lock(&fscache_object_list_lock); BUG_ON(RB_EMPTY_ROOT(&fscache_object_list)); |