]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
bcache: prevent crash on changing writeback_running
authorStefan Bader <stefan.bader@canonical.com>
Mon, 30 Nov 2015 02:44:49 +0000 (18:44 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 3 Mar 2016 23:07:09 +0000 (15:07 -0800)
commit9e761c1b436d04823baa161c294fddc524750015
treea565e419a9a912cf1d30ae5cf3c9c0e7b42f90fe
parentb38798df6cca121e0df4c6a500408070eba24264
bcache: prevent crash on changing writeback_running

commit 8d16ce540c94c9d366eb36fc91b7154d92d6397b upstream.

Added a safeguard in the shutdown case. At least while not being
attached it is also possible to trigger a kernel bug by writing into
writeback_running. This change  adds the same check before trying to
wake up the thread for that case.

Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
Cc: Kent Overstreet <kent.overstreet@gmail.com>
Signed-off-by: Jens Axboe <axboe@fb.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/md/bcache/writeback.h