Re: [PATCH 1/1] scsi: ufs: remove ucd_rsp_dma_addr and ucd_prdt_dma_addr from ufshcd_lrb

From: Peter Wang (王信友)

Date: Mon Apr 27 2026 - 02:12:05 EST


On Mon, 2026-04-27 at 11:58 +0800, ed.tsai@xxxxxxxxxxxx wrote:
> The offsets stored in utp_transfer_req_desc are in double words on
> hosts without UFSHCD_QUIRK_PRDT_BYTE_GRAN, using them directly to
> compute ucd_rsp_dma_addr and ucd_prdt_dma_addr results in incorrect
> DMA addresses.
>
> Since these fields are only used for error logging, remove them from
> struct ufshcd_lrb and compute directly in ufshcd_print_tr() using
> offsetof(struct utp_transfer_cmd_desc, ...) instead.
>
> Fixes: d5130c5a0932 ("scsi: ufs: Use pre-calculated offsets in
> ufshcd_init_lrb()")
> Cc: stable@xxxxxxxxxxxxxxx
> Link:
> https://lore.kernel.org/all/20260424063603.382328-2-ed.tsai@xxxxxxxxxxxx/
> Signed-off-by: Ed Tsai <ed.tsai@xxxxxxxxxxxx>
> ---

Reviewed-by: Peter Wang <peter.wang@xxxxxxxxxxxx>