Skip to contentSkip to conversation

Patch "bpf: change back to orig prog on too many passes" has been added to the 4.9-stable tree

PATCH [email protected] 1 participant 1 message Jan 12, 2017

Subsystems (4)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

bpf: change back to orig prog on too many passes

to the 4.9-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
bpf-change-back-to-orig-prog-on-too-many-passes.patch
and it can be found in the queue-4.9 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From foo@baz Thu Jan 12 21:37:26 CET 2017

From: Daniel Borkmann <[email protected]>
Date: Sat, 7 Jan 2017 00:26:33 +0100
Subject: bpf: change back to orig prog on too many passes

From: Daniel Borkmann <[email protected]>

[ Upstream commit 9d5ecb09d525469abd1a10c096cb5a17206523f2 ]

If after too many passes still no image could be emitted, then swap back to the original program as we do in all other cases and don't use the one with blinding.

Fixes 959a75791603 ("bpf, x86: add support for constant blinding")
---
 arch/x86/net/bpf_jit_comp.c |    2 ++
 1 file changed, 2 insertions(+)
arch/x86/net/bpf_jit_comp.c +2 -0
@@ -1172,6 +1172,8 @@ struct bpf_prog *bpf_int_jit_compile(str
 		set_memory_ro((unsigned long)header, header->pages);
 		prog->bpf_func = (void *)image;
 		prog->jited = 1;
+	} else {
+		prog = orig_prog;
 	}
 
 out_addrs:

Patches currently in stable-queue which might be from [email protected] are

queue-4.9/bpf-change-back-to-orig-prog-on-too-many-passes.patch queue-4.9/net-sched-fix-soft-lockup-in-tc_classify.patch