Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
scsi: lpfc: Early return after marking final NLP_DROPPED flag in dev_…
…loss_tmo When a dev_loss_tmo event occurs, an ndlp lock is taken before checking nlp_flag for NLP_DROPPED. There is an attempt to restore the ndlp lock when exiting the if statement, but the nlp_put kref could be the final decrement causing a use-after-free memory access on a released ndlp object. Instead of trying to reacquire the ndlp lock after checking nlp_flag, just return after calling nlp_put. Signed-off-by: Justin Tee <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: "Ewan D. Milne" <[email protected]> Signed-off-by: Martin K. Petersen <[email protected]>
- Loading branch information