Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ea47ebf1 authored by Dan Carpenter's avatar Dan Carpenter Committed by James Bottomley
Browse files

csiostor: fix an error code in csio_hw_init()



We should return -ENOMEM if kzalloc() fails here instead of returning
success.

Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: default avatarTomas Henzl <thenzl@redhat.com>
Signed-off-by: default avatarJames Bottomley <JBottomley@Odin.com>
parent 0d143c69
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -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;
		}