summaryrefslogtreecommitdiff
path: root/ipc
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2018-05-21 12:21:14 -0600
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-05-30 07:51:49 +0200
commit2a039b93679fb2e974bedf5b0d76da81731474ba (patch)
tree7e1d4fd0d9dafabb4c9fe772a1eaa2f3f259d0cc /ipc
parenta59bd819576d9dc0ca279f2c1a4b3903ca786d12 (diff)
sr: pass down correctly sized SCSI sense buffer
commit f7068114d45ec55996b9040e98111afa56e010fe upstream. We're casting the CDROM layer request_sense to the SCSI sense buffer, but the former is 64 bytes and the latter is 96 bytes. As we generally allocate these on the stack, we end up blowing up the stack. Fix this by wrapping the scsi_execute() call with a properly sized sense buffer, and copying back the bits for the CDROM layer. Cc: stable@vger.kernel.org Reported-by: Piotr Gabriel Kosinski <pg.kosinski@gmail.com> Reported-by: Daniel Shapira <daniel@twistlock.com> Tested-by: Kees Cook <keescook@chromium.org> Fixes: 82ed4db499b8 ("block: split scsi_request out of struct request") Signed-off-by: Jens Axboe <axboe@kernel.dk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'ipc')
0 files changed, 0 insertions, 0 deletions