]> www.infradead.org Git - users/jedix/linux-maple.git/commit
scsi: ufs: core: Fix the return value documentation
authorBart Van Assche <bvanassche@acm.org>
Fri, 15 Aug 2025 15:58:25 +0000 (08:58 -0700)
committerMartin K. Petersen <martin.petersen@oracle.com>
Tue, 19 Aug 2025 02:15:19 +0000 (22:15 -0400)
commit9ee35fd43f94bf19dbd27cffc213a31314b623d2
treee50666d49acb4286e19ad0e3182b335c724b1c15
parente5203d89d59bfcbe1f348aa0d2dc4449a8ba644c
scsi: ufs: core: Fix the return value documentation

ufshcd_wait_for_dev_cmd() and all its callers can return an OCS error.
OCS errors are represented by positive integers. Remove the WARN_ONCE()
statements that complain about positive error codes and update the
documentation.

Keep the behavior of ufshcd_wait_for_dev_cmd() because this return value
may end be passed as the second argument of bsg_job_done() and
bsg_job_done() handles positive and negative error codes differently.

Cc: Peter Wang <peter.wang@mediatek.com>
Fixes: cc59f3b68542 ("scsi: ufs: core: Improve return value documentation")
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Link: https://lore.kernel.org/r/20250815155842.472867-4-bvanassche@acm.org
Reviewed-by: Peter Wang <peter.wang@mediatek.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/ufs/core/ufshcd.c