OSDN Git Service
(root)
/
sagit-ice-cold
/
kernel_xiaomi_msm8998.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
635a2b3
)
target: Make pscsi_create_virtdevice use ERR_CAST
author
Dan Carpenter
<dan.carpenter@oracle.com>
Sat, 1 Oct 2011 22:59:13 +0000
(
01:59
+0300)
committer
Nicholas Bellinger
<nab@linux-iscsi.org>
Mon, 24 Oct 2011 03:20:51 +0000
(
03:20
+0000)
This patch changes pscsi_create_virtdevice() to properly return ERR_CAST
instead of a raw pointer upon scsi_host_lookup() failure.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
drivers/target/target_core_pscsi.c
patch
|
blob
|
history
diff --git
a/drivers/target/target_core_pscsi.c
b/drivers/target/target_core_pscsi.c
index
b6d6093
..
3898fb7
100644
(file)
--- a/
drivers/target/target_core_pscsi.c
+++ b/
drivers/target/target_core_pscsi.c
@@
-566,7
+566,7
@@
static struct se_device *pscsi_create_virtdevice(
if (IS_ERR(sh)) {
pr_err("pSCSI: Unable to locate"
" pdv_host_id: %d\n", pdv->pdv_host_id);
- return
(struct se_device *) sh
;
+ return
ERR_CAST(sh)
;
}
}
} else {