Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\include\asm\tlbflush.h Create Date:2022-07-28 05:55:16
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Blindly accessing user memory from NMI context can be dangerous* if we're in the middle of switching the current user task or* switching the loaded mm. It can also be dangerous if we* interrupted some kernel code that was temporarily using a* different mm.

Proto:static inline bool nmi_uaccess_okay(void)

Type:bool

Parameter:Nothing

254  loaded_mm = Operations with implied preemption/interrupt protection. These* operations can be used without worrying about preemption or interrupt.(loaded_mm)
255  current_mm = mm
257  VM_WARN_ON_ONCE(!loaded_mm)
269  If loaded_mm != current_mm Then Return false
272  VM_WARN_ON_ONCE(pgd != __va(Friendlier CR3 helpers.))
274  Return true
Caller
NameDescribe
copy_from_user_nmiWe rely on the nested NMI work to allow atomic faults from the NMI path; the* nested NMI paths are careful to preserve CR2.
____bpf_probe_write_user
____bpf_send_signal