]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
target/pscsi: Fix NULL pointer dereference in get_device_type
authorNicholas Bellinger <nab@linux-iscsi.org>
Fri, 27 Feb 2015 11:54:13 +0000 (03:54 -0800)
committerJiri Slaby <jslaby@suse.cz>
Thu, 9 Apr 2015 11:14:21 +0000 (13:14 +0200)
commitd8e7312770e7f9b540a362bc029d5d77fbe40520
tree07087fe7fed39722efa077c8a84db50887481ed2
parent2ddc09fbd0e4fc6dec0b24c7e1978043a67933e1
target/pscsi: Fix NULL pointer dereference in get_device_type

commit 215a8fe4198f607f34ecdbc9969dae783d8b5a61 upstream.

This patch fixes a NULL pointer dereference OOPs with pSCSI backends
within target_core_stat.c code.  The bug is caused by a configfs attr
read if no pscsi_dev_virt->pdv_sd has been configured.

Reported-by: Olaf Hering <olaf@aepfle.de>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
drivers/target/target_core_pscsi.c