Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\bpf\arraymap.c Create Date:2022-07-28 13:11:40
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:prog_array_map_poke_track

Proto:static int prog_array_map_poke_track(struct bpf_map *map, struct bpf_prog_aux *prog_aux)

Type:int

Parameter:

TypeParameterName
struct bpf_map *map
struct bpf_prog_aux *prog_aux
699  ret = 0
701  aux = ({
701  __mptr = map
701  Do
701  When 0 cycle
701  __mptr - __builtin_offsetof(structbpf_array, map)
701  })->aux
702  mutex_lock( & poke_mutex)
704  If aux == prog_aux Then Go to out
708  elem = Allocation memory
709  If Not elem Then
710  ret = -ENOMEM
711  Go to out
714  Initialization list head
719  aux = prog_aux
721  list_add_tail - add a new entry*@new: new entry to be added*@head: list head to add it before* Insert a new entry before the specified head.* This is useful for implementing queues.
722  out :
723  mutex_unlock - release the mutex*@lock: the mutex to be released* Unlock a mutex that has been locked by this task previously.* This function must not be used in interrupt context. Unlocking* of a not locked mutex is not allowed.
724  Return ret