summaryrefslogtreecommitdiffstats
path: root/drivers/staging/lustre
diff options
context:
space:
mode:
authorSomya Anand <somyaanand214@gmail.com>2015-03-21 18:20:24 +0530
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-03-23 22:13:50 +0100
commit28b9d6f14d30eae2d600a3f6deac625f26591820 (patch)
tree58a579ded0d334ae459d517b7c1847e58f3b5e63 /drivers/staging/lustre
parent8e76e695f76c99b97c0949dfafe9cf176bceb0e4 (diff)
downloadop-kernel-dev-28b9d6f14d30eae2d600a3f6deac625f26591820.zip
op-kernel-dev-28b9d6f14d30eae2d600a3f6deac625f26591820.tar.gz
Staging: lustre: Convert macro class_export_rpc_inc into static inline function
This patch converts the macro class_export_rpc_inc into static inline function. This is possible because the types of arguments at all the call sites are same. So, the type of parameter is compatible with the types of the arguments at all of the call sites. Signed-off-by: Somya Anand <somyaanand214@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/lustre')
-rw-r--r--drivers/staging/lustre/lustre/include/obd_class.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/staging/lustre/lustre/include/obd_class.h b/drivers/staging/lustre/lustre/include/obd_class.h
index 4a29261..9f528d4 100644
--- a/drivers/staging/lustre/lustre/include/obd_class.h
+++ b/drivers/staging/lustre/lustre/include/obd_class.h
@@ -222,12 +222,12 @@ extern void (*class_export_dump_hook)(struct obd_export *);
#endif
-#define class_export_rpc_inc(exp) \
-({ \
- atomic_inc(&(exp)->exp_rpc_count); \
- CDEBUG(D_INFO, "RPC GETting export %p : new rpc_count %d\n", \
- (exp), atomic_read(&(exp)->exp_rpc_count)); \
-})
+static inline void class_export_rpc_inc(struct obd_export *exp)
+{
+ atomic_inc(&(exp)->exp_rpc_count);
+ CDEBUG(D_INFO, "RPC GETting export %p : new rpc_count %d\n",
+ (exp), atomic_read(&(exp)->exp_rpc_count));
+}
#define class_export_rpc_dec(exp) \
({ \
OpenPOWER on IntegriCloud