Thread (4 messages) 4 messages, 2 authors, 2023-01-10
STALE1255d

[PATCH v1 0/2] add support for IO_ADVISE

From: Jorge Mora <hidden>
Date: 2023-01-10 18:53:42

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(+)

-- 
2.31.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help