diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2015-04-14 14:32:19 (GMT) |
---|---|---|
committer | James Bottomley <JBottomley@Odin.com> | 2015-05-25 15:46:26 (GMT) |
commit | ea47ebf15d68d616cf0daef31e7f694d11b59f7f (patch) | |
tree | f6795dac78f84e34514d72221f4d2d940e94dc45 /drivers/scsi/csiostor | |
parent | 0d143c69a32d062ee859b75cab982a926ef79817 (diff) | |
download | linux-ea47ebf15d68d616cf0daef31e7f694d11b59f7f.tar.xz |
csiostor: fix an error code in csio_hw_init()
We should return -ENOMEM if kzalloc() fails here instead of returning
success.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Tomas Henzl <thenzl@redhat.com>
Signed-off-by: James Bottomley <JBottomley@Odin.com>
Diffstat (limited to 'drivers/scsi/csiostor')
-rw-r--r-- | drivers/scsi/csiostor/csio_hw.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/scsi/csiostor/csio_hw.c b/drivers/scsi/csiostor/csio_hw.c index 2e66f34..622bdab 100644 --- a/drivers/scsi/csiostor/csio_hw.c +++ b/drivers/scsi/csiostor/csio_hw.c @@ -3928,6 +3928,7 @@ csio_hw_init(struct csio_hw *hw) evt_entry = kzalloc(sizeof(struct csio_evt_msg), GFP_KERNEL); if (!evt_entry) { + rv = -ENOMEM; csio_err(hw, "Failed to initialize eventq"); goto err_evtq_cleanup; } |