]> git.baikalelectronics.ru Git - kernel.git/commit
blktrace: fix unlocked access to init/start-stop/teardown
authorJens Axboe <axboe@kernel.dk>
Sun, 5 Nov 2017 16:13:48 +0000 (09:13 -0700)
committerJens Axboe <axboe@kernel.dk>
Sat, 11 Nov 2017 02:53:25 +0000 (19:53 -0700)
commit9d28b7baba1a4a277df809dd7c469e4e085990e8
tree958d22ca65748177f3d3de85af6ef468fe5826c7
parente0f3f5f6d0aaf53d500beef3f632131161aab328
blktrace: fix unlocked access to init/start-stop/teardown

sg.c calls into the blktrace functions without holding the proper queue
mutex for doing setup, start/stop, or teardown.

Add internal unlocked variants, and export the ones that do the proper
locking.

Fixes: 08e7dae9bb1b ("blktrace: Add blktrace ioctls to SCSI generic devices")
Tested-by: Dmitry Vyukov <dvyukov@google.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
kernel/trace/blktrace.c