Files
linux/drivers/block
Linus Torvalds 56bc086358 loop: fix concurrent lo_open/lo_release
commit ae6650163c upstream.

范龙飞 reports that KASAN can report a use-after-free in __lock_acquire.
The reason is due to insufficient serialization in lo_release(), which
will continue to use the loop device even after it has decremented the
lo_refcnt to zero.

In the meantime, another process can come in, open the loop device
again as it is being shut down. Confusion ensues.

Reported-by: 范龙飞 <long7573@126.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Cc: Ben Hutchings <ben.hutchings@codethink.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-02-03 17:05:33 +01:00
..
2016-09-15 08:42:03 -06:00
2016-06-27 12:26:08 -07:00
2016-06-27 12:26:08 -07:00
2016-03-14 09:06:01 -06:00
2018-02-03 17:05:33 +01:00
2015-09-23 11:01:16 -06:00
2016-03-15 15:59:47 -07:00
2016-08-07 14:41:02 -06:00
2016-06-27 12:26:08 -07:00
2016-06-27 12:26:08 -07:00
2018-01-17 09:38:54 +01:00
2016-06-27 12:26:08 -07:00
2016-08-07 14:41:02 -06:00