[PATCH 2/2] rcu: Use call_rcu_func_to to replace explicit type equivalents

From: Boqun Feng
Date: Wed Jul 29 2015 - 01:30:35 EST


We have call_rcu_func_t for a quite while, but we still use explicit
function pointer type equivalents in some places, this patch replace
these equivalent types with call_rcu_func_t to gain better readability.

Signed-off-by: Boqun Feng <boqun.feng@xxxxxxxxx>
---
kernel/rcu/rcutorture.c | 2 +-
kernel/rcu/tree.h | 3 +--
2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/kernel/rcu/rcutorture.c b/kernel/rcu/rcutorture.c
index 51c8e7f..f9ec6cb 100644
--- a/kernel/rcu/rcutorture.c
+++ b/kernel/rcu/rcutorture.c
@@ -252,7 +252,7 @@ struct rcu_torture_ops {
void (*exp_sync)(void);
unsigned long (*get_state)(void);
void (*cond_sync)(unsigned long oldstate);
- void (*call)(struct rcu_head *head, void (*func)(struct rcu_head *rcu));
+ call_rcu_func_t call;
void (*cb_barrier)(void);
void (*fqs)(void);
void (*stats)(void);
diff --git a/kernel/rcu/tree.h b/kernel/rcu/tree.h
index ad11529..0c33c82 100644
--- a/kernel/rcu/tree.h
+++ b/kernel/rcu/tree.h
@@ -464,8 +464,7 @@ struct rcu_state {
/* shut bogus gcc warning) */
u8 flavor_mask; /* bit in flavor mask. */
struct rcu_data __percpu *rda; /* pointer of percu rcu_data. */
- void (*call)(struct rcu_head *head, /* call_rcu() flavor. */
- void (*func)(struct rcu_head *head));
+ call_rcu_func_t call; /* call_rcu() flavor. */

/* The following fields are guarded by the root rcu_node's lock. */

--
2.4.6

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/