From: <gregkh@linuxfoundation.org>
To: aurelien@aurel32.net, gregkh@linuxfoundation.org,
markos.chandras@imgtec.com, ralf@linux-mips.org
Cc: <stable@vger.kernel.org>, <stable-commits@vger.kernel.org>
Subject: Patch "MIPS: BPF: Avoid unreachable code on little endian" has been added to the 4.2-stable tree
Date: Sat, 17 Oct 2015 16:36:45 -0700 [thread overview]
Message-ID: <144512500520066@kroah.com> (raw)
This is a note to let you know that I've just added the patch titled
MIPS: BPF: Avoid unreachable code on little endian
to the 4.2-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:
mips-bpf-avoid-unreachable-code-on-little-endian.patch
and it can be found in the queue-4.2 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.
>From faa9724a674e5e52316bb0d173aed16bd17d536c Mon Sep 17 00:00:00 2001
From: Aurelien Jarno <aurelien@aurel32.net>
Date: Sat, 5 Sep 2015 18:46:56 +0200
Subject: MIPS: BPF: Avoid unreachable code on little endian
From: Aurelien Jarno <aurelien@aurel32.net>
commit faa9724a674e5e52316bb0d173aed16bd17d536c upstream.
On little endian, avoid generating the big endian version of the code
by using #else in addition to #ifdef #endif. Also fix one alignment
issue wrt delay slot.
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Reviewed-by: Markos Chandras <markos.chandras@imgtec.com>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/11097/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
arch/mips/net/bpf_jit_asm.S | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
--- a/arch/mips/net/bpf_jit_asm.S
+++ b/arch/mips/net/bpf_jit_asm.S
@@ -151,9 +151,10 @@ NESTED(bpf_slow_path_word, (6 * SZREG),
wsbh t0, $r_s0
jr $r_ra
rotr $r_A, t0, 16
-#endif
+#else
jr $r_ra
- move $r_A, $r_s0
+ move $r_A, $r_s0
+#endif
END(bpf_slow_path_word)
@@ -162,9 +163,10 @@ NESTED(bpf_slow_path_half, (6 * SZREG),
#ifdef CONFIG_CPU_LITTLE_ENDIAN
jr $r_ra
wsbh $r_A, $r_s0
-#endif
+#else
jr $r_ra
move $r_A, $r_s0
+#endif
END(bpf_slow_path_half)
Patches currently in stable-queue which might be from aurelien@aurel32.net are
queue-4.2/mips-bpf-fix-build-on-pre-r2-little-endian-cpus.patch
queue-4.2/mips-bpf-avoid-unreachable-code-on-little-endian.patch
reply other threads:[~2015-10-17 23:36 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=144512500520066@kroah.com \
--to=gregkh@linuxfoundation.org \
--cc=aurelien@aurel32.net \
--cc=markos.chandras@imgtec.com \
--cc=ralf@linux-mips.org \
--cc=stable-commits@vger.kernel.org \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.