Commit 20ddfe1
program: don't return error when kmod BTF is disabled
In kernels where the flag CONFIG_DEBUG_INFO_BTF_MODULES is not set,
including kernels 5.10 and below (because the flag was introduced in 5.11),
loading a program that attaches to kernel module functions and relied on
CORE failed because the module's BTF is not available.
This fix allows the program to run, obviously only as long as it only
relies on the kernel's BTF and not on the specific module's BTF.
Fixes: #1436
Signed-off-by: Ori Shussman <orishuss@gmail.com>1 parent 7719d2f commit 20ddfe1
2 files changed
Lines changed: 7 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
| 66 | + | |
66 | 67 | | |
67 | 68 | | |
68 | 69 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| 9 | + | |
9 | 10 | | |
10 | 11 | | |
11 | 12 | | |
| |||
148 | 149 | | |
149 | 150 | | |
150 | 151 | | |
151 | | - | |
| 152 | + | |
| 153 | + | |
152 | 154 | | |
153 | 155 | | |
154 | | - | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
155 | 159 | | |
156 | 160 | | |
157 | 161 | | |
| |||
0 commit comments