aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/sg.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi/sg.c')
-rw-r--r--drivers/scsi/sg.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/scsi/sg.c b/drivers/scsi/sg.c
index 7936aafc3d05..3d1d7bff38ed 100644
--- a/drivers/scsi/sg.c
+++ b/drivers/scsi/sg.c
@@ -2472,6 +2472,8 @@ sg_remove_request(Sg_fd * sfp, Sg_request * srp)
2472 if ((!sfp) || (!srp) || (!sfp->headrp)) 2472 if ((!sfp) || (!srp) || (!sfp->headrp))
2473 return res; 2473 return res;
2474 write_lock_irqsave(&sfp->rq_list_lock, iflags); 2474 write_lock_irqsave(&sfp->rq_list_lock, iflags);
2475 if (srp->my_cmdp)
2476 srp->my_cmdp->upper_private_data = NULL;
2475 prev_rp = sfp->headrp; 2477 prev_rp = sfp->headrp;
2476 if (srp == prev_rp) { 2478 if (srp == prev_rp) {
2477 sfp->headrp = prev_rp->nextrp; 2479 sfp->headrp = prev_rp->nextrp;