scsi: ufs: fix NULL pointer dereference when aborting command
If there is a race between command completion and the scsi timeout,
the scsi timeout ignores the command completion and proceed with
aborting the command. Since the command completion happen in
interrupt context, it would be prioritized and ufshcd might free
resources before abort initiated by scsi is completed. Hence, if the
abort routine refers to the command info saved in lrbp it would cause
NULL pointer dereference. Fix this by using the command info provided
by scsi layer in the ufshcd_abort() argument.
Change-Id: Ie915880b1c239ef9080cfb5cb74f19329b3a82d4
Signed-off-by:
Sujit Reddy Thumma <sthumma@codeaurora.org>
Loading
Please register or sign in to comment