Merge tag 'nfs-for-5.8-1' of git://git.linux-nfs.org/projects/anna/linux-nfs
authorLinus Torvalds <torvalds@linux-foundation.org>
Thu, 11 Jun 2020 19:22:41 +0000 (12:22 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 11 Jun 2020 19:22:41 +0000 (12:22 -0700)
Pull NFS client updates from Anna Schumaker:
 "New features and improvements:
   - Sunrpc receive buffer sizes only change when establishing a GSS credentials
   - Add more sunrpc tracepoints
   - Improve on tracepoints to capture internal NFS I/O errors

  Other bugfixes and cleanups:
   - Move a dprintk() to after a call to nfs_alloc_fattr()
   - Fix off-by-one issues in rpc_ntop6
   - Fix a few coccicheck warnings
   - Use the correct SPDX license identifiers
   - Fix rpc_call_done assignment for BIND_CONN_TO_SESSION
   - Replace zero-length array with flexible array
   - Remove duplicate headers
   - Set invalid blocks after NFSv4 writes to update space_used attribute
   - Fix direct WRITE throughput regression"

* tag 'nfs-for-5.8-1' of git://git.linux-nfs.org/projects/anna/linux-nfs: (27 commits)
  NFS: Fix direct WRITE throughput regression
  SUNRPC: rpc_xprt lifetime events should record xprt->state
  xprtrdma: Make xprt_rdma_slot_table_entries static
  nfs: set invalid blocks after NFSv4 writes
  NFS: remove redundant initialization of variable result
  sunrpc: add missing newline when printing parameter 'auth_hashtable_size' by sysfs
  NFS: Add a tracepoint in nfs_set_pgio_error()
  NFS: Trace short NFS READs
  NFS: nfs_xdr_status should record the procedure name
  SUNRPC: Set SOFTCONN when destroying GSS contexts
  SUNRPC: rpc_call_null_helper() should set RPC_TASK_SOFT
  SUNRPC: rpc_call_null_helper() already sets RPC_TASK_NULLCREDS
  SUNRPC: trace RPC client lifetime events
  SUNRPC: Trace transport lifetime events
  SUNRPC: Split the xdr_buf event class
  SUNRPC: Add tracepoint to rpc_call_rpcerror()
  SUNRPC: Update the RPC_SHOW_SOCKET() macro
  SUNRPC: Update the rpc_show_task_flags() macro
  SUNRPC: Trace GSS context lifetimes
  SUNRPC: receive buffer size estimation values almost never change
  ...

1  2 
include/trace/events/rpcrdma.h
include/trace/events/sunrpc.h
net/sunrpc/svc_xprt.c

Simple merge
  #include <linux/net.h>
  #include <linux/tracepoint.h>
  
- DECLARE_EVENT_CLASS(xdr_buf_class,
 +TRACE_DEFINE_ENUM(SOCK_STREAM);
 +TRACE_DEFINE_ENUM(SOCK_DGRAM);
 +TRACE_DEFINE_ENUM(SOCK_RAW);
 +TRACE_DEFINE_ENUM(SOCK_RDM);
 +TRACE_DEFINE_ENUM(SOCK_SEQPACKET);
 +TRACE_DEFINE_ENUM(SOCK_DCCP);
 +TRACE_DEFINE_ENUM(SOCK_PACKET);
 +
 +#define show_socket_type(type)                                        \
 +      __print_symbolic(type,                                  \
 +              { SOCK_STREAM,          "STREAM" },             \
 +              { SOCK_DGRAM,           "DGRAM" },              \
 +              { SOCK_RAW,             "RAW" },                \
 +              { SOCK_RDM,             "RDM" },                \
 +              { SOCK_SEQPACKET,       "SEQPACKET" },          \
 +              { SOCK_DCCP,            "DCCP" },               \
 +              { SOCK_PACKET,          "PACKET" })
 +
 +/* This list is known to be incomplete, add new enums as needed. */
 +TRACE_DEFINE_ENUM(AF_UNSPEC);
 +TRACE_DEFINE_ENUM(AF_UNIX);
 +TRACE_DEFINE_ENUM(AF_LOCAL);
 +TRACE_DEFINE_ENUM(AF_INET);
 +TRACE_DEFINE_ENUM(AF_INET6);
 +
 +#define rpc_show_address_family(family)                               \
 +      __print_symbolic(family,                                \
 +              { AF_UNSPEC,            "AF_UNSPEC" },          \
 +              { AF_UNIX,              "AF_UNIX" },            \
 +              { AF_LOCAL,             "AF_LOCAL" },           \
 +              { AF_INET,              "AF_INET" },            \
 +              { AF_INET6,             "AF_INET6" })
 +
+ DECLARE_EVENT_CLASS(rpc_xdr_buf_class,
        TP_PROTO(
+               const struct rpc_task *task,
                const struct xdr_buf *xdr
        ),
  
@@@ -906,11 -913,17 +906,11 @@@ int svc_send(struct svc_rqst *rqstp
        xb->len = xb->head[0].iov_len +
                xb->page_len +
                xb->tail[0].iov_len;
-       trace_svc_sendto(xb);
+       trace_svc_xdr_sendto(rqstp, xb);
 -
 -      /* Grab mutex to serialize outgoing data. */
 -      mutex_lock(&xprt->xpt_mutex);
        trace_svc_stats_latency(rqstp);
 -      if (test_bit(XPT_DEAD, &xprt->xpt_flags)
 -                      || test_bit(XPT_CLOSE, &xprt->xpt_flags))
 -              len = -ENOTCONN;
 -      else
 -              len = xprt->xpt_ops->xpo_sendto(rqstp);
 -      mutex_unlock(&xprt->xpt_mutex);
 +
 +      len = xprt->xpt_ops->xpo_sendto(rqstp);
 +
        trace_svc_send(rqstp, len);
        svc_xprt_release(rqstp);