diff options
author | Igor Pylypiv <[email protected]> | 2021-07-07 11:59:45 -0700 |
---|---|---|
committer | Martin K. Petersen <[email protected]> | 2021-07-28 23:29:09 -0400 |
commit | d712d3fb484b7fa8d1d57e9ca6f134bb9d8c18b1 (patch) | |
tree | b309c6d514e869fefba51996e843c412314bb325 /lib/test_overflow.c | |
parent | a47fa41381a09e5997afd762664db4f5f6657e03 (diff) |
scsi: pm80xx: Fix TMF task completion race condition
The TMF timeout timer may trigger at the same time when the response from a
controller is being handled. When this happens the SAS task may get freed
before the response processing is finished.
Fix this by calling complete() only when SAS_TASK_STATE_DONE is not set.
A similar race condition was fixed in commit b90cd6f2b905 ("scsi: libsas:
fix a race condition when smp task timeout")
Link: https://lore.kernel.org/r/[email protected]
Reviewed-by: Vishakha Channapattan <[email protected]>
Acked-by: Jack Wang <[email protected]>
Signed-off-by: Igor Pylypiv <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
Diffstat (limited to 'lib/test_overflow.c')
0 files changed, 0 insertions, 0 deletions