]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ARM: probes: fix instruction fetch order with <asm/opcodes.h>
authorBen Dooks <ben.dooks@codethink.co.uk>
Fri, 8 Nov 2013 18:29:25 +0000 (18:29 +0000)
committerJiri Slaby <jslaby@suse.cz>
Wed, 19 Nov 2014 17:38:26 +0000 (18:38 +0100)
commit612d07862d30f4a08cc1157b82bf94312c63f3ef
tree1e46d18abdb65178626bd395c50bf8caa6916896
parentafdb2106cf94f193907304fd51dcaa5894926280
ARM: probes: fix instruction fetch order with <asm/opcodes.h>

commit 888be25402021a425da3e85e2d5a954d7509286e upstream.

If we are running BE8, the data and instruction endianness do not
match, so use <asm/opcodes.h> to correctly translate memory accesses
into ARM instructions.

Acked-by: Jon Medhurst <tixy@linaro.org>
Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
[taras.kondratiuk@linaro.org: fixed Thumb instruction fetch order]
Signed-off-by: Taras Kondratiuk <taras.kondratiuk@linaro.org>
[wangnan: backport to 3.10 and 3.14:
 - adjust context
 - backport all changes on arch/arm/kernel/probes.c to
   arch/arm/kernel/kprobes-common.c since we don't have
   commit c18377c303787ded44b7decd7dee694db0f205e9.
 - After the above adjustments, becomes same to Taras Kondratiuk's
   original patch:
     http://lists.linaro.org/pipermail/linaro-kernel/2014-January/010346.html
]
Signed-off-by: Wang Nan <wangnan0@huawei.com>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
arch/arm/kernel/kprobes-common.c
arch/arm/kernel/kprobes-thumb.c
arch/arm/kernel/kprobes.c