public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: kovalev@altlinux.org
To: stable@vger.kernel.org, linux-doc@vger.kernel.org,
	linux-kernel@vger.kernel.org, linux-cifs@vger.kernel.org,
	samba-technical@lists.samba.org
Cc: keescook@chromium.org, sfrench@samba.org, corbet@lwn.net,
	natechancellor@gmail.com, ndesaulniers@google.com,
	kovalev@altlinux.org
Subject: [PATCH 0/2] smb: client: fix "df: Resource temporarily unavailable" on 5.10 stable kernel
Date: Fri, 26 Jan 2024 22:31:41 +0300	[thread overview]
Message-ID: <20240126193143.245122-1-kovalev@altlinux.org> (raw)

After mounting a remote cifs resource, it becomes unavailable:
df: /mnt/sambashare: Resource temporarily unavailable

It was tested on the following Linux kernels:
Linux altlinux 5.10.208-std-def-alt1
Linux fedora 5.10.208-200.el8.x86_64

The error appeared starting from kernel 5.10.206 after adding
the commit [1] "smb: client: fix OOB in SMB2_query_info_init()",
in which the buffer length increases by 1 as a result of changes:
...
-      iov[0].iov_len = total_len - 1 + input_len;
+      iov[0].iov_len = len;
...

[1] https://patchwork.kernel.org/project/cifs-client/patch/20231213152557.6634-2-pc@manguebit.com/

Error fixed by backported commits in next two patches  adapted for the 5.10 kernel:

[PATCH 1/2] stddef: Introduce DECLARE_FLEX_ARRAY() helper
[PATCH 2/2] smb3: Replace smb2pdu 1-element arrays with flex-arrays


             reply	other threads:[~2024-01-26 19:32 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-26 19:31 kovalev [this message]
2024-01-26 19:31 ` [PATCH 1/2] stddef: Introduce DECLARE_FLEX_ARRAY() helper kovalev
2024-01-26 19:31 ` [PATCH 2/2] smb3: Replace smb2pdu 1-element arrays with flex-arrays kovalev
2024-01-27  0:49 ` [PATCH 0/2] smb: client: fix "df: Resource temporarily unavailable" on 5.10 stable kernel Greg KH
2024-01-27  6:42   ` Harshit Mogalapalli
2024-01-27  8:02     ` kovalev
2024-01-27 13:29       ` Harshit Mogalapalli
2024-01-27 21:20         ` Greg KH
2024-01-27 23:01     ` Steve French

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=20240126193143.245122-1-kovalev@altlinux.org \
    --to=kovalev@altlinux.org \
    --cc=corbet@lwn.net \
    --cc=keescook@chromium.org \
    --cc=linux-cifs@vger.kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=natechancellor@gmail.com \
    --cc=ndesaulniers@google.com \
    --cc=samba-technical@lists.samba.org \
    --cc=sfrench@samba.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