Bug 4943 - BUG: 'direct->addr' not restored in modify_ftrace_direct()
Summary: BUG: 'direct->addr' not restored in modify_ftrace_direct()
Status: NEW
Alias: None
Product: ANCK 5.10 Dev
Classification: ANCK
Component: bpf (show other bugs) bpf
Version: 5.10.y-15
Hardware: All Linux
: P3-Medium S3-normal
Target Milestone: ---
Assignee: maqiao
QA Contact: shuming
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-05-13 10:15 UTC by ljubomir
Modified: 2023-05-13 10:22 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description ljubomir inspur_group 2023-05-13 10:15:46 UTC
Description of problem:

Syzkaller report a WARNING: "WARN_ON(!direct)" in modify_ftrace_direct().

Root cause is 'direct->addr' was changed from 'old_addr' to 'new_addr' but
not restored if error happened on calling ftrace_modify_direct_caller().
Then it can no longer find 'direct' by that 'old_addr'.
Comment 1 小龙 admin 2023-05-13 10:22:26 UTC
The PR Link: https://gitee.com/anolis/cloud-kernel/pulls/1624