@@ -139,40 +139,40 @@ typedef struct _ebpf_map_definition_in_file
139139
140140typedef enum
141141{
142- BPF_FUNC_map_lookup_elem = 1 , ///< \ref bpf_map_lookup_elem
143- BPF_FUNC_map_update_elem = 2 , ///< \ref bpf_map_update_elem
144- BPF_FUNC_map_delete_elem = 3 , ///< \ref bpf_map_delete_elem
145- BPF_FUNC_map_lookup_and_delete_elem = 4 , ///< \ref bpf_map_lookup_and_delete_elem
146- BPF_FUNC_tail_call = 5 , ///< \ref bpf_tail_call
147- BPF_FUNC_get_prandom_u32 = 6 , ///< \ref bpf_get_prandom_u32
148- BPF_FUNC_ktime_get_boot_ns = 7 , ///< \ref bpf_ktime_get_boot_ns
149- BPF_FUNC_get_smp_processor_id = 8 , ///< \ref bpf_get_smp_processor_id
150- BPF_FUNC_ktime_get_ns = 9 , ///< \ref bpf_ktime_get_ns
151- BPF_FUNC_csum_diff = 10 , ///< \ref bpf_csum_diff
152- BPF_FUNC_ringbuf_output = 11 , ///< \ref bpf_ringbuf_output
153- BPF_FUNC_trace_printk2 = 12 , ///< \ref bpf_trace_printk2 (but use \ref bpf_printk instead)
154- BPF_FUNC_trace_printk3 = 13 , ///< \ref bpf_trace_printk3 (but use \ref bpf_printk instead)
155- BPF_FUNC_trace_printk4 = 14 , ///< \ref bpf_trace_printk4 (but use \ref bpf_printk instead)
156- BPF_FUNC_trace_printk5 = 15 , ///< \ref bpf_trace_printk5 (but use \ref bpf_printk instead)
157- BPF_FUNC_map_push_elem = 16 , ///< \ref bpf_map_push_elem
158- BPF_FUNC_map_pop_elem = 17 , ///< \ref bpf_map_pop_elem
159- BPF_FUNC_map_peek_elem = 18 , ///< \ref bpf_map_peek_elem
160- BPF_FUNC_get_current_pid_tgid = 19 , ///< \ref bpf_get_current_pid_tgid
161- BPF_FUNC_get_current_logon_id = 20 , ///< \ref bpf_get_current_logon_id
162- BPF_FUNC_is_current_admin = 21 , ///< \ref bpf_is_current_admin
163- BPF_FUNC_memcpy_s = 22 , ///< \ref bpf_memcpy_s
164- BPF_FUNC_memcmp_s = 23 , ///< \ref bpf_memcmp_s
165- BPF_FUNC_memset = 24 , ///< \ref bpf_memset
166- BPF_FUNC_memmove_s = 25 , ///< \ref bpf_memmove_s
167- BPF_FUNC_get_socket_cookie = 26 , ///< \ref bpf_get_socket_cookie
168- BPF_FUNC_strncpy_s = 27 , ///< \ref bpf_strncpy_s
169- BPF_FUNC_strncat_s = 28 , ///< \ref bpf_strncat_s
170- BPF_FUNC_strnlen_s = 29 , ///< \ref bpf_strnlen_s
171- BPF_FUNC_ktime_get_boot_ms = 30 , ///< \ref bpf_ktime_get_boot_ms
172- BPF_FUNC_ktime_get_ms = 31 , ///< \ref bpf_ktime_get_ms
173- BPF_FUNC_perf_event_output = 32 , ///< \ref bpf_perf_event_output
174- BPF_FUNC_get_current_process_start_key = 33 , ///< \ref bpf_get_current_process_start_key
175- BPF_FUNC_get_current_thread_create_time = 34 , ///< \ref bpf_get_current_thread_create_time
142+ BPF_FUNC_map_lookup_elem = 1 , ///< \ref bpf_map_lookup_elem
143+ BPF_FUNC_map_update_elem = 2 , ///< \ref bpf_map_update_elem
144+ BPF_FUNC_map_delete_elem = 3 , ///< \ref bpf_map_delete_elem
145+ BPF_FUNC_map_lookup_and_delete_elem = 4 , ///< \ref bpf_map_lookup_and_delete_elem
146+ BPF_FUNC_tail_call = 5 , ///< \ref bpf_tail_call
147+ BPF_FUNC_get_prandom_u32 = 6 , ///< \ref bpf_get_prandom_u32
148+ BPF_FUNC_ktime_get_boot_ns = 7 , ///< \ref bpf_ktime_get_boot_ns
149+ BPF_FUNC_get_smp_processor_id = 8 , ///< \ref bpf_get_smp_processor_id
150+ BPF_FUNC_ktime_get_ns = 9 , ///< \ref bpf_ktime_get_ns
151+ BPF_FUNC_csum_diff = 10 , ///< \ref bpf_csum_diff
152+ BPF_FUNC_ringbuf_output = 11 , ///< \ref bpf_ringbuf_output
153+ BPF_FUNC_trace_printk2 = 12 , ///< \ref bpf_trace_printk2 (but use \ref bpf_printk instead)
154+ BPF_FUNC_trace_printk3 = 13 , ///< \ref bpf_trace_printk3 (but use \ref bpf_printk instead)
155+ BPF_FUNC_trace_printk4 = 14 , ///< \ref bpf_trace_printk4 (but use \ref bpf_printk instead)
156+ BPF_FUNC_trace_printk5 = 15 , ///< \ref bpf_trace_printk5 (but use \ref bpf_printk instead)
157+ BPF_FUNC_map_push_elem = 16 , ///< \ref bpf_map_push_elem
158+ BPF_FUNC_map_pop_elem = 17 , ///< \ref bpf_map_pop_elem
159+ BPF_FUNC_map_peek_elem = 18 , ///< \ref bpf_map_peek_elem
160+ BPF_FUNC_get_current_pid_tgid = 19 , ///< \ref bpf_get_current_pid_tgid
161+ BPF_FUNC_get_current_logon_id = 20 , ///< \ref bpf_get_current_logon_id
162+ BPF_FUNC_is_current_admin = 21 , ///< \ref bpf_is_current_admin
163+ BPF_FUNC_memcpy_s = 22 , ///< \ref bpf_memcpy_s
164+ BPF_FUNC_memcmp_s = 23 , ///< \ref bpf_memcmp_s
165+ BPF_FUNC_memset = 24 , ///< \ref bpf_memset
166+ BPF_FUNC_memmove_s = 25 , ///< \ref bpf_memmove_s
167+ BPF_FUNC_get_socket_cookie = 26 , ///< \ref bpf_get_socket_cookie
168+ BPF_FUNC_strncpy_s = 27 , ///< \ref bpf_strncpy_s
169+ BPF_FUNC_strncat_s = 28 , ///< \ref bpf_strncat_s
170+ BPF_FUNC_strnlen_s = 29 , ///< \ref bpf_strnlen_s
171+ BPF_FUNC_ktime_get_boot_ms = 30 , ///< \ref bpf_ktime_get_boot_ms
172+ BPF_FUNC_ktime_get_ms = 31 , ///< \ref bpf_ktime_get_ms
173+ BPF_FUNC_perf_event_output = 32 , ///< \ref bpf_perf_event_output
174+ BPF_FUNC_get_current_process_start_key = 33 , ///< \ref bpf_get_current_process_start_key
175+ BPF_FUNC_get_current_thread_create_time = 34 , ///< \ref bpf_get_current_thread_create_time
176176} ebpf_helper_id_t ;
177177
178178// Cross-platform BPF program types.
@@ -249,16 +249,6 @@ enum bpf_prog_type
249249 */
250250 BPF_PROG_TYPE_PROCESS ,
251251
252- /** @brief Program type for handling incoming packets as early as possible.
253- *
254- * **eBPF program prototype:** \ref xdp_hook_t
255- *
256- * **Attach type(s):** \ref BPF_XDP_TEST
257- *
258- * **Helpers available:** all helpers defined in bpf_helpers.h
259- */
260- BPF_PROG_TYPE_XDP_TEST = 998 ,
261-
262252 /** @brief Program type for handling calls from the eBPF sample extension. Used for
263253 * testing.
264254 *
@@ -343,23 +333,17 @@ enum bpf_attach_type
343333 */
344334 BPF_ATTACH_TYPE_SAMPLE ,
345335
346- /** @brief Attach type for handling incoming packets as early as possible.
347- *
348- * **Program type:** \ref BPF_PROG_TYPE_XDP_TEST
349- */
350- BPF_XDP_TEST ,
351-
352336 /** @brief Attach type for handling netevents.
353337 *
354338 * **Program type:** \ref BPF_PROG_TYPE_NETEVENT
355339 */
356- BPF_ATTACH_TYPE_NETEVENT ,
340+ BPF_ATTACH_TYPE_NETEVENT = 10 ,
357341
358342 /** @brief Attach type for handling process creation/deletion events.
359343 *
360344 * **Program type:** \ref BPF_PROG_TYPE_PROCESS
361345 */
362- BPF_ATTACH_TYPE_PROCESS ,
346+ BPF_ATTACH_TYPE_PROCESS = 11 ,
363347
364348 __MAX_BPF_ATTACH_TYPE ,
365349};
0 commit comments