Commit cddf2bd
bpf: Allow instructions with arena source and non-arena dest registers
[ Upstream commit ac61bff ]
The compiler sometimes stores the result of a PTR_TO_ARENA and SCALAR
operation into the scalar register rather than the pointer register.
Relax the verifier to allow operations between a source arena register
and a destination non-arena register, marking the destination's value
as a PTR_TO_ARENA.
Signed-off-by: Emil Tsalapatis <emil@etsalapatis.com>
Acked-by: Song Liu <song@kernel.org>
Fixes: 6082b6c ("bpf: Recognize addr_space_cast instruction in the verifier.")
Link: https://lore.kernel.org/r/20260412174546.18684-2-emil@etsalapatis.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>1 parent 9d51c86 commit cddf2bd
1 file changed
Lines changed: 11 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15705 | 15705 | | |
15706 | 15706 | | |
15707 | 15707 | | |
15708 | | - | |
| 15708 | + | |
| 15709 | + | |
| 15710 | + | |
| 15711 | + | |
15709 | 15712 | | |
15710 | | - | |
| 15713 | + | |
| 15714 | + | |
15711 | 15715 | | |
15712 | 15716 | | |
| 15717 | + | |
| 15718 | + | |
| 15719 | + | |
| 15720 | + | |
| 15721 | + | |
15713 | 15722 | | |
15714 | 15723 | | |
15715 | 15724 | | |
| |||
15725 | 15734 | | |
15726 | 15735 | | |
15727 | 15736 | | |
15728 | | - | |
15729 | 15737 | | |
15730 | 15738 | | |
15731 | 15739 | | |
| |||
0 commit comments