Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
155 commits
Select commit Hold shift + click to select a range
e72dadd
BPF_PROG_LOAD_DJW
djwillia Aug 23, 2021
b55891d
not-working code
djwillia Nov 29, 2021
272f3f5
update to 5.15
djwillia Dec 3, 2021
21511f3
alloc executable mem for prog
djwillia Dec 13, 2021
b20d1d3
take out printk
djwillia Dec 21, 2021
0d014c5
fix bpf_trace_printk by always enable trace event
jinghao-jia Jan 9, 2022
5d3aa69
ELF Loader in kernel
Sayeed42 Feb 4, 2022
58b46fa
ELF loader woring for example program
jinghao-jia Feb 5, 2022
00f0b96
free program memory
jinghao-jia Feb 7, 2022
310e084
Page permission solved
Sayeed42 Feb 14, 2022
64ec0ef
refactor page permission code
jinghao-jia Feb 14, 2022
fa99bab
might have fixed the page fault (permission error)
jinghao-jia Feb 21, 2022
ccf42e1
fix problem with empty section
jinghao-jia Mar 11, 2022
0db49c4
Fixed memory conflict for distributed apps
Sayeed42 Apr 15, 2022
ebec9a8
Rewritten to resolve conflicts
Sayeed42 Apr 22, 2022
a091d49
map support
jinghao-jia Apr 15, 2022
7e46a02
load the ELF as "inner-unikernel base"
jinghao-jia Apr 27, 2022
78177f6
implement subprog-loading functions to support multiple programs in t…
jinghao-jia Apr 29, 2022
1a1647a
cleanup debug statements
jinghao-jia May 1, 2022
f9cfdfe
Patch GOT at load time
jinghao-jia Aug 30, 2022
a9b5ab7
Add specialized trace_printk for inner-unikernel
jinghao-jia Oct 4, 2022
a0fbfe2
fixup .rela.dyn data
jinghao-jia Nov 10, 2022
d88927f
remove generated files
jinghao-jia Nov 21, 2022
1765b2d
allow larger programs
jinghao-jia May 11, 2023
4cb8627
kernel support for cleanup mechanism
jinghao-jia May 11, 2023
b3d7339
Add support for rust panic handling and stack unwinding
jinghao-jia Aug 16, 2023
77fdb69
Link inner-unikernel invocation with new dispatcher
jinghao-jia Aug 17, 2023
400402d
Save callee-saved registers in new dispatcher
jinghao-jia Aug 28, 2023
33b0e12
x86: iu_unwind_64.S: fix indentation
jinghao-jia Aug 29, 2023
a8f0c5f
allocate vmapped per-cpu iu_stack
jinghao-jia Sep 2, 2023
69e7590
switch stack for iu invocation
jinghao-jia Sep 2, 2023
5c58c19
x86: iu_unwind.c: add more verbose log and doc
jinghao-jia Sep 5, 2023
fe9d7c8
x86: iu_unwind.c: add GREATer kernel message
chinrw Sep 5, 2023
3e94c4c
bpf: filter.h: use iu_unwind as xdp prog dispatcher_func
chinrw Sep 6, 2023
3b45a71
handle potentially read-only map sections
jinghao-jia Sep 12, 2023
fb78c18
bpf: syscall.c: fix compile warning for printk %lx -> %llx
chinrw Sep 12, 2023
7b644a3
bpf_prog_load_iu_base: refactor iu_parse_map and iu_parse_relas out
jinghao-jia Oct 24, 2023
db4f023
bpf_prog_load_iu_base: fixup relocs for dynamic symbols
jinghao-jia Oct 24, 2023
b8c6ee9
uapi/bpf: remove got-related fields in bpf_attr
jinghao-jia Oct 24, 2023
12de651
x86: iu_unwind_64.S: export symbol of iu_dispatcher_func to network
chinrw Oct 30, 2023
cefecb2
x86/iu_unwind: prototype iu_dispatcher_func
jinghao-jia Oct 30, 2023
2e1dd00
x86/iu_unwind: refactor iu panic path
jinghao-jia Nov 7, 2023
a471ea3
bpf,iu: Fix refcnt leak on base program
jinghao-jia Nov 14, 2023
97527e0
bpf,iu: fix NULL-ptr-deref on error path
jinghao-jia Apr 5, 2024
5c00b76
samples/kprobe: add kprobe target module
jinghao-jia Mar 24, 2024
c49a466
samples/kprobes/kprobe_target: prevent call from being optimized away
jinghao-jia Mar 24, 2024
9577ee4
samples/kprobes: allow passing arguments from userspace to kprobes
jinghao-jia Apr 6, 2024
14225a7
include/linux/filter.h: Add timing for dispatcher function in bpf_pro…
MinhPhan8803 Mar 21, 2024
1c76f2f
include/linux/filter.h: update log string
MinhPhan8803 Mar 21, 2024
d510b2d
include/linux/filter.h: use nanoseconds for time
jinghao-jia Mar 24, 2024
1c3b573
samples/bpf: add equivalent eBPF program for startup overhead
jinghao-jia Mar 24, 2024
1d18154
include/linux/filter.h: fix %lu warning msg and add condition prog->n…
chinrw Mar 25, 2024
13806d4
spinlock_cleanup_benchmark: Add BPF spinlock cleanup benchmark
MinhPhan8803 Mar 25, 2024
6dacff7
spinlock_cleanup_benchmark_user.c: update open object file
MinhPhan8803 Mar 26, 2024
23aa195
spinlock_cleanup_benchmark: rename to tracex9
MinhPhan8803 Mar 26, 2024
675ce23
tracex9_user.c: update bpf object file
MinhPhan8803 Mar 26, 2024
03df370
Added tail call program to calculate factorial
orangeng Apr 2, 2024
048fec0
samples/bpf: update recursion benchmark
jinghao-jia Apr 6, 2024
2ffd239
tracex9_user.c: use xdp instead of kprobe
chinrw Apr 7, 2024
d56c5a8
include/linux/filter.h: ignore benchmark timer for BPF dispatcher fun…
chinrw Apr 7, 2024
ec8d729
gitignore: ignore recursive sample binary
chinrw Apr 7, 2024
99eeef9
samples/bpf: fix warnings in recursive
jinghao-jia Apr 7, 2024
0aa3a5e
s/iu/rex/g
jinghao-jia Jun 12, 2024
4314ae1
bpf/syscall: fix incorrect fmt argument type
jinghao-jia Jun 25, 2024
dacc6f8
Fix build errors after rebase
jinghao-jia Aug 8, 2024
9b99f64
libbpf: export section_defs
jinghao-jia Aug 9, 2024
ad9a2ba
samples/bpf: temporarily skip tracex9
jinghao-jia Aug 16, 2024
5f28faf
samples/bpf: fix the use of de[recated libbpf API in tracex9
jinghao-jia Aug 18, 2024
50f6466
bpf,rex: remove bpf_trace_printk_rex
jinghao-jia Aug 20, 2024
ecfbc71
x86/rex_unwind: use unreachable() instead of BUG() to annotate noreturn
jinghao-jia Aug 20, 2024
6a84162
x86/rex_unwind: enlarge rex stack to 32k
jinghao-jia Aug 20, 2024
dfddc29
x86/rex_unwind: fix comments and annotations
jinghao-jia Aug 20, 2024
19cc908
rex/termination: Code for IPI based termination
rjsu26 Mar 29, 2024
1e56c0f
rex-termination: Read per-cpu termination flag before changing execut…
rjsu26 Apr 9, 2024
0c877ed
rex/termination: fix lib/bpf compile fail issue
chinrw Aug 30, 2024
4924523
rex/termination: add termination option in `bpftool`
chinrw Sep 1, 2024
2f069ad
rex/termination: remove the prog detach code in bpf_die()
chinrw Sep 1, 2024
5577cae
bpf: make bpf_termination_flag an unsigned char
jinghao-jia Sep 1, 2024
fe1c648
bpf: remove unused printk in __bpf_prog_run
jinghao-jia Sep 1, 2024
bad4e98
rex: fix cfi check failure
jinghao-jia Sep 2, 2024
906dfa3
rex: move termination code to its own file
jinghao-jia Sep 2, 2024
03d9c5b
rex: set up watchdog timer for termination
jinghao-jia Sep 2, 2024
bc3c408
rex: merge init function invocations
jinghao-jia Sep 2, 2024
6709269
rex: add basic support for watchdog-based termination
jinghao-jia Sep 3, 2024
8385a98
rex: fix null-ptr-deref and triggering condition
jinghao-jia Sep 4, 2024
153bce2
smp,ipi: do not warn on rex termination
jinghao-jia Sep 4, 2024
c17c17e
rex: fix inconsistent attributes in rex_landingpad
jinghao-jia Sep 5, 2024
4f4f381
rex: add per_cpu rex_cur_prog if bpf_stats_enabled_key
chinrw Sep 5, 2024
bdd0da8
rex: force loader process to dump core upon panic
jinghao-jia Sep 10, 2024
86f46ae
rex/kprobe: add function after barrier to disable OPTPROBES
chinrw Sep 13, 2024
26d1efa
rex: setup two hrtimers on different cpu during system boot
chinrw Sep 15, 2024
a6ed014
rex/termination: use per-CPU timer instead of IPI
jinghao-jia Sep 17, 2024
db5c8b2
rex: fix generic_smp_call_function_interrupt in xen function interrupt
chinrw Sep 19, 2024
1690531
rex: fix ERROR: modpost: "rex_curr_prog" [lib/test_bpf.ko] undefined!
chinrw Sep 19, 2024
e1c9bf4
rex/termination: disable print in timer handler
jinghao-jia Sep 19, 2024
1abfa62
samples/bpf: recursive: remove newline to match rex output
jinghao-jia Sep 21, 2024
d2cdc22
samples/tracex9: update xdp to native mode for spinlock_benchmark
chinrw Sep 24, 2024
28d82c7
samples/kprobes: support both int3-based and optimized kprobes in kpr…
jinghao-jia Sep 25, 2024
0b855cf
samples/bpf: add more verbose error message in recursive
jinghao-jia Sep 25, 2024
b38e6e0
samples/bpf: tracex9_user: remove unused variables
jinghao-jia Sep 25, 2024
6767103
samples/bpf: add map_tests for array, hash and static_u64
chinrw Sep 26, 2024
54b2c5e
samples/bpf: modify default key and map max_entries
chinrw Sep 26, 2024
e26f104
rex/landingpad: reset the rex_termination_state set in rex panic handler
chinrw Sep 27, 2024
beceefe
rex: set rex_curr_prog in rex_dispatcher_func
jinghao-jia Sep 27, 2024
b59ed7c
bpf: remove unused bpf prog debug printk
chinrw Sep 30, 2024
4287358
rex: fix the memory leak when "fp->active" failed
chinrw Oct 2, 2024
1c028b3
samples/bpf: remove the unused `ret` variable
chinrw Oct 2, 2024
37a0c8f
rex: free the `saved_state` when __bpf_prog_free() is called
chinrw Oct 2, 2024
af9e0fa
x86/rex: fix OOB access on rex stack area
jinghao-jia Oct 8, 2024
49377be
rex: avoid modifying non-rex contexts
jinghao-jia Oct 8, 2024
4fef654
x86/rex: save frame pointer directly on stack
jinghao-jia Oct 11, 2024
0601c94
samples/bpf: recursive: simplify program to match rex side
jinghao-jia Oct 12, 2024
710a7ad
rex: properly set prog->kprobe_override
jinghao-jia Dec 3, 2024
acecb62
samples/bpf: remove accidentally added build artifacts
jinghao-jia Jan 24, 2025
e842033
x86/rex: code cleanup
jinghao-jia Jan 24, 2025
c77303a
x86/dumpstack: support stack dump from rex programs
jinghao-jia Jan 24, 2025
0af2c52
x86/dumpstack: print rex stack name in stack dump
jinghao-jia Jan 24, 2025
943c0fa
x86/rex: save old stack pointer on top of rex stack
jinghao-jia Jan 25, 2025
fc815c6
rex: correctly allocate rex programs to kallsyms
jinghao-jia Jan 25, 2025
a6ad80e
x86/rex: split rsp modification to a separate function
jinghao-jia Jan 27, 2025
06d9d48
objtool: add rex landingpad functions to the noreturn set
jinghao-jia Jan 27, 2025
3f5d36d
rex: simplify handling of dyn_sym
jinghao-jia Jan 28, 2025
64b31cf
rex: add rust symbols to kallsyms
jinghao-jia Jan 28, 2025
fc6d51b
rex: correctly initialize bpf_ksym entries for rex symbols
jinghao-jia Jan 29, 2025
875cbf4
x86/rex: update outdated panic message
jinghao-jia Feb 6, 2025
960f42d
x86/rex: support retpoline in dispatcher
jinghao-jia Feb 6, 2025
7db2042
x86/rex: move __rex_landingpad to rex_64.S
jinghao-jia Feb 6, 2025
9aaf9a7
x86/rex: improve comments for asm functions
jinghao-jia Feb 7, 2025
41ae38f
x86/rex: replace WARN with ratelimited pr_err
jinghao-jia Feb 7, 2025
43dcf2f
x86/rex: replace inline asm with C function call to rex_landingpad_asm()
jinghao-jia Feb 7, 2025
e480f64
objtool: add rex_landingpad_asm() to noreturns list
jinghao-jia Feb 7, 2025
216aed8
perf: remove unused a.out obj
chinrw Feb 7, 2025
f8fd4f2
rex: cleanup rex_load_prog{,_base}
jinghao-jia Feb 18, 2025
c736140
rex: directly compute final value of relocations
jinghao-jia Feb 19, 2025
6543b82
kbuild: add simple meson support
jinghao-jia Feb 26, 2025
5244768
kbuild/meson: s/build_dir/kbuild_dir/g
jinghao-jia Feb 26, 2025
cc90426
kbuild/meson: fix build file format
jinghao-jia Feb 27, 2025
e5ced5a
kbuild/meson: use nproc instead of '32'
chinrw Mar 6, 2025
edc1297
kbuild/meson: explicitly capture and check nproc
jinghao-jia Mar 6, 2025
ffb8efe
kbuild/meson: enable build_always_stable to ensure vmlinux is up-to-date
chinrw Mar 25, 2025
1802500
rex: remove unnecessary zeroing of rex program segments
jinghao-jia Mar 30, 2025
765d3cd
rex: introduce rex_log_buf per-cpu buffer for formatting and printing
jinghao-jia Apr 5, 2025
72b7a53
x86/rex: print rex panic message from per-cpu log buffer
jinghao-jia Apr 5, 2025
63fb4f1
rex: do not count total memory size and page counts incermentally
jinghao-jia Apr 6, 2025
cd6db28
samples/kprobes: add missing MODULE_DESCRIPTION() to kprobe_target
jinghao-jia Jun 15, 2025
e7f41e6
kbuild/meson: do not clean meson.build during
jinghao-jia Jul 27, 2025
a9d3c21
Sanity testig done
Apr 9, 2026
8382a19
Sanity testing done
Apr 9, 2026
51970aa
Add support for sched_ext_ops_cfs
jampflah Apr 9, 2026
e9ba1a8
print statements on KCFI errors - reaching scx_enable
Apr 9, 2026
64fbf3c
Merging origin/sched_ext_ops_cfg.
jampflah Apr 14, 2026
08e7e17
Fix merge duplication error.
jampflah Apr 14, 2026
4c9ae66
Plumbing Rex scheduler name through Rex sched_ext path
Apr 21, 2026
8d2cf1f
Fix leak on SCX_EXIT_ERROR_STALL (mode 1 scx simple soft stall).
jampflah Apr 26, 2026
90e2e16
Merge branch 'rex-linux' into nmi_branch_test
dg1197 May 2, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions include/linux/bpf.h
Original file line number Diff line number Diff line change
Expand Up @@ -1793,6 +1793,18 @@ struct rex_saved_states{
struct bpf_link *link;
};

struct rex_mem {
void *mem;
u32 total_page;
};

struct rex_saved_states{
int cpu_id;
int loader_pid;
u64 unwinder_insn_off;
struct bpf_link *link;
};

struct bpf_prog {
u16 pages; /* Number of allocated pages */
u16 jited:1, /* Is our filter JIT'ed? */
Expand Down
20 changes: 19 additions & 1 deletion include/uapi/linux/bpf.h
Original file line number Diff line number Diff line change
Expand Up @@ -992,9 +992,11 @@ enum bpf_cmd {
BPF_PROG_BIND_MAP,
BPF_TOKEN_CREATE,
BPF_PROG_STREAM_READ_BY_FD,
BPF_PROG_ASSOC_STRUCT_OPS,
BPF_PROG_LOAD_REX_BASE,
BPF_PROG_LOAD_REX,
BPF_SCHED_EXT_ATTACH_REX,
BPF_SCHED_EXT_DETACH_REX,
BPF_PROG_ASSOC_STRUCT_OPS,
BPF_PROG_TERMINATE,
__MAX_BPF_CMD,
};
Expand Down Expand Up @@ -1528,6 +1530,11 @@ struct rex_text_sym {
const char __user *symbol;
};

struct rex_sched_ops_sym {
const char __user *name;
__u64 offset;
};

union bpf_attr {
struct { /* anonymous struct used by BPF_MAP_CREATE command */
__u32 map_type; /* one of enum bpf_map_type */
Expand Down Expand Up @@ -1955,6 +1962,17 @@ union bpf_attr {
__u32 prog_fd;
} prog_stream_read;

struct { /* BPF_SCHED_EXT_ATTACH_REX */
__u32 base_prog_fd;
__aligned_u64 sched_ops_syms; /* ptr to rex_sched_ops_sym array */
__u32 nr_sched_ops_syms;
__u32 timeout_ms; /* ops.timeout_ms, 0 = default */
__u32 exit_dump_len; /* ops.exit_dump_len, 0 = default */
__u32 pad;
__aligned_u64 ops_flags; /* SCX_OPS_* flags */
char name[128]; /* ops.name; empty string = use base->aux->name */
} sched_ext_attach;

struct {
__u32 map_fd;
__u32 prog_fd;
Expand Down
Loading