target/pscsi: fix return value check
authorWei Yongjun <yongjun_wei@trendmicro.com.cn>
Fri, 25 Oct 2013 13:53:33 +0000 (21:53 +0800)
committerBen Hutchings <ben@decadent.org.uk>
Thu, 28 Nov 2013 14:02:05 +0000 (14:02 +0000)
commit5874fd1d23ed9a7a49802c2cfeed8d57b9ae303d
tree0176d89df5b2acd9748b78372af710aea8c0e479
parent069b7dec73731bb979c5fcc773934d2f403f69a0
target/pscsi: fix return value check

commit 58932e96e438cd78f75e765d7b87ef39d3533d15 upstream.

In case of error, the function scsi_host_lookup() returns NULL
pointer not ERR_PTR(). The IS_ERR() test in the return value check
should be replaced with NULL test.

Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
[bwh: Backported to 3.2: pscsi_configure_device() returns a pointer]
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
drivers/target/target_core_pscsi.c