Skip to content

add support for IO_ADVISE

Jorge Mora linux-nfs 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2NFS: add IO_ADVISE operationfs/nfs/nfs42.h fs/nfs/nfs42proc.c fs/nfs/nfs42xdr.c +6 more+221 -01 reply
2/2NFSv4.2 add tracepoint to IO_ADVISEfs/nfs/nfs42proc.c fs/nfs/nfs4trace.h+76 -00 replies

Reviews trailers per patch

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

Read the v1 thread

Cover letter [PATCH v1 0/2] add support for IO_ADVISE

Adds support for using the NFS v4.2 operation IO_ADVISE to send client I/O access pattern hints to the server.

There is a one-to-one correspondence between the advice (POSIX_FADV_*) given in fadvise64() and the bitmap mask sent to the server. Any other advice given, results in just calling generic_fadvise().

The bitmap mask given by the server reply is just ignored since the fadvise64() returns 0 on success. If server replies with more than one bitmap word, only the first word is stored on the nfs42_io_advise_res struct and all other words are ignored.

Added trace point (nfs4_io_advise) for this operation:
nfs4_io_advise: error=0 (OK) fileid=00:32:4217220 \
fhandle=0x4a271991 stateid=0:0x30b83748 offset=0 \
count=200 arg_hints=SEQUENTIAL res_hints=SEQUENTIAL

Jorge Mora (2):
NFS: add IO_ADVISE operation
NFSv4.2 add tracepoint to IO_ADVISE

 fs/nfs/nfs42.h            |  1 +
 fs/nfs/nfs42proc.c        | 68 +++++++++++++++++++++++++++++++
 fs/nfs/nfs42xdr.c         | 84 +++++++++++++++++++++++++++++++++++++++
 fs/nfs/nfs4file.c         | 37 +++++++++++++++++
 fs/nfs/nfs4proc.c         |  1 +
 fs/nfs/nfs4trace.h        | 75 ++++++++++++++++++++++++++++++++++
 fs/nfs/nfs4xdr.c          |  1 +
 include/linux/nfs4.h      |  1 +
 include/linux/nfs_fs_sb.h |  1 +
 include/linux/nfs_xdr.h   | 28 +++++++++++++
 10 files changed, 297 insertions(+)
Signature · 1 line
2.31.1