From: Sergey Shtylyov <sergei.shtylyov@gmail.com>
To: Oliver Neukum <oneukum@suse.com>,
gregkh@linuxfoundation.org, linux-usb@vger.kernel.org,
luca.cecchi.info@gmail.com
Subject: Re: [PATCH] usb: uas: do not leak error codes from usb_alloc_streams()
Date: Thu, 8 Oct 2026 19:23:13 +0300 [thread overview]
Message-ID: <08da0196-6201-4b5c-bffc-243a0250f632@gmail.com> (raw)
In-Reply-To: <20261008132711.211908-1-oneukum@suse.com>
On 10/8/26 4:27 PM, Oliver Neukum wrote:
> While a UAS device is undergoing a reset not triggered by
> the SCSI layer there is a short window in the error case
> of reallocating streams during which internal error codes
> of the USB layer are exported as nonsensical queue depths.
>
> The error has been noticed by Sashiko in a different
> context, but it is a general issue.
>
> Fixes: 4de7a3735bdc4 ("uas: Fix reset handling for externally triggered reset")
> Signed-off-by: Oliver Neukum <oneukum@suse.com>
> ---
> drivers/usb/storage/uas.c | 8 +++++---
> 1 file changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/usb/storage/uas.c b/drivers/usb/storage/uas.c
> index 265162981269..3f69e9de9b61 100644
> --- a/drivers/usb/storage/uas.c
> +++ b/drivers/usb/storage/uas.c
> @@ -983,10 +983,12 @@ static int uas_configure_endpoints(struct uas_dev_info *devinfo)
> devinfo->qdepth = 32;
> devinfo->use_streams = 0;
> } else {
> - devinfo->qdepth = usb_alloc_streams(devinfo->intf, eps + 1,
> + r = usb_alloc_streams(devinfo->intf, eps + 1,
> 3, MAX_CMNDS, GFP_NOIO);
This line now needs to be realigned...
[...]
MBR, Sergey
prev parent reply other threads:[~2026-10-08 16:23 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-08 13:27 [PATCH] usb: uas: do not leak error codes from usb_alloc_streams() Oliver Neukum
2026-10-08 13:45 ` sashiko-bot
2026-10-08 16:23 ` Sergey Shtylyov [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=08da0196-6201-4b5c-bffc-243a0250f632@gmail.com \
--to=sergei.shtylyov@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-usb@vger.kernel.org \
--cc=luca.cecchi.info@gmail.com \
--cc=oneukum@suse.com \
/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