Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\rcu\tree.c Create Date:2022-07-28 10:26:02
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Update CPU-local rcu_data state to record the beginnings and ends of* grace periods. The caller must hold the ->lock of the leaf rcu_node* structure corresponding to the current CPU, and must have irqs disabled.

Proto:static bool __note_gp_changes(struct rcu_node *rnp, struct rcu_data *rdp)

Type:bool

Parameter:

TypeParameterName
struct rcu_node *rnp
struct rcu_data *rdp
1392  bool ret = false
1394  offloaded = IS_ENABLED(CONFIG_FOO) evaluates to 1 if CONFIG_FOO is set to 'y' or 'm',* 0 otherwise.(CONFIG_RCU_NOCB_CPU) && Is the specified rcu_segcblist offloaded?
1397  raw_lockdep_assert_held_rcu_node(rnp)
1399  If Track rsp->rcu_gp_seq counter. == Track rsp->rcu_gp_seq. Then Return false
1403  If Has a grace period completed since the time the old gp_seq was collected? || Value for the false possibility is greater at compile time(READ_ONCE(Possible ->gp_seq wrap. )) Then
1405  If Not offloaded Then ret = Move any callbacks whose grace period has completed to the* RCU_DONE_TAIL sublist, then compact the remaining sublists and* assign ->gp_seq numbers to any callbacks in the RCU_NEXT_TAIL* sublist. This function is idempotent, so it does not hurt to
1407  trace_rcu_grace_period(Name of structure. , Track rsp->rcu_gp_seq counter. , Strings used in tracepoints need to be exported via the* tracing system such that tools like perf and trace-cmd can* translate the string address pointers to actual text.("cpuend"))
1408  Else
1409  If Not offloaded Then ret = If there is room, assign a ->gp_seq number to any callbacks on this* CPU that have not already been assigned
1414  If Has a grace period started since the time the old gp_seq was collected? || Value for the false possibility is greater at compile time(READ_ONCE(Possible ->gp_seq wrap. )) Then
1421  trace_rcu_grace_period(Name of structure. , Track rsp->rcu_gp_seq. , Strings used in tracepoints need to be exported via the* tracing system such that tools like perf and trace-cmd can* translate the string address pointers to actual text.("cpustart"))
1422  need_gp = Not Not (CPUs or groups that need to switch in & Mask to apply to leaf qsmask. )
1423  norm = need_gp
1424  Core waits for quiesc state. = need_gp
1425  zero_cpu_stall_ticks(rdp)
1427  Track rsp->rcu_gp_seq counter. = Track rsp->rcu_gp_seq.
1428  If ULONG_CMP_LT(Track furthest future GP request. , Track furthest future GP request. ) || Possible ->gp_seq wrap. Then Track furthest future GP request. = Track furthest future GP request.
1430  WRITE_ONCE(Possible ->gp_seq wrap. , false)
1431  We are reporting a quiescent state on behalf of some other CPU, so* it is our responsibility to check for and handle potential overflow* of the rcu_node ->gp_seq counter with respect to the rcu_data counters
1432  Return ret
Caller
NameDescribe
note_gp_changes
rcu_gp_initInitialize a new grace period. Return false if no grace period required.
rcu_gp_cleanupClean up after the old grace period.