]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commitdiff
sunrpc: eliminate RPC_DEBUG
authorJeff Layton <jlayton@primarydata.com>
Mon, 17 Nov 2014 21:58:04 +0000 (16:58 -0500)
committerTrond Myklebust <trond.myklebust@primarydata.com>
Mon, 24 Nov 2014 22:31:46 +0000 (17:31 -0500)
It's always set to whatever CONFIG_SUNRPC_DEBUG is, so just use that.

Signed-off-by: Jeff Layton <jlayton@primarydata.com>
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
32 files changed:
include/linux/sunrpc/auth.h
include/linux/sunrpc/debug.h
include/linux/sunrpc/sched.h
include/uapi/linux/nfsd/debug.h
net/sunrpc/auth.c
net/sunrpc/auth_generic.c
net/sunrpc/auth_gss/auth_gss.c
net/sunrpc/auth_gss/gss_generic_token.c
net/sunrpc/auth_gss/gss_krb5_crypto.c
net/sunrpc/auth_gss/gss_krb5_keys.c
net/sunrpc/auth_gss/gss_krb5_mech.c
net/sunrpc/auth_gss/gss_krb5_seal.c
net/sunrpc/auth_gss/gss_krb5_seqnum.c
net/sunrpc/auth_gss/gss_krb5_unseal.c
net/sunrpc/auth_gss/gss_krb5_wrap.c
net/sunrpc/auth_gss/gss_mech_switch.c
net/sunrpc/auth_gss/gss_rpc_xdr.h
net/sunrpc/auth_gss/svcauth_gss.c
net/sunrpc/auth_null.c
net/sunrpc/auth_unix.c
net/sunrpc/backchannel_rqst.c
net/sunrpc/clnt.c
net/sunrpc/rpcb_clnt.c
net/sunrpc/sched.c
net/sunrpc/sunrpc_syms.c
net/sunrpc/svc.c
net/sunrpc/sysctl.c
net/sunrpc/xprt.c
net/sunrpc/xprtrdma/rpc_rdma.c
net/sunrpc/xprtrdma/transport.c
net/sunrpc/xprtrdma/verbs.c
net/sunrpc/xprtsock.c

