[openib-general] SRP [PATCH] Looks like a potantial bug

Ishai Rabinovitz ishai at mellanox.co.il
Wed May 17 08:40:04 PDT 2006


Hi,

While doing a code review I found a potential bug.
I did not manage to execute a test to check this code.
Please take a look:
Signed-off-by: Ishai Rabinovitz <ishai at mellanox.co.il>
--------------------------------------
Index: last_stable/drivers/infiniband/ulp/srp/ib_srp.c
===================================================================
--- last_stable.orig/drivers/infiniband/ulp/srp/ib_srp.c	2006-05-17 16:24:24.000000000 +0300
+++ last_stable/drivers/infiniband/ulp/srp/ib_srp.c	2006-05-17 17:13:47.000000000 +0300
@@ -1326,7 +1326,7 @@ static int srp_reset_device(struct scsi_
 	list_for_each_entry_safe(req, tmp, &target->req_queue, list)
 		if (req->scmnd->device == scmnd->device) {
 			req->scmnd->result = DID_RESET << 16;
-			scmnd->scsi_done(scmnd);
+			req->scmnd->scsi_done(scmnd);
 			srp_remove_req(target, req);
 		}
 
-- 
Ishai Rabinovitz



More information about the general mailing list