1
0
Fork 0

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>
hifive-unleashed-5.1
Somya Anand 2015-03-21 18:20:24 +05:30 committed by Greg Kroah-Hartman
parent 8e76e695f7
commit 28b9d6f14d
1 changed files with 6 additions and 6 deletions

View File

@ -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) \
({ \