Function report | 
Source Code:kernel\bpf\syscall.c | 
Create Date:2022-07-28 12:52:54 | 
| Last Modify:2022-05-19 18:06:12 | Copyright©Brick | 
| home page | Tree | 
| Annotation kernel can get tool activity | Download SCCT | Chinese | 
Name:map_freeze
Proto:static int map_freeze(const union bpf_attr *attr)
Type:int
Parameter:
| Type | Parameter | Name | 
|---|---|---|
| const union bpf_attr * | attr | 
| 1247 | err = 0 , ufd = anonymous struct used by BPF_MAP_*_ELEM commands | 
| 1251 | If helper macro to check that unused fields 'union bpf_attr' are zero (BPF_MAP_FREEZE) Then Return -EINVAL | 
| 1255 | map = error is returned, fd is released.* On success caller should complete fd access with matching fdput() | 
| 1259 | mutex_lock( & freeze_mutex) | 
| 1261 | If writable mmap cnt; protected by freeze_mutex Then | 
| 1265 | If READ_ONCE( write-once; write-protected by freeze_mutex ) Then | 
| 1269 | If Not Check operation authority Then | 
| 1274 | WRITE_ONCE( write-once; write-protected by freeze_mutex , true) | 
| 1275 | err_put : | 
| 1278 | Return err | 
| Source code conversion tool public plug-in interface  | X | 
|---|---|
| Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion  |