From: David Howells <dhowells@redhat.com>
To: Jeff Layton <jlayton@kernel.org>, Steve French <smfrench@gmail.com>
Cc: David Howells <dhowells@redhat.com>,
Matthew Wilcox <willy@infradead.org>,
Paulo Alcantara <pc@manguebit.com>,
Shyam Prasad N <sprasad@microsoft.com>,
Tom Talpey <tom@talpey.com>,
Christian Brauner <christian@brauner.io>,
linux-cachefs@redhat.com, linux-afs@lists.infradead.org,
linux-cifs@vger.kernel.org, linux-nfs@vger.kernel.org,
ceph-devel@vger.kernel.org, v9fs@lists.linux.dev,
linux-fsdevel@vger.kernel.org, linux-mm@kvack.org,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH v4 00/13] netfs, cifs: Delegate high-level I/O to netfslib
Date: Wed, 13 Dec 2023 15:41:26 +0000 [thread overview]
Message-ID: <20231213154139.432922-1-dhowells@redhat.com> (raw)
Hi Steve,
Here are patches to convert cifs to use my netfslib helpers. With this I can
run a certain amount of xfstests on CIFS, though I'm running into occasional
ksmbd issues and not all the tests work correctly because of fallocate issues.
The patches remove around 2000 lines from CIFS
This stacks on top of my netfs-lib branch[1].
CIFS notes:
(1) CIFS is made to use unbuffered I/O for unbuffered caching modes and
write-through caching for cache=strict.
(2) Various cifs fallocate() function implementations needed fixing and
those fixes are upstream or on the way.
(3) It should be possible to turn on multipage folio support in CIFS now.
(4) The then-unused CIFS code is removed in three patches, not one, to
avoid the git patch generator from producing confusing patches in
which it thinks code is being moved around rather than just being
removed.
The patches can be found here also:
https://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs.git/log/?h=cifs-netfs
Changes
=======
ver #4)
- Slimmed down the branch:
- Split the cifs-related patches off to a separate branch (cifs-netfs)
- Deferred the content-encryption to the in-progress ceph changes.
- Deferred the use-PG_writeback rather than PG_fscache patch
- Rebased on a later linux-next with afs-rotation patches.
ver #3)
- Moved the fscache module into netfslib to avoid export cycles.
- Fixed a bunch of bugs.
- Got CIFS to pass as much of xfstests as possible.
- Added a patch to make 9P use all the helpers.
- Added a patch to stop using PG_fscache, but rather dirty pages on
reading and have writepages write to the cache.
ver #2)
- Folded the addition of NETFS_RREQ_NONBLOCK/BLOCKED into first patch that
uses them.
- Folded addition of rsize member into first user.
- Don't set rsize in ceph (yet) and set it in kafs to 256KiB. cifs sets
it dynamically.
- Moved direct_bv next to direct_bv_count in struct netfs_io_request and
labelled it with a __counted_by().
- Passed flags into netfs_xa_store_and_mark() rather than two bools.
- Removed netfs_set_up_buffer() as it wasn't used.
David
Link: https://lore.kernel.org/r/20231213152350.431591-1-dhowells@redhat.com/ [1]
Link: https://lore.kernel.org/r/20231013160423.2218093-1-dhowells@redhat.com/ # v1
Link: https://lore.kernel.org/r/20231117211544.1740466-1-dhowells@redhat.com/ # v2
Link: https://lore.kernel.org/r/20231207212206.1379128-1-dhowells@redhat.com/ # v3
David Howells (13):
netfs: Rearrange netfs_io_subrequest to put request pointer first
cifs: Replace cifs_readdata with a wrapper around netfs_io_subrequest
cifs: Share server EOF pos with netfslib
cifs: Set zero_point in the copy_file_range() and remap_file_range()
cifs: Replace cifs_writedata with a wrapper around netfs_io_subrequest
cifs: Use more fields from netfs_io_subrequest
cifs: Make wait_mtu_credits take size_t args
cifs: Implement netfslib hooks
cifs: Move cifs_loose_read_iter() and cifs_file_write_iter() to file.c
cifs: Cut over to using netfslib
cifs: Remove some code that's no longer used, part 1
cifs: Remove some code that's no longer used, part 2
cifs: Remove some code that's no longer used, part 3
fs/netfs/buffered_write.c | 3 +
fs/netfs/io.c | 7 +-
fs/smb/client/Kconfig | 1 +
fs/smb/client/cifsfs.c | 86 +-
fs/smb/client/cifsfs.h | 10 +-
fs/smb/client/cifsglob.h | 59 +-
fs/smb/client/cifsproto.h | 14 +-
fs/smb/client/cifssmb.c | 111 +-
fs/smb/client/file.c | 2908 ++++++----------------------------
fs/smb/client/fscache.c | 109 --
fs/smb/client/fscache.h | 54 -
fs/smb/client/inode.c | 27 +-
fs/smb/client/smb2ops.c | 28 +-
fs/smb/client/smb2pdu.c | 168 +-
fs/smb/client/smb2proto.h | 5 +-
fs/smb/client/trace.h | 144 +-
fs/smb/client/transport.c | 17 +-
include/linux/netfs.h | 3 +-
include/trace/events/netfs.h | 1 +
19 files changed, 883 insertions(+), 2872 deletions(-)
next reply other threads:[~2023-12-13 15:41 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-13 15:41 David Howells [this message]
2023-12-13 15:41 ` [PATCH v4 01/13] netfs: Rearrange netfs_io_subrequest to put request pointer first David Howells
2023-12-13 15:41 ` [PATCH v4 02/13] cifs: Replace cifs_readdata with a wrapper around netfs_io_subrequest David Howells
2023-12-13 15:41 ` [PATCH v4 03/13] cifs: Share server EOF pos with netfslib David Howells
2023-12-13 15:41 ` [PATCH v4 04/13] cifs: Set zero_point in the copy_file_range() and remap_file_range() David Howells
2023-12-13 15:41 ` [PATCH v4 05/13] cifs: Replace cifs_writedata with a wrapper around netfs_io_subrequest David Howells
2023-12-13 15:41 ` [PATCH v4 06/13] cifs: Use more fields from netfs_io_subrequest David Howells
2023-12-13 15:41 ` [PATCH v4 07/13] cifs: Make wait_mtu_credits take size_t args David Howells
2023-12-13 15:41 ` [PATCH v4 08/13] cifs: Implement netfslib hooks David Howells
2023-12-13 15:41 ` [PATCH v4 09/13] cifs: Move cifs_loose_read_iter() and cifs_file_write_iter() to file.c David Howells
2023-12-13 15:41 ` [PATCH v4 10/13] cifs: Cut over to using netfslib David Howells
2023-12-13 15:41 ` [PATCH v4 11/13] cifs: Remove some code that's no longer used, part 1 David Howells
2023-12-13 15:41 ` [PATCH v4 12/13] cifs: Remove some code that's no longer used, part 2 David Howells
2023-12-13 15:41 ` [PATCH v4 13/13] cifs: Remove some code that's no longer used, part 3 David Howells
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=20231213154139.432922-1-dhowells@redhat.com \
--to=dhowells@redhat.com \
--cc=ceph-devel@vger.kernel.org \
--cc=christian@brauner.io \
--cc=jlayton@kernel.org \
--cc=linux-afs@lists.infradead.org \
--cc=linux-cachefs@redhat.com \
--cc=linux-cifs@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linux-nfs@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pc@manguebit.com \
--cc=smfrench@gmail.com \
--cc=sprasad@microsoft.com \
--cc=tom@talpey.com \
--cc=v9fs@lists.linux.dev \
--cc=willy@infradead.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).