diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-07-29 11:50:17 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-07-29 11:50:17 -0700 |
commit | 9c5891bd4342349a200676d33f742dd1b864822c (patch) | |
tree | b14c1698f2d8ce5276e1befd562f6398a46b48b9 /drivers/md/bcache/closure.c | |
parent | pcmcia: synclink_cs: replace sum of bitmasks with OR operation. (diff) | |
parent | Linux 3.11-rc3 (diff) | |
download | linux-dev-9c5891bd4342349a200676d33f742dd1b864822c.tar.xz linux-dev-9c5891bd4342349a200676d33f742dd1b864822c.zip |
Merge 3.11-rc3 into char-misc-next.
This resolves a merge issue with:
drivers/misc/mei/init.c
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/md/bcache/closure.c')
-rw-r--r-- | drivers/md/bcache/closure.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/md/bcache/closure.c b/drivers/md/bcache/closure.c index bd05a9a8c7cf..9aba2017f0d1 100644 --- a/drivers/md/bcache/closure.c +++ b/drivers/md/bcache/closure.c @@ -66,16 +66,18 @@ static inline void closure_put_after_sub(struct closure *cl, int flags) } else { struct closure *parent = cl->parent; struct closure_waitlist *wait = closure_waitlist(cl); + closure_fn *destructor = cl->fn; closure_debug_destroy(cl); + smp_mb(); atomic_set(&cl->remaining, -1); if (wait) closure_wake_up(wait); - if (cl->fn) - cl->fn(cl); + if (destructor) + destructor(cl); if (parent) closure_put(parent); |