diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/filter.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/filter.h b/include/linux/filter.h index fccd8db33647..e0218e677a1d 100644 --- a/include/linux/filter.h +++ b/include/linux/filter.h @@ -267,9 +267,13 @@ static inline bool bpf_is_unwind_exit(const struct bpf_insn *insn) /* * The caller of the main prog doesn't tell unwind_exit from exit. An extension * is different: its caller is the caller of the subprog that it replaced. + * An exception callback returns from the frame of the main prog. After freplace + * or a tail call it returns to a prog that wasn't verified with the callback. */ static inline bool bpf_prog_can_unwind(const struct bpf_prog *prog) { + if (prog->aux->exception_cb) + return false; return bpf_is_subprog(prog) || prog->type == BPF_PROG_TYPE_EXT; } |
