Skip to contentSkip to conversation

bpf: remove obsolete prog->aux sanitation in bpf_insn_prepare_dump

PATCH Applied Daniel Borkmann 2 participants 2 messages Dec 12, 2018 – Dec 13, 2018

Subsystems (4)
lore
Share & tools
lore

Daniel Borkmann

author maintainer
#0 lore raw

PATCH 1/1 bpf: remove obsolete prog->aux sanitation in bpf_insn_prepare_dump

This logic is not needed anymore since we got rid of the verifier rewrite that was using prog->aux address in f6069b9aa993 ("bpf:
fix redirect to map under tail calls").

---
 kernel/bpf/syscall.c | 7 -------
 1 file changed, 7 deletions(-)
kernel/bpf/syscall.c +0 -7
index 5745c78..330010d 100644
@@ -2031,13 +2031,6 @@ static struct bpf_insn *bpf_insn_prepare_dump(const struct bpf_prog *prog)
 			insns[i + 1].imm = 0;
 			continue;
 		}
-
-		if (!bpf_dump_raw_ok() &&
-		    imm == (unsigned long)prog->aux) {
-			insns[i].imm = 0;
-			insns[i + 1].imm = 0;
-			continue;
-		}
 	}
 
 	return insns;
Signature · 1 line
2.9.5
#1 lore raw
Quoted 5 lines · Daniel Borkmann

This logic is not needed anymore since we got rid of the verifier rewrite that was using prog->aux address in f6069b9aa993 ("bpf:
fix redirect to map under tail calls").

Applied, Thanks