mirror of
https://github.com/torvalds/linux.git
synced 2026-07-27 17:47:41 +02:00
scsi: ufs: core: Complain if UIC argument 2 is invalid
According to the UFSHCI standard, the lowest byte of UIC argument 2 is an output value. Additionally, ufshcd_uic_cmd_compl() is based on the assumption that the lowest byte of UIC argument 2 is zero. Hence, complain if the result byte is set when a UIC command is submitted. Reviewed-by: Peter Wang <peter.wang@mediatek.com> Signed-off-by: Bart Van Assche <bvanassche@acm.org> Link: https://patch.msgid.link/20260519212135.3130556-3-bvanassche@acm.org Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
parent
727e78887e
commit
9fb4c79322
|
|
@ -2571,6 +2571,7 @@ ufshcd_dispatch_uic_cmd(struct ufs_hba *hba, struct uic_command *uic_cmd)
|
|||
lockdep_assert_held(&hba->uic_cmd_mutex);
|
||||
|
||||
WARN_ON(hba->active_uic_cmd);
|
||||
WARN_ON_ONCE(uic_cmd->argument2 & MASK_UIC_COMMAND_RESULT);
|
||||
|
||||
hba->active_uic_cmd = uic_cmd;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user