Thread (1 message) 1 message, 1 author, 2017-01-09

Re: [PATCH] virtio_blk: fix panic in initialization error path

From: Jeff Moyer <hidden>
Date: 2017-01-09 19:55:57

Omar Sandoval [off-list ref] writes:
From: Omar Sandoval <redacted>

If blk_mq_init_queue() returns an error, it gets assigned to
vblk->disk->queue. Then, when we call put_disk(), we end up calling
blk_put_queue() with the ERR_PTR, causing a bad dereference. Fix it by
only assigning to vblk->disk->queue on success.

Signed-off-by: Omar Sandoval <redacted>
Reviewed-by: Jeff Moyer <redacted>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help