diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-24 18:56:45 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-24 18:56:45 -0500 |
commit | 8301bb240d0f1b1521b83342f3af8edab7131361 (patch) | |
tree | b866e77863d534d2447f4aaeeba77ea6b307e2bd /fs/fscache/object-list.c | |
parent | 12f287878afc39acea00b3e62baf72c79878c427 (diff) | |
parent | cfbf8d4857c26a8a307fb7cd258074c9dcd8c691 (diff) |
Merge 3.14-rc4 into tty-next
We want the tty revert here as well.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
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) | |||
50 | struct fscache_object *xobj; | 50 | struct fscache_object *xobj; |
51 | struct rb_node **p = &fscache_object_list.rb_node, *parent = NULL; | 51 | struct rb_node **p = &fscache_object_list.rb_node, *parent = NULL; |
52 | 52 | ||
53 | ASSERT(RB_EMPTY_NODE(&obj->objlist_link)); | ||
54 | |||
53 | write_lock(&fscache_object_list_lock); | 55 | write_lock(&fscache_object_list_lock); |
54 | 56 | ||
55 | while (*p) { | 57 | while (*p) { |
@@ -75,6 +77,9 @@ void fscache_objlist_add(struct fscache_object *obj) | |||
75 | */ | 77 | */ |
76 | void fscache_objlist_remove(struct fscache_object *obj) | 78 | void fscache_objlist_remove(struct fscache_object *obj) |
77 | { | 79 | { |
80 | if (RB_EMPTY_NODE(&obj->objlist_link)) | ||
81 | return; | ||
82 | |||
78 | write_lock(&fscache_object_list_lock); | 83 | write_lock(&fscache_object_list_lock); |
79 | 84 | ||
80 | BUG_ON(RB_EMPTY_ROOT(&fscache_object_list)); | 85 | BUG_ON(RB_EMPTY_ROOT(&fscache_object_list)); |