From: Greg KH <greg@kroah.com>
To: Sasha Levin <sashal@kernel.org>
Cc: stable@vger.kernel.org, Damien Le Moal <dlemoal@kernel.org>,
Niklas Cassel <cassel@kernel.org>
Subject: Re: [PATCH 6.12.y 1/2] ata: libata-scsi: Return residual for emulated SCSI commands
Date: Sat, 21 Mar 2026 15:39:06 +0100 [thread overview]
Message-ID: <2026032154-malformed-muster-43bb@gregkh> (raw)
In-Reply-To: <20260320215445.132838-1-sashal@kernel.org>
On Fri, Mar 20, 2026 at 05:54:44PM -0400, Sasha Levin wrote:
> From: Damien Le Moal <dlemoal@kernel.org>
>
> [ Upstream commit 5251ae224d8d3caa21b28d12408062b6e75cffad ]
>
> The function ata_scsi_rbuf_fill() used to fill the reply buffer of
> emulated SCSI commands always copies the ATA reply buffer
> (ata_scsi_rbuf) up to the size of the SCSI command buffer (the transfer
> length for the command), even if the reply is shorter than the SCSI
> command buffer. This leads to issuers of the SCSI command to always get
> a result without any residual (resid is always 0) despite the
> potentially shorter reply for the command.
>
> Modify all fill actors used by ata_scsi_rbuf_fill() to return the number
> of bytes filled for the reply and 0 in case of error. Using this value,
> add a call to scsi_set_resid() in ata_scsi_rbuf_fill() to set the
> correct residual for the SCSI command when the reply length is shorter
> than the command buffer.
>
> Signed-off-by: Damien Le Moal <dlemoal@kernel.org>
> Link: https://lore.kernel.org/r/20241022024537.251905-7-dlemoal@kernel.org
> Signed-off-by: Niklas Cassel <cassel@kernel.org>
> Stable-dep-of: e6d7eba23b66 ("ata: libata-scsi: report correct sense field pointer in ata_scsiop_maint_in()")
> Signed-off-by: Sasha Levin <sashal@kernel.org>
> ---
> drivers/ata/libata-scsi.c | 81 +++++++++++++++++++++++----------------
> 1 file changed, 47 insertions(+), 34 deletions(-)
>
BOth of these don't apply :(
prev parent reply other threads:[~2026-03-21 14:41 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-20 17:31 FAILED: patch "[PATCH] ata: libata-scsi: report correct sense field pointer in" failed to apply to 6.12-stable tree gregkh
2026-03-20 21:54 ` [PATCH 6.12.y 1/2] ata: libata-scsi: Return residual for emulated SCSI commands Sasha Levin
2026-03-20 21:54 ` [PATCH 6.12.y 2/2] ata: libata-scsi: report correct sense field pointer in ata_scsiop_maint_in() Sasha Levin
2026-03-21 14:39 ` Greg KH [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2026032154-malformed-muster-43bb@gregkh \
--to=greg@kroah.com \
--cc=cassel@kernel.org \
--cc=dlemoal@kernel.org \
--cc=sashal@kernel.org \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox