函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\bpf\devmap.c Create Date:2022-07-27 14:40:24
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:dev_map_notification

函数原型:static int dev_map_notification(struct notifier_block *notifier, ulong event, void *ptr)

返回类型:int

参数:

类型参数名称
struct notifier_block *notifier
ulongevent
void *ptr
770  netdev等于netdev_notifier_info_to_dev(ptr)
775  :event恒等于NETDEV_UNREGISTER
781  _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
783  如果map_type恒等于BPF_MAP_TYPE_DEVMAP_HASH
785  继续下一循环
788 i小于max_entries循环
792  如果非devnetdev不等于 must be first member, due to tracepoint 则继续下一循环
794  odev等于cmpxchg( & DEVMAP type only [i], dev, NULL)
800  _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()
801  退出
802  默认
803  退出
805  返回:Suits me