infer packet range for 'if pkt ==/!= pkt_end' instructions
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest3 patches 12 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/3 | bpf: simplify try_match_pkt_pointers()kernel/ | +24 | 4 replies | |
| 2/3 | bpf: infer packet range for 'if pkt ==/!= pkt_end' comparisonskernel/ | +8 | 8 replies | |
| 3/3 | selftests/bpf: test packet range inference for 'if pkt ==/!= pkt_end'tools/ | +138 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH bpf-next 0/3] infer packet range for 'if pkt ==/!= pkt_end' instructions
As suggested by Maciej Żenczykowski in [1], extend try_match_pkt_pointers to allow verification of BPF, generated for C code like below:
if (data + 42 != data_end) { ... }
Also simplify try_match_pkt_pointers to avoid checking both 'pkt <op> pkt_end' and 'pkt_end <op> pkt' conditions, as suggested by Andrii Nakryiko.
[1] https://lore.kernel.org/bpf/CAHo-Oow5V2u4ZYvzuR8NmJmFDPNYp0pQDJX66rZqUjFHvhx82A@mail.gmail.com/
Eduard Zingerman (3):
bpf: simplify try_match_pkt_pointers()
bpf: infer packet range for 'if pkt ==/!= pkt_end' comparisons selftests/bpf: test packet range inference for 'if pkt ==/!= pkt_end'
kernel/bpf/verifier.c | 112 ++++---------- .../bpf/progs/verifier_direct_packet_access.c | 138 ++++++++++++++++++ 2 files changed, 170 insertions(+), 80 deletions(-)
Signature · 1 line
2.43.0