mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Paulo Alcantara <pc@manguebit.org>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org, linux-cifs@vger.kernel.org
Subject: [GIT PULL] smb client fixes for 7.3-rc6
Date: Fri, 02 Oct 2026 17:42:23 -0300	[thread overview]
Message-ID: <7af974fcbddc7e739dc7d18aaf1ea69f@manguebit.org> (raw)

Linus,

Please consider pulling these smb client fixes for v7.3-rc6.  They fix
a series of data corruption and I/O error bugs found by running
generic/363 (fsx) in a loop against Windows Server 2022 and Samba.
All -stable material.

Thanks,
Paulo

----------------------------------------------------------------
The following changes since commit f14572c203d57492e1d4e5d7851a3b143e083b82:

  Merge tag 'cifs-fixes-7.3-rc5' of https://git.manguebit.org/linux (2026-09-25 13:30:04 -0700)

are available in the Git repository at:

  https://git.manguebit.org/linux tags/cifs-fixes-7.3-rc6

for you to fetch changes up to 19465a9aeb664f1d710d0d22c07c31bfb7c85446:

  smb: client: split cifsFileInfo bitfields to avoid shared-byte RMW races (2026-09-30 23:17:30 -0300)

----------------------------------------------------------------
smb client fixes for v7.3-rc6

 - Stop data dirtied past EOF through an mmap from reappearing as file
   content once the file is extended by a write, truncate, zero range,
   copy range or clone range

 - Flush dirty data and drain in-flight I/O before operations that
   assume the pagecache and the server agree on the file: querying
   allocated ranges, the O_TRUNC open, interior zero range, and
   server-side copy/clone

 - Stop a genuine size-extending zero range or preallocate from being
   refused with -EOPNOTSUPP when the inode is not read caching, by
   querying the server's authoritative EOF instead of trusting a stale
   cached i_size

 - Zero the untransferred tail of a short read, both in the netfs
   read-gaps path (where stale folio content could otherwise be written
   back to the server) and in the DIO/unbuffered read collector, and
   tell a real EOF apart from a stale cached remote_i_size after a lease
   downgrade

 - Require stable pages on signed connections so a buffered write can't
   modify a folio whose signature has already been computed and is in
   flight, which the server rejected with STATUS_ACCESS_DENIED and the
   client surfaced as -EIO

 - Split several cifsFileInfo flags out of a shared bitfield byte so
   concurrent updates taken under different locks no longer clobber each
   other through a byte-level RMW

----------------------------------------------------------------
Frank Sorenson (1):
      smb: client: split cifsFileInfo bitfields to avoid shared-byte RMW races

Paulo Alcantara (15):
      netfs: clear post-EOF pagecache when extending a file via write
      smb: client: clear post-EOF pagecache when extending a file via truncate
      smb: client: discard post-EOF pagecache when extending a file via zero range
      smb: client: discard post-EOF pagecache when extending a file via copy range
      smb: client: discard post-EOF pagecache when extending a file via clone range
      smb: client: flush and commit data before querying allocated ranges
      smb: client: drain outstanding I/O before truncating on O_TRUNC open
      smb: client: flush dirty data before zeroing a range
      smb: client: drain and invalidate before server-side copy/clone
      smb: client: only require read lease for size-extending zero range
      netfs: zero gaps in read-gaps folio to avoid writing back stale data
      smb: client: only require read lease for size-extending preallocate
      netfs: zero the tail of a short DIO/unbuffered read
      smb: client: distinguish real EOF from a stale remote_i_size on read
      smb: client: require stable pages for signed connections

 Documentation/filesystems/netfs_library.rst |  26 ++++++
 fs/netfs/buffered_read.c                    |   7 ++
 fs/netfs/buffered_write.c                   |   9 ++
 fs/netfs/direct_write.c                     |   9 ++
 fs/netfs/internal.h                         |   2 +
 fs/netfs/misc.c                             |  99 +++++++++++++++++++++
 fs/netfs/read_collect.c                     |  24 +++++
 fs/smb/client/cifsfs.c                      |  41 +++++++--
 fs/smb/client/cifsfs.h                      |   5 +-
 fs/smb/client/cifsglob.h                    |  10 +--
 fs/smb/client/file.c                        |   5 +-
 fs/smb/client/inode.c                       |  24 +++--
 fs/smb/client/smb2ops.c                     | 130 +++++++++++++++++++++-------
 fs/smb/client/smb2pdu.c                     |  10 ++-
 include/linux/netfs.h                       |   2 +
 15 files changed, 347 insertions(+), 56 deletions(-)

             reply	other threads:[~2026-10-02 20:42 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-02 20:42 Paulo Alcantara [this message]
2026-10-02 21:11 ` pr-tracker-bot

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=7af974fcbddc7e739dc7d18aaf1ea69f@manguebit.org \
    --to=pc@manguebit.org \
    --cc=linux-cifs@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.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

all inboxes | Powered by JetHome®