Skip to content

smb: client: fix "df: Resource temporarily unavailable" on 5.10 stable kernel

[email protected] linux-cifs linux-doc lkml stable 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 6 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2stddef: Introduce DECLARE_FLEX_ARRAY() helperinclude/linux/stddef.h include/uapi/linux/stddef.h scripts/kernel-doc+31 -10 replies
2/2smb3: Replace smb2pdu 1-element arrays with flex-arraysfs/cifs/smb2misc.c fs/cifs/smb2ops.c fs/cifs/smb2pdu.c +1 more+38 -330 replies

Reviews trailers per patch

1 of 2 patches has a Reviewed-by or Acked-by.

PatchNamjae Jeon
1/2
2/2R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/2] smb: client: fix "df: Resource temporarily unavailable" on 5.10 stable kernel

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/[email protected]/

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