Skip to content

bpf: Allow doing stack read with size larger than the earlier spilled reg

Martin KaFai Lau bpf 1 version Applied

Status from this message: This series was applied to bpf/bpf.git (master)

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 3 repliesApplied 2/2

Patches in v1 All 2 applied

#Subject and filesSizeRepliesApplied
1/2bpf: Do not reject when the stack read size is different from the tracked scalar sizekernel/bpf/verifier.c+6 -122 repliesApplied
2/2bpf: selftest: verifier test on refill from a smaller spilltools/testing/selftests/bpf/verifier/spill_fill.c+17 -01 replyApplied

Reviews trailers per patch

All 2 patches have a Reviewed-by or Acked-by.

PatchHengqi ChenYonghong Song
1/2T-b A-b
2/2A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH bpf-next 0/2] bpf: Allow doing stack read with size larger than the earlier spilled reg

This set fixes an issue that the verifier rejects a u64 stack read after an earlier u32 scalar spill. It is caused by the earlier commit that allows tracking the spilled u32 scalar reg.

Martin KaFai Lau (2):
bpf: Do not reject when the stack read size is different from the
tracked scalar size
bpf: selftest: verifier test on refill from a smaller spill

 kernel/bpf/verifier.c                          | 18 ++++++------------
 .../selftests/bpf/verifier/spill_fill.c        | 17 +++++++++++++++++
 2 files changed, 23 insertions(+), 12 deletions(-)
Signature · 1 line
2.30.2