netfs: Add write_begin helper
Add a helper to do the pre-reading work for the netfs write_begin address space op. Changes v6: - Fixed a missing rreq put in netfs_write_begin()[3]. - Use DEFINE_READAHEAD()[4]. v5: - Made the wait for PG_fscache in netfs_write_begin() killable[2]. v4: - Added flag to netfs_subreq_terminated() to indicate that the caller may have been running async and stuff that might sleep needs punting to a workqueue (can't use in_softirq()[1]). Signed-off-by:David Howells <dhowells@redhat.com> Reviewed-and-tested-by:
Jeff Layton <jlayton@kernel.org> Tested-by:
Dave Wysochanski <dwysocha@redhat.com> Tested-By:
Marc Dionne <marc.dionne@auristor.com> cc: Matthew Wilcox <willy@infradead.org> cc: linux-mm@kvack.org cc: linux-cachefs@redhat.com cc: linux-afs@lists.infradead.org cc: linux-nfs@vger.kernel.org cc: linux-cifs@vger.kernel.org cc: ceph-devel@vger.kernel.org cc: v9fs-developer@lists.sourceforge.net cc: linux-fsdevel@vger.kernel.org Link: https://lore.kernel.org/r/20210216084...
Showing
- fs/netfs/internal.h 2 additions, 0 deletionsfs/netfs/internal.h
- fs/netfs/read_helper.c 164 additions, 0 deletionsfs/netfs/read_helper.c
- fs/netfs/stats.c 8 additions, 3 deletionsfs/netfs/stats.c
- include/linux/netfs.h 8 additions, 0 deletionsinclude/linux/netfs.h
- include/trace/events/netfs.h 3 additions, 1 deletioninclude/trace/events/netfs.h
Please register or sign in to comment