Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:security\selinux\avc.c Create Date:2022-07-28 18:43:24
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:avc_reclaim_node

Proto:static inline int avc_reclaim_node(struct selinux_avc *avc)

Type:int

Parameter:

TypeParameterName
struct selinux_avc *avc
469  When try < AVC_CACHE_SLOTS cycle
470  hvalue = atomic_inc_return( & LRU hint for reclaim scan ) & AVC_CACHE_SLOTS - 1
472  head = head for avc_node->list [hvalue]
473  lock = lock for writes [hvalue]
475  If Not spin_trylock_irqsave(lock, flags) Then Continue
478  _read_lock() - mark the beginning of an RCU read-side critical section* When synchronize_rcu() is invoked on one CPU while other CPUs* are within RCU read-side critical sections, then the* synchronize_rcu() is guaranteed to block until after all the other
480  avc_node_delete(avc, node)
481  avc_cache_stats_incr(reclaims)
482  ecx++
483  If ecx >= AVC_CACHE_RECLAIM Then
486  Go to out
489  _read_unlock() - marks the end of an RCU read-side critical section.* In most situations, rcu_read_unlock() is immune from deadlock.* However, in kernels built with CONFIG_RCU_BOOST, rcu_read_unlock()
490  spin_unlock_irqrestore(lock, flags)
492  out :
493  Return ecx
Caller
NameDescribe
avc_alloc_node