index 8e030075fe7906bbf46db5296e0abaf12c7c6131..a7cbb570cc5c98cb76fe0a8733a1c791bca7419b 100644 (file)
@@ -53,7 +53,7 @@ struct rpc_cred {
        struct rcu_head         cr_rcu;
        struct rpc_auth *       cr_auth;
        const struct rpc_credops *cr_ops;
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
        unsigned long           cr_magic;       /* 0x0f4aa4f0 */
 #endif
        unsigned long           cr_expire;      /* when to gc */
index 9385bd74c8604fb467979c16c164cdcd4723ec83..51143757b8f74a3665612c79943d8027201789cf 100644 (file)
@@ -14,9 +14,6 @@
 /*
  * Enable RPC debugging/profiling.
  */
-#ifdef CONFIG_SUNRPC_DEBUG
-#define  RPC_DEBUG
-#endif
 #ifdef CONFIG_TRACEPOINTS
 #define RPC_TRACEPOINTS
 #endif
@@ -25,7 +22,7 @@
 /*
  * Debugging macros etc
  */
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 extern unsigned int            rpc_debug;
 extern unsigned int            nfs_debug;
 extern unsigned int            nfsd_debug;
@@ -36,7 +33,7 @@ extern unsigned int           nlm_debug;
 #define dprintk_rcu(args...)   dfprintk_rcu(FACILITY, ## args)
 
 #undef ifdebug
-#ifdef RPC_DEBUG                       
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define ifdebug(fac)          if (unlikely(rpc_debug & RPCDBG_##fac))
 
 # define dfprintk(fac, args...)        \
@@ -65,7 +62,7 @@ extern unsigned int           nlm_debug;
 /*
  * Sysctl interface for RPC debugging
  */
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 void           rpc_register_sysctl(void);
 void           rpc_unregister_sysctl(void);
 #endif
index 1a8959944c5f4d56038acb386110cc2c1390903e..fecdbf1b4797be0cad27e524851759db8c57cd11 100644 (file)
@@ -79,7 +79,7 @@ struct rpc_task {
        unsigned short          tk_flags;       /* misc flags */
        unsigned short          tk_timeouts;    /* maj timeouts */
 
-#if defined(RPC_DEBUG) || defined(RPC_TRACEPOINTS)
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG) || defined(RPC_TRACEPOINTS)
        unsigned short          tk_pid;         /* debugging aid */
 #endif
        unsigned char           tk_priority : 2,/* Task priority */
@@ -187,7 +187,7 @@ struct rpc_wait_queue {
        unsigned char           nr;                     /* # tasks remaining for cookie */
        unsigned short          qlen;                   /* total # tasks waiting in queue */
        struct rpc_timer        timer_list;
-#if defined(RPC_DEBUG) || defined(RPC_TRACEPOINTS)
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG) || defined(RPC_TRACEPOINTS)
        const char *            name;
 #endif
 };
@@ -237,7 +237,7 @@ void                rpc_free(void *);
 int            rpciod_up(void);
 void           rpciod_down(void);
 int            __rpc_wait_for_completion_task(struct rpc_task *task, wait_bit_action_f *);
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 struct net;
 void           rpc_show_tasks(struct net *);
 #endif
@@ -251,7 +251,7 @@ static inline int rpc_wait_for_completion_task(struct rpc_task *task)
        return __rpc_wait_for_completion_task(task, NULL);
 }
 
-#if defined(RPC_DEBUG) || defined (RPC_TRACEPOINTS)
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG) || defined (RPC_TRACEPOINTS)
 static inline const char * rpc_qname(const struct rpc_wait_queue *q)
 {
        return ((q && q->name) ? q->name : "unknown");
index a6f453c740b8c42f3c9b040cdf157eef7937e2cf..1fdc95bb2375c5f8c4d7b0d32bb49616a2a62106 100644 (file)
@@ -15,7 +15,7 @@
  * Enable debugging for nfsd.
  * Requires RPC_DEBUG.
  */
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define NFSD_DEBUG            1
 #endif
 
index 383eb919ac0be3ed1348528d59f0bd637cb65bf5..47f38be4155fa9e6c3dbb98147027407645b2e91 100644 (file)
@@ -16,7 +16,7 @@
 #include <linux/sunrpc/gss_api.h>
 #include <linux/spinlock.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_AUTH
 #endif
 
@@ -646,7 +646,7 @@ rpcauth_init_cred(struct rpc_cred *cred, const struct auth_cred *acred,
        cred->cr_auth = auth;
        cred->cr_ops = ops;
        cred->cr_expire = jiffies;
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
        cred->cr_magic = RPCAUTH_CRED_MAGIC;
 #endif
        cred->cr_uid = acred->uid;
index 6f6b829c9e8ee2bab63ba5f30d03d3c39dc5ba52..41248b1820c778e2e2dd6dc89c3437692673d7cd 100644 (file)
@@ -14,7 +14,7 @@
 #include <linux/sunrpc/debug.h>
 #include <linux/sunrpc/sched.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_AUTH
 #endif
 
index 53ed8d3f88970a877b2799e6ecb2dc9de6893304..dace13d7638ee885729390838c97788721b75fc9 100644 (file)
@@ -66,7 +66,7 @@ static unsigned int gss_expired_cred_retry_delay = GSS_RETRY_EXPIRED;
 #define GSS_KEY_EXPIRE_TIMEO 240
 static unsigned int gss_key_expire_timeo = GSS_KEY_EXPIRE_TIMEO;
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_AUTH
 #endif
 
index c586e92bcf7614dc370d1011c037230ce8efc94f..254defe446a73ae371b2d6a04e6bb561fc2d727f 100644 (file)
@@ -38,7 +38,7 @@
 #include <linux/sunrpc/gss_asn1.h>
 
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY        RPCDBG_AUTH
 #endif
 
index f5ed9f6ece0699cbc89208f278554962f9409912..b5408e8a37f2baddf9979bdac2882d8eb5f8c27f 100644 (file)
@@ -45,7 +45,7 @@
 #include <linux/sunrpc/gss_krb5.h>
 #include <linux/sunrpc/xdr.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY        RPCDBG_AUTH
 #endif
 
index 24589bd2a4b600cae5fdb8f5c0f54fb5198e2115..234fa8d0fd9bf80cc28c3d88ae94037122ca422c 100644 (file)
@@ -61,7 +61,7 @@
 #include <linux/sunrpc/xdr.h>
 #include <linux/lcm.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY        RPCDBG_AUTH
 #endif
 
index 0d3c158ef8fa9e332eea86e72cc9c2b127619bd3..28db442a0034ad601d1a4cc2f2f82dc16a32a3da 100644 (file)
@@ -45,7 +45,7 @@
 #include <linux/crypto.h>
 #include <linux/sunrpc/gss_krb5_enctypes.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_AUTH
 #endif
 
index 42768e5c3994e3d4570bdea259ab6c7f658f76c0..1d74d653e6c058cfbf3669cf9258e14b6002d6b0 100644 (file)
@@ -64,7 +64,7 @@
 #include <linux/random.h>
 #include <linux/crypto.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY        RPCDBG_AUTH
 #endif
 
index 62ac90c62cb12a8b7fb61d814aef5dbfd0a3b94c..20d55c793eb657203e40b90779ceb361e2391c32 100644 (file)
@@ -35,7 +35,7 @@
 #include <linux/sunrpc/gss_krb5.h>
 #include <linux/crypto.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY        RPCDBG_AUTH
 #endif
 
index 6c981ddc19f89a35115c823a1acf743eca61844d..dcf9515d9aef2885ed7aadca352d97f0965e3d1e 100644 (file)
@@ -62,7 +62,7 @@
 #include <linux/sunrpc/gss_krb5.h>
 #include <linux/crypto.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY        RPCDBG_AUTH
 #endif
 
index 4b614c604fe09afd8a7ef03c635662d2117d05db..ca7e92a32f84920036c124732d71e029a9f0ce4c 100644 (file)
@@ -35,7 +35,7 @@
 #include <linux/pagemap.h>
 #include <linux/crypto.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_AUTH
 #endif
 
index 92d5ab99fbf3d3072063c3f611931ab2a9826fc9..7063d856a598e3c4f1201c5df26ce86c6158538d 100644 (file)
@@ -46,7 +46,7 @@
 #include <linux/sunrpc/gss_api.h>
 #include <linux/sunrpc/clnt.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY        RPCDBG_AUTH
 #endif
 
index 685a688f3d8aed9ae3eba23d413f3e58520a217f..9d88c6239f01429b59cc2bb64cbac3abb3329f43 100644 (file)
@@ -25,7 +25,7 @@
 #include <linux/sunrpc/clnt.h>
 #include <linux/sunrpc/xprtsock.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_AUTH
 #endif
 
index c548ab213f766c94d83e3ee8f645d3a9baaafd57..de856ddf5fed7fe531eb99661e00f6a3ba39d52f 100644 (file)
@@ -51,7 +51,7 @@
 #include "gss_rpc_upcall.h"
 
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_AUTH
 #endif
 
index 712c123e04e9ec43464581115b7bfb4cf42e514b..c2a2b584a056ab3b716b985ebf52058f3326fd37 100644 (file)
@@ -10,7 +10,7 @@
 #include <linux/module.h>
 #include <linux/sunrpc/clnt.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_AUTH
 #endif
 
@@ -138,7 +138,7 @@ struct rpc_cred null_cred = {
        .cr_ops         = &null_credops,
        .cr_count       = ATOMIC_INIT(1),
        .cr_flags       = 1UL << RPCAUTH_CRED_UPTODATE,
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
        .cr_magic       = RPCAUTH_CRED_MAGIC,
 #endif
 };
index d5d692366294bacf976ed53fbb83fb1ecbb5ef61..4feda2d0a8333eb6a280521b0dc187cae84e6621 100644 (file)
@@ -25,7 +25,7 @@ struct unx_cred {
 
 #define UNX_WRITESLACK         (21 + (UNX_MAXNODENAME >> 2))
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_AUTH
 #endif
 
index 9761a0da964d81d85a322086ea6c89a1e75b9124..651f49ab601fbdd75eed30ddc0a29c9cb4369e54 100644 (file)
@@ -27,7 +27,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 #include <linux/export.h>
 #include <linux/sunrpc/bc_xprt.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 #define RPCDBG_FACILITY        RPCDBG_TRANS
 #endif
 
index 9acd6ce88db7970d9d84b1d28aebe840d415e185..36c64ef460cf7517ec593518f97f8c8e344f5e91 100644 (file)
@@ -42,7 +42,7 @@
 #include "sunrpc.h"
 #include "netns.h"
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_CALL
 #endif
 
@@ -1396,7 +1396,7 @@ rpc_restart_call(struct rpc_task *task)
 }
 EXPORT_SYMBOL_GPL(rpc_restart_call);
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 static const char *rpc_proc_name(const struct rpc_task *task)
 {
        const struct rpc_procinfo *proc = task->tk_msg.rpc_proc;
@@ -2421,7 +2421,7 @@ struct rpc_task *rpc_call_null(struct rpc_clnt *clnt, struct rpc_cred *cred, int
 }
 EXPORT_SYMBOL_GPL(rpc_call_null);
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 static void rpc_show_header(void)
 {
        printk(KERN_INFO "-pid- flgs status -client- --rqstp- "
index 1891a1022c17e9d7d4c1686ff30c2ef13ebbf7b8..05202012bcfca1f205df6284a622c271d95069ac 100644 (file)
@@ -32,7 +32,7 @@
 
 #include "netns.h"
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_BIND
 #endif
 
index fe3441abdbe5a7a95825c93454ed6a7def75f55e..574b2977fc4b8b70429af7292ed8aca884401d6b 100644 (file)
@@ -24,7 +24,7 @@
 
 #include "sunrpc.h"
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 #define RPCDBG_FACILITY                RPCDBG_SCHED
 #endif
 
@@ -258,7 +258,7 @@ static int rpc_wait_bit_killable(struct wait_bit_key *key)
        return 0;
 }
 
-#if defined(RPC_DEBUG) || defined(RPC_TRACEPOINTS)
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG) || defined(RPC_TRACEPOINTS)
 static void rpc_task_set_debuginfo(struct rpc_task *task)
 {
        static atomic_t rpc_pid;
index cd30120de9e4eb7ba413135dd2eb690311d784cb..f632e476ab6c253eac9ace39fe8484c0dfc55553 100644 (file)
@@ -97,7 +97,7 @@ init_sunrpc(void)
        err = register_rpc_pipefs();
        if (err)
                goto out4;
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
        rpc_register_sysctl();
 #endif
        svc_init_xprt_sock();   /* svc sock transport */
@@ -123,7 +123,7 @@ cleanup_sunrpc(void)
        unregister_rpc_pipefs();
        rpc_destroy_mempool();
        unregister_pernet_subsys(&sunrpc_net_ops);
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
        rpc_unregister_sysctl();
 #endif
        rcu_barrier(); /* Wait for completion of call_rcu()'s */
index 371a8bbb43d649be807487b0b87f2ff3f85b2ef4..2783fd80c2297c91ed035ad741ed0bb86cfec1dc 100644 (file)
@@ -1042,7 +1042,7 @@ static void svc_unregister(const struct svc_serv *serv, struct net *net)
 /*
  * dprintk the given error with the address of the client that caused it.
  */
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 static __printf(2, 3)
 void svc_printk(struct svc_rqst *rqstp, const char *fmt, ...)
 {
index c99c58e2ee66155173338a43aec6aff48dc8614e..887f0183b4c67440d2671101d9773781e9b2038f 100644 (file)
@@ -37,7 +37,7 @@ EXPORT_SYMBOL_GPL(nfsd_debug);
 unsigned int   nlm_debug;
 EXPORT_SYMBOL_GPL(nlm_debug);
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 
 static struct ctl_table_header *sunrpc_table_header;
 static struct ctl_table sunrpc_table[];
index 1b2e5e616cae757fe4a8c0b1a5229a8a26982a79..894d071426b2f24b01b852661dd364d5e0e4f28c 100644 (file)
@@ -57,7 +57,7 @@
  * Local variables
  */
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_XPRT
 #endif
 
index 6166c985fe24850b94f4cccb56dfceee6bbd575d..df01d124936c32409f88e872e6e1b3c1bdb2e25c 100644 (file)
 
 #include <linux/highmem.h>
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_TRANS
 #endif
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 static const char transfertypes[][12] = {
        "pure inline",  /* no chunks */
        " read chunk",  /* some argument via rdma read */
index 6a4615dd02618318ce145b95367011150fd35a68..ef58ebadb3aea0b9a41222055292e69cb427c72d 100644 (file)
@@ -55,7 +55,7 @@
 
 #include "xprt_rdma.h"
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_TRANS
 #endif
 
@@ -75,7 +75,7 @@ static unsigned int xprt_rdma_inline_write_padding;
 static unsigned int xprt_rdma_memreg_strategy = RPCRDMA_FRMR;
                 int xprt_rdma_pad_optimize = 0;
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 
 static unsigned int min_slot_table_size = RPCRDMA_MIN_SLOT_TABLE;
 static unsigned int max_slot_table_size = RPCRDMA_MAX_SLOT_TABLE;
@@ -705,7 +705,7 @@ static void __exit xprt_rdma_cleanup(void)
        int rc;
 
        dprintk("RPCRDMA Module Removed, deregister RPC RDMA transport\n");
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
        if (sunrpc_table_header) {
                unregister_sysctl_table(sunrpc_table_header);
                sunrpc_table_header = NULL;
@@ -736,7 +736,7 @@ static int __init xprt_rdma_init(void)
        dprintk("\tPadding %d\n\tMemreg %d\n",
                xprt_rdma_inline_write_padding, xprt_rdma_memreg_strategy);
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
        if (!sunrpc_table_header)
                sunrpc_table_header = register_sysctl_table(sunrpc_table);
 #endif
index 61c41298b4ea7b09b727548bb1a00d71b60d50b9..b92b04083e402e46d91288370c8d602563e75e54 100644 (file)
@@ -57,7 +57,7 @@
  * Globals/Macros
  */
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # define RPCDBG_FACILITY       RPCDBG_TRANS
 #endif
 
@@ -313,7 +313,7 @@ rpcrdma_flush_cqs(struct rpcrdma_ep *ep)
        rpcrdma_sendcq_upcall(ep->rep_attr.send_cq, ep);
 }
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 static const char * const conn[] = {
        "address resolved",
        "address error",
@@ -344,7 +344,7 @@ rpcrdma_conn_upcall(struct rdma_cm_id *id, struct rdma_cm_event *event)
        struct rpcrdma_xprt *xprt = id->context;
        struct rpcrdma_ia *ia = &xprt->rx_ia;
        struct rpcrdma_ep *ep = &xprt->rx_ep;
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
        struct sockaddr_in *addr = (struct sockaddr_in *) &ep->rep_remote_addr;
 #endif
        struct ib_qp_attr attr;
@@ -408,7 +408,7 @@ connected:
                break;
        }
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
        if (connstate == 1) {
                int ird = attr.max_dest_rd_atomic;
                int tird = ep->rep_remote_cma.responder_resources;
index 31c015196a29c228585a0d7f85344fb72147b30b..87ce7e8bb8dc79a60bb5bafa4bbfa86fb9132a7e 100644 (file)
@@ -75,7 +75,7 @@ static unsigned int xs_tcp_fin_timeout __read_mostly = XS_TCP_LINGER_TO;
  * someone else's file names!
  */
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 
 static unsigned int min_slot_table_size = RPC_MIN_SLOT_TABLE;
 static unsigned int max_slot_table_size = RPC_MAX_SLOT_TABLE;
@@ -186,7 +186,7 @@ static struct ctl_table sunrpc_table[] = {
  */
 #define XS_IDLE_DISC_TO                (5U * 60 * HZ)
 
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
 # undef  RPC_DEBUG_DATA
 # define RPCDBG_FACILITY       RPCDBG_TRANS
 #endif
@@ -2991,7 +2991,7 @@ static struct xprt_class  xs_bc_tcp_transport = {
  */
 int init_socket_xprt(void)
 {
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
        if (!sunrpc_table_header)
                sunrpc_table_header = register_sysctl_table(sunrpc_table);
 #endif
@@ -3010,7 +3010,7 @@ int init_socket_xprt(void)
  */
 void cleanup_socket_xprt(void)
 {
-#ifdef RPC_DEBUG
+#if IS_ENABLED(CONFIG_SUNRPC_DEBUG)
        if (sunrpc_table_header) {
                unregister_sysctl_table(sunrpc_table_header);
                sunrpc_table_header = NULL;