Message ID | 1332144734-9375-2-git-send-email-laijs@cn.fujitsu.com |
---|---|
State | New |
Headers | show |
diff --git a/kernel/srcu.c b/kernel/srcu.c index 1bed654..9e86ed7 100644 --- a/kernel/srcu.c +++ b/kernel/srcu.c @@ -108,7 +108,6 @@ static unsigned long srcu_readers_active_idx(struct srcu_struct *sp, int idx) static bool srcu_readers_active_idx_check(struct srcu_struct *sp, int idx) { - int cpu; unsigned long seq; seq = srcu_readers_seq_idx(sp, idx); @@ -186,7 +185,7 @@ static int srcu_readers_active(struct srcu_struct *sp) sum += ACCESS_ONCE(per_cpu_ptr(sp->per_cpu_ref, cpu)->c[0]); sum += ACCESS_ONCE(per_cpu_ptr(sp->per_cpu_ref, cpu)->c[1]); } - return sum & SRCU_REF_MASK; + return sum; } /**
After patch "implement Peter's checking algorithm" applied, SRCU_REF_MASK is not existed. Also remove unused @cpu in srcu_readers_active_idx_check(). Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com> --- kernel/srcu.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-)