ipr: fix addition of abort command to HRRQ free queue
Please ignore this one. Messed up with send-email --annotate.
Thanks,
Kleber
Quoted 32 lines · Kleber Sacilotto de Souza
Brian/Wendy,
This is a patch for bug #89324. We were not using the right HRRQ pointer, so we were adding the command to the wrong free queue, which can be not initialized and cause a null-pointer dereference when calling
list_add_tail().Kleber
---
The abort command issued byipr_cancel_op()is being added to the wrong HRRQ free queue after the command returns. Fix it by using the HRRQ pointer in the ipr command struct itself.Signed-off-by Kleber Sacilotto de Souza <[email protected]>--- drivers/scsi/ipr.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)drivers/scsi/ipr.c +1
-1@@ -5148,7 +5148,7 @@ static int ipr_cancel_op(struct scsi_cmnd *scsi_cmd) ipr_trace; } -list_add_tail (&ipr_cmd->queue, &hrrq->hrrq_free_q); +list_add_tail (&ipr_cmd->queue, &ipr_cmd->hrrq->hrrq_free_q);if (!ipr_is_naca_model (res)) res->needs_sync_complete =1 ;
Signature · 2 lines
Kleber Sacilotto de Souza IBM Linux Technology Center