Commit c31657e5 authored by Bart Van Assche's avatar Bart Van Assche
Browse files

BACKPORT: FROMGIT: scsi: ufs: core: Stop clearing unit attentions

Commit aa53f580 ("scsi: ufs: Minor adjustments to error handling")
introduced a ufshcd_clear_ua_wluns() call in
ufshcd_err_handling_unprepare(). As explained in detail by Adrian Hunter,
this can trigger a deadlock. Avoid that deadlock by removing the code that
clears the unit attention. This is safe because the only software that
relies on clearing unit attentions is the Android Trusty software and
because support for handling unit attentions has been added in the Trusty software.

See also https://lore.kernel.org/linux-scsi/20210930124224.114031-2-adrian.hunter@intel.com/

Note that, should apply "scsi: ufs: retry START_STOP on UNIT_ATTENTION" before
this patch, since this patch gives UNIT ATTENTION to scsi_execute(START_STOP).

Bug: 194712579
(cherry picked from commit edc0596c
        git://git.kernel.org/pub/scm/linux/kernel/git/mkp/scsi.git for-next)
Link: https://lore.kernel.org/r/20211001182015.1347587-3-jaegeuk@kernel.org


Fixes: aa53f580 ("scsi: ufs: Minor adjustments to error handling")
Cc: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: default avatarBart Van Assche <bvanassche@google.com>
Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
Change-Id: I73656b8b6773558dc7a552700d283c1ae6dc25f7
Bug: 207618707
Signed-off-by: default avatarBart Van Assche <bvanassche@google.com>
parent ad6511e6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment