Linux SCSI subsystem development
 help / color / mirror / Atom feed
* [PATCH 0/3] scsi: ufs: Fix UIC result byte and BSG request length handling
@ 2026-10-13 10:29 Stanley Jhu
  2026-10-13 10:29 ` [PATCH 1/3] scsi: ufs: bsg: Validate request_len before accessing request Stanley Jhu
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Stanley Jhu @ 2026-10-13 10:29 UTC (permalink / raw)
  To: Martin K. Petersen, James E.J. Bottomley
  Cc: powenkao, Alim Akhtar, Bart Van Assche, Bean Huo, Peter Wang,
	linux-scsi, linux-kernel

Two ufs-bsg fixes for issues found by fuzzing /dev/bsg/ufs-bsg* with
syzkaller on QEMU's emulated UFS host controller, plus a related fix
for the same UIC result byte problem in the peer DME retry path.

Patch 1 rejects requests shorter than the UFS BSG request structures.
Patch 2 clears the UIC result byte supplied by userspace.
Patch 3 clears the stale UIC result byte before peer DME retries.

Tested on QEMU arm64: the reproducers no longer trigger.

Stanley Jhu (3):
  scsi: ufs: bsg: Validate request_len before accessing request
  scsi: ufs: bsg: Clear the UIC result byte before sending UIC commands
  scsi: ufs: core: Clear stale UIC result byte before peer DME retries

 drivers/ufs/core/ufs_bsg.c | 9 +++++++++
 drivers/ufs/core/ufshcd.c  | 2 ++
 2 files changed, 11 insertions(+)

-- 
2.56.0.385.gd3acb90ef8-goog

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2026-10-13 10:48 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-13 10:29 [PATCH 0/3] scsi: ufs: Fix UIC result byte and BSG request length handling Stanley Jhu
2026-10-13 10:29 ` [PATCH 1/3] scsi: ufs: bsg: Validate request_len before accessing request Stanley Jhu
2026-10-13 10:44   ` sashiko-bot
2026-10-13 10:29 ` [PATCH 2/3] scsi: ufs: bsg: Clear the UIC result byte before sending UIC commands Stanley Jhu
2026-10-13 10:29 ` [PATCH 3/3] scsi: ufs: core: Clear stale UIC result byte before peer DME retries Stanley Jhu
2026-10-13 10:41   ` sashiko-bot
2026-10-13 10:48     ` Stanley Jhu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox