Loading kernel/rcu/tree.c +7 −7 Original line number Diff line number Diff line Loading @@ -597,25 +597,25 @@ static int rcu_future_needs_gp(struct rcu_state *rsp) * The caller must have disabled interrupts to prevent races with * normal callback registry. */ static int static bool cpu_needs_another_gp(struct rcu_state *rsp, struct rcu_data *rdp) { int i; if (rcu_gp_in_progress(rsp)) return 0; /* No, a grace period is already in progress. */ return false; /* No, a grace period is already in progress. */ if (rcu_future_needs_gp(rsp)) return 1; /* Yes, a no-CBs CPU needs one. */ return true; /* Yes, a no-CBs CPU needs one. */ if (!rdp->nxttail[RCU_NEXT_TAIL]) return 0; /* No, this is a no-CBs (or offline) CPU. */ return false; /* No, this is a no-CBs (or offline) CPU. */ if (*rdp->nxttail[RCU_NEXT_READY_TAIL]) return 1; /* Yes, this CPU has newly registered callbacks. */ return true; /* Yes, CPU has newly registered callbacks. */ for (i = RCU_WAIT_TAIL; i < RCU_NEXT_TAIL; i++) if (rdp->nxttail[i - 1] != rdp->nxttail[i] && ULONG_CMP_LT(READ_ONCE(rsp->completed), rdp->nxtcompleted[i])) return 1; /* Yes, CBs for future grace period. */ return 0; /* No grace period needed. */ return true; /* Yes, CBs for future grace period. */ return false; /* No grace period needed. */ } /* Loading Loading
kernel/rcu/tree.c +7 −7 Original line number Diff line number Diff line Loading @@ -597,25 +597,25 @@ static int rcu_future_needs_gp(struct rcu_state *rsp) * The caller must have disabled interrupts to prevent races with * normal callback registry. */ static int static bool cpu_needs_another_gp(struct rcu_state *rsp, struct rcu_data *rdp) { int i; if (rcu_gp_in_progress(rsp)) return 0; /* No, a grace period is already in progress. */ return false; /* No, a grace period is already in progress. */ if (rcu_future_needs_gp(rsp)) return 1; /* Yes, a no-CBs CPU needs one. */ return true; /* Yes, a no-CBs CPU needs one. */ if (!rdp->nxttail[RCU_NEXT_TAIL]) return 0; /* No, this is a no-CBs (or offline) CPU. */ return false; /* No, this is a no-CBs (or offline) CPU. */ if (*rdp->nxttail[RCU_NEXT_READY_TAIL]) return 1; /* Yes, this CPU has newly registered callbacks. */ return true; /* Yes, CPU has newly registered callbacks. */ for (i = RCU_WAIT_TAIL; i < RCU_NEXT_TAIL; i++) if (rdp->nxttail[i - 1] != rdp->nxttail[i] && ULONG_CMP_LT(READ_ONCE(rsp->completed), rdp->nxtcompleted[i])) return 1; /* Yes, CBs for future grace period. */ return 0; /* No grace period needed. */ return true; /* Yes, CBs for future grace period. */ return false; /* No grace period needed. */ } /* Loading