This adds the ability to read gso_segs from a BPF program. v3: Use BPF_REG_AX instead of BPF_REG_TMP for the temporary register, as suggested by Martin. v2: refined Eddie Hao patch to address Alexei feedback.
Showing the changes to include/uapi/linux (1 of 4 files). Show all
Unified · Split
| @@ -2540,6 +2540,7 @@ struct __sk_buff { · 2539 unmodified lines | |||
| 2540 | __bpf_md_ptr(struct bpf_flow_keys *, flow_keys); | 2540 | __bpf_md_ptr(struct bpf_flow_keys *, flow_keys); |
| 2541 | __u64 tstamp; | 2541 | __u64 tstamp; |
| 2542 | __u32 wire_len; | 2542 | __u32 wire_len; |
| 2543 | __u32 gso_segs; | ||
| 2543 | }; | 2544 | }; |
| 2544 | 2545 | ||
| 2545 | struct bpf_tunnel_key { | 2546 | struct bpf_tunnel_key { |