Skip to content

RFC PNFS Read and Write Cleanups

Anna Schumaker linux-nfs 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest12 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/12nfs: Create a common pnfs_pageio_reset_mds() functionfs/nfs/blocklayout/blocklayout.c fs/nfs/internal.h fs/nfs/nfs4filelayout.c +5 more+16 -250 replies
2/12nfs: Create a common pnfs_generic_pg_init() functionfs/nfs/pnfs.c+28 -330 replies
3/12nfs: Create a common pnfs_ld_handle_rw_error() functionfs/nfs/pnfs.c+13 -250 replies
4/12nfs: Create a common pnfs_ld_rw_done()fs/nfs/pnfs.c+14 -120 replies
5/12nfs: Create a common pnfs_through_mds() functionfs/nfs/pnfs.c+14 -260 replies
6/12nfs: merge pnfs_try_to_write_data() and pnfs_do_write()fs/nfs/pnfs.c+7 -210 replies
7/12nfs: merge pnfs_try_to_read_data() and pnfs_do_read()fs/nfs/pnfs.c+7 -210 replies
8/12nfs: create a common pnfs_do_rw() functionfs/nfs/pnfs.c+23 -220 replies
9/12nfs: create a common pnfs_pgiohdr_free functionfs/nfs/pnfs.c+8 -160 replies
10/12nfs: Split up generic_pg_pgiosfs/nfs/internal.h fs/nfs/pagelist.c+23 -50 replies
11/12nfs: pnfs can use nfs_generic_pgios_common() too!fs/nfs/pnfs.c+8 -330 replies
12/12nfs: Create a common pnfs_generic_rwpages() functionfs/nfs/pnfs.c+14 -120 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [RFC 00/12] PNFS Read and Write Cleanups

There is a lot of duplicate code in pnfs.c that can be cleaned up to share more code. This patch set goes through each function one at a time and merges read and write code together wherever possible. In the end I'm passing around a few function pointers. Would it be better to use a function pointer struct instead?

These patches still need a lot of testing and are not ready for merge yet (hence the RFC). I just wanted to send out a preview of the changes I've made so far.

Questions, comments and thoughts are appreciated!

Anna

Anna Schumaker (12):
nfs: Create a common pnfs_pageio_reset_mds() function
nfs: Create a common pnfs_generic_pg_init() function
nfs: Create a common pnfs_ld_handle_rw_error() function
nfs: Create a common pnfs_ld_rw_done()
nfs: Create a common pnfs_through_mds() function
nfs: merge pnfs_try_to_write_data() and pnfs_do_write()
nfs: merge pnfs_try_to_read_data() and pnfs_do_read()
nfs: create a common pnfs_do_rw() function
nfs: create a common pnfs_pgiohdr_free function
nfs: Split up generic_pg_pgios
nfs: pnfs can use nfs_generic_pgios_common() too!
nfs: Create a common pnfs_generic_rwpages() function

 fs/nfs/blocklayout/blocklayout.c |   4 +-
 fs/nfs/internal.h                |   6 +-
 fs/nfs/nfs4filelayout.c          |   4 +-
 fs/nfs/pagelist.c                |  25 +++-
 fs/nfs/pnfs.c                    | 297 ++++++++++++++-------------------------
 fs/nfs/pnfs.h                    |   1 +
 fs/nfs/read.c                    |   7 -
 fs/nfs/write.c                   |   8 --
 8 files changed, 138 insertions(+), 214 deletions(-)
Signature · 1 line
1.9.2