Skip to content

Commit ed5097b

Browse files
DanielTimLeekernel-patches-bot
authored andcommitted
samples: bpf: remove bpf_load loader completely
Numerous refactoring that rewrites BPF programs written with bpf_load to use the libbpf loader was finally completed, resulting in BPF programs using bpf_load within the kernel being completely no longer present. This commit removes bpf_load, an outdated bpf loader that is difficult to keep up with the latest kernel BPF and causes confusion. Also, this commit removes the unused trace_helper and bpf_load from samples/bpf target objects from Makefile. Signed-off-by: Daniel T. Lee <[email protected]> Acked-by: Jesper Dangaard Brouer <[email protected]> Acked-by: Andrii Nakryiko <[email protected]>
1 parent 265c17d commit ed5097b

File tree

4 files changed

+5
-731
lines changed

4 files changed

+5
-731
lines changed

samples/bpf/Makefile

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ tracex5-objs := tracex5_user.o $(TRACE_HELPERS)
7373
tracex6-objs := tracex6_user.o
7474
tracex7-objs := tracex7_user.o
7575
test_probe_write_user-objs := test_probe_write_user_user.o
76-
trace_output-objs := trace_output_user.o $(TRACE_HELPERS)
76+
trace_output-objs := trace_output_user.o
7777
lathist-objs := lathist_user.o
7878
offwaketime-objs := offwaketime_user.o $(TRACE_HELPERS)
7979
spintest-objs := spintest_user.o $(TRACE_HELPERS)
@@ -91,8 +91,8 @@ test_current_task_under_cgroup-objs := $(CGROUP_HELPERS) \
9191
test_current_task_under_cgroup_user.o
9292
trace_event-objs := trace_event_user.o $(TRACE_HELPERS)
9393
sampleip-objs := sampleip_user.o $(TRACE_HELPERS)
94-
tc_l2_redirect-objs := bpf_load.o tc_l2_redirect_user.o
95-
lwt_len_hist-objs := bpf_load.o lwt_len_hist_user.o
94+
tc_l2_redirect-objs := tc_l2_redirect_user.o
95+
lwt_len_hist-objs := lwt_len_hist_user.o
9696
xdp_tx_iptunnel-objs := xdp_tx_iptunnel_user.o
9797
test_map_in_map-objs := test_map_in_map_user.o
9898
per_socket_stats_example-objs := cookie_uid_helper_example.o
@@ -108,7 +108,7 @@ xdpsock-objs := xdpsock_user.o
108108
xsk_fwd-objs := xsk_fwd.o
109109
xdp_fwd-objs := xdp_fwd_user.o
110110
task_fd_query-objs := task_fd_query_user.o $(TRACE_HELPERS)
111-
xdp_sample_pkts-objs := xdp_sample_pkts_user.o $(TRACE_HELPERS)
111+
xdp_sample_pkts-objs := xdp_sample_pkts_user.o
112112
ibumad-objs := ibumad_user.o
113113
hbm-objs := hbm.o $(CGROUP_HELPERS)
114114

@@ -197,8 +197,6 @@ TPROGS_CFLAGS += --sysroot=$(SYSROOT)
197197
TPROGS_LDFLAGS := -L$(SYSROOT)/usr/lib
198198
endif
199199

200-
TPROGCFLAGS_bpf_load.o += -Wno-unused-variable
201-
202200
TPROGS_LDLIBS += $(LIBBPF) -lelf -lz
203201
TPROGLDLIBS_tracex4 += -lrt
204202
TPROGLDLIBS_trace_output += -lrt

0 commit comments

Comments
 (0)