Skip to contentSkip to conversation

Patch "scsi: lpfc: Set elsiocb contexts to NULL after freeing it" has been added to the 4.9-stable tree

PATCH [email protected] 1 participant 1 message Jul 3, 2017

Subsystems (3)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

scsi: lpfc: Set elsiocb contexts to NULL after freeing it

to the 4.9-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
scsi-lpfc-set-elsiocb-contexts-to-null-after-freeing-it.patch
and it can be found in the queue-4.9 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From foo@baz Mon Jul 3 11:12:14 CEST 2017

From: Johannes Thumshirn <[email protected]>
Date: Tue, 10 Jan 2017 12:05:54 +0100
Subject: scsi: lpfc: Set elsiocb contexts to NULL after freeing it

From: Johannes Thumshirn <[email protected]>

[ Upstream commit 8667f515952feefebb3c0f8d9a9266c91b101a46 ]

Set the elsiocb contexts to NULL after freeing as others depend on it.

---
 drivers/scsi/lpfc/lpfc_els.c |    2 ++
 1 file changed, 2 insertions(+)
drivers/scsi/lpfc/lpfc_els.c +2 -0
@@ -3590,12 +3590,14 @@ lpfc_els_free_iocb(struct lpfc_hba *phba
 		} else {
 			buf_ptr1 = (struct lpfc_dmabuf *) elsiocb->context2;
 			lpfc_els_free_data(phba, buf_ptr1);
+			elsiocb->context2 = NULL;
 		}
 	}
 
 	if (elsiocb->context3) {
 		buf_ptr = (struct lpfc_dmabuf *) elsiocb->context3;
 		lpfc_els_free_bpl(phba, buf_ptr);
+		elsiocb->context3 = NULL;
 	}
 	lpfc_sli_release_iocbq(phba, elsiocb);
 	return 0;

Patches currently in stable-queue which might be from [email protected] are

queue-4.9/scsi-lpfc-set-elsiocb-contexts-to-null-after-freeing-it.patch