On 02/14/2017 08:15 PM, Christoph Hellwig wrote: > Remove bogus evaluations of retval and sshdr when the device is offline, > and fix a possible NULL pointer dereference by allocating the 8 byte > sized sense header on stack. > > Signed-off-by: Christoph Hellwig <hch@xxxxxx> > --- > drivers/scsi/sd.c | 25 +++++++++++-------------- > 1 file changed, 11 insertions(+), 14 deletions(-) > Reviewed-by: Hannes Reinecke <hare@xxxxxxxx> Cheers, Hannes -- Dr. Hannes Reinecke Teamlead Storage & Networking hare@xxxxxxx +49 911 74053 688 SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg GF: F. Imendörffer, J. Smithard, J. Guild, D. Upmanyu, G. Norton HRB 21284 (AG Nürnberg)