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

Commit fdb4c1f3 authored by Dan Carpenter's avatar Dan Carpenter Committed by Nicholas Bellinger
Browse files

target/pscsi: remove an unneeded check



blk_get_request() just returns NULL on error, it doesn't return an
ERR_PTR.

Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarNicholas Bellinger <nab@linux-iscsi.org>
parent 988e3a85
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -1050,9 +1050,8 @@ pscsi_execute_cmd(struct se_cmd *cmd)
		req = blk_get_request(pdv->pdv_sd->request_queue,
				(data_direction == DMA_TO_DEVICE),
				GFP_KERNEL);
		if (!req || IS_ERR(req)) {
			pr_err("PSCSI: blk_get_request() failed: %ld\n",
					req ? IS_ERR(req) : -ENOMEM);
		if (!req) {
			pr_err("PSCSI: blk_get_request() failed\n");
			ret = TCM_LOGICAL_UNIT_COMMUNICATION_FAILURE;
			goto fail;
		}