[PATCH 0/5 v16] KASan for Arm

Ahmad Fatoum a.fatoum at pengutronix.de
Thu Nov 5 17:10:08 EST 2020


Hello,

On 10/19/20 10:41 AM, Linus Walleij wrote:
> This is the 16th and final (knock on wood) version of
> KASan for ARM32

I was about to report an apparent incompatibility with ftrace (see below),
but I can't reproduce this when rebasing the patch stack onto v5.10-rc2.

I paste the log here anyway in case someone else runs into it. I don't
know which commit between v5.9.5 and v5.10-rc2 is to thank for fixing/masking
the splat.

[    0.000000] ftrace: allocating 31200 entries in 61 pages
[    0.000000] ------------[ cut here ]------------
[    0.000000] WARNING: CPU: 0 PID: 0 at arch/arm/kernel/insn.c:47 __arm_gen_branch+0x78/0x80
[    0.000000] Modules linked in:
[    0.000000] CPU: 0 PID: 0 Comm: swapper Not tainted 5.9.5-20201105-1 #1
[    0.000000] Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree)
[    0.000000] Backtrace:
[    0.000000] [<c1eaed78>] (dump_backtrace) from [<c1eaf120>] (show_stack+0x20/0x24)
[    0.000000]  r7:600000d3 r6:c2730b80 r5:00000000 r4:c2730b80
[    0.000000] [<c1eaf100>] (show_stack) from [<c1eb8130>] (dump_stack+0x8c/0xa4)
[    0.000000] [<c1eb80a4>] (dump_stack) from [<c015a2dc>] (__warn+0x284/0x2bc)
[    0.000000]  r7:0000002f r6:00000009 r5:c01267a4 r4:c1f094a0
[    0.000000] [<c015a058>] (__warn) from [<c1eb01b4>] (warn_slowpath_fmt+0xc0/0x140)
[    0.000000]  r9:c01267a4 r8:0000002f r7:c1f094a0 r6:00000000 r5:c2603ec0 r4:b74c07cc
[    0.000000] [<c1eb00f8>] (warn_slowpath_fmt) from [<c01267a4>] (__arm_gen_branch+0x78/0x80)
[    0.000000]  r10:e605ab68 r9:c0125f48 r8:c2607070 r7:00000000 r6:0000756d r5:0000056e
[    0.000000]  r4:00000000
[    0.000000] [<c012672c>] (__arm_gen_branch) from [<c012654c>] (ftrace_make_nop+0x58/0x88)
[    0.000000]  r5:0000056e r4:c2500354
[    0.000000] [<c01264f4>] (ftrace_make_nop) from [<c03c3d04>] (ftrace_process_locs+0x8d8/0xc60)
[    0.000000]  r4:e6003a00
[    0.000000] [<c03c342c>] (ftrace_process_locs) from [<c251e628>] (ftrace_init+0x90/0x140)
[    0.000000]  r10:10c5387d r9:c1f43ba8 r8:c25c8250 r7:c25a9ad0 r6:00000001 r5:c2607070
[    0.000000]  r4:c2908b80
[    0.000000] [<c251e598>] (ftrace_init) from [<c2501698>] (start_kernel+0x160/0x34c)
[    0.000000]  r9:00000001 r8:c2606ec0 r7:00000000 r6:c2606ec0 r5:c28bc000 r4:ffffffff
[    0.000000] [<c2501538>] (start_kernel) from [<00000000>] (0x0)
[    0.000000]  r9:412fc09a r8:18000000 r7:00000000 r6:10c0387d r5:00000051 r4:c2500334
[    0.000000] ---[ end trace bec787061c40ac80 ]---
[    0.000000] ------------[ ftrace bug ]------------
[    0.000000] ftrace failed to modify
[    0.000000] [<c2500354>] set_reset_devices+0x10/0x28
[    0.000000]  actual:   a7:d9:01:eb
[    0.000000] Initializing ftrace call sites
[    0.000000] ftrace record flags: 0
[    0.000000]  (0)
[    0.000000]  expected tramp: c0125f54
[    0.000000] ------------[ cut here ]------------
[    0.000000] WARNING: CPU: 0 PID: 0 at kernel/trace/ftrace.c:2065 ftrace_bug+0x328/0x39c
[    0.000000] Modules linked in:
[    0.000000] CPU: 0 PID: 0 Comm: swapper Tainted: G        W         5.9.5-20201105-1 #1
[    0.000000] Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree)
[    0.000000] Backtrace:
[    0.000000] [<c1eaed78>] (dump_backtrace) from [<c1eaf120>] (show_stack+0x20/0x24)
[    0.000000]  r7:600000d3 r6:c2730b80 r5:00000000 r4:c2730b80
[    0.000000] [<c1eaf100>] (show_stack) from [<c1eb8130>] (dump_stack+0x8c/0xa4)
[    0.000000] [<c1eb80a4>] (dump_stack) from [<c015a2dc>] (__warn+0x284/0x2bc)
[    0.000000]  r7:00000811 r6:00000009 r5:c1eb4f3c r4:c1f42960
[    0.000000] [<c015a058>] (__warn) from [<c1eb01b4>] (warn_slowpath_fmt+0xc0/0x140)
[    0.000000]  r9:c1eb4f3c r8:00000811 r7:c1f42960 r6:00000000 r5:c2603ec0 r4:b74c07cc
[    0.000000] [<c1eb00f8>] (warn_slowpath_fmt) from [<c1eb4f3c>] (ftrace_bug+0x328/0x39c)
[    0.000000]  r10:e605ab68 r9:00000000 r8:c2607070 r7:bbc0b56d r6:e605ab6c r5:00000000
[    0.000000]  r4:e605ab68
[    0.000000] [<c1eb4c14>] (ftrace_bug) from [<c03c3a8c>] (ftrace_process_locs+0x660/0xc60)
[    0.000000]  r7:c0125f48 r6:0000756d r5:0000056e r4:e6003a00
[    0.000000] [<c03c342c>] (ftrace_process_locs) from [<c251e628>] (ftrace_init+0x90/0x140)
[    0.000000]  r10:10c5387d r9:c1f43ba8 r8:c25c8250 r7:c25a9ad0 r6:00000001 r5:c2607070
[    0.000000]  r4:c2908b80
[    0.000000] [<c251e598>] (ftrace_init) from [<c2501698>] (start_kernel+0x160/0x34c)
[    0.000000]  r9:00000001 r8:c2606ec0 r7:00000000 r6:c2606ec0 r5:c28bc000 r4:ffffffff
[    0.000000] [<c2501538>] (start_kernel) from [<00000000>] (0x0)
[    0.000000]  r9:412fc09a r8:18000000 r7:00000000 r6:10c0387d r5:00000051 r4:c2500334
[    0.000000] ---[ end trace bec787061c40ac81 ]---
[    0.000000] ftrace: allocated 61 pages with 5 groups



-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |



More information about the linux-arm-kernel mailing list