Christophe Leroy
c12ab8dbc4
powerpc/8xx: Fix Oops with STRICT_KERNEL_RWX without DEBUG_RODATA_TEST
Until now, all tests involving CONFIG_STRICT_KERNEL_RWX were done with
DEBUG_RODATA_TEST to check the result. But now that
CONFIG_STRICT_KERNEL_RWX is selected by default, it came without
CONFIG_DEBUG_RODATA_TEST and led to the following Oops
[ 6.830908] Freeing unused kernel image (initmem) memory: 352K
[ 6.840077] BUG: Unable to handle kernel data access on write at 0xc1285200
[ 6.846836] Faulting instruction address: 0xc0004b6c
[ 6.851745] Oops: Kernel access of bad area, sig: 11 [#1]
[ 6.857075] BE PAGE_SIZE=16K PREEMPT CMPC885
[ 6.861348] SAF3000 DIE NOTIFICATION
[ 6.864830] CPU: 0 PID: 1 Comm: swapper Not tainted 5.15.0-rc5-s3k-dev-02255-g2747d7b7916f #451
[ 6.873429] NIP: c0004b6c LR: c0004b60 CTR: 00000000
[ 6.878419] REGS: c902be60 TRAP: 0300 Not tainted (5.15.0-rc5-s3k-dev-02255-g2747d7b7916f)
[ 6.886852] MSR: 00009032 <EE,ME,IR,DR,RI> CR: 53000335 XER: 8000ff40
[ 6.893564] DAR: c1285200 DSISR: 82000000
[ 6.893564] GPR00: 0c000000 c902bf20 c20f4000 08000000 00000001 04001f00 c1800000 00000035
[ 6.893564] GPR08: ff0001ff c1280000 00000002 c0004b60 00001000 00000000 c0004b1c 00000000
[ 6.893564] GPR16: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[ 6.893564] GPR24: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 c1060000
[ 6.932034] NIP [c0004b6c] kernel_init+0x50/0x138
[ 6.936682] LR [c0004b60] kernel_init+0x44/0x138
[ 6.941245] Call Trace:
[ 6.943653] [c902bf20] [c0004b60] kernel_init+0x44/0x138 (unreliable)
[ 6.950022] [c902bf30] [c001122c] ret_from_kernel_thread+0x5c/0x64
[ 6.956135] Instruction dump:
[ 6.959060] 48ffc521 48045469 4800d8cd 3d20c086 89295fa0 2c090000 41820058 480796c9
[ 6.966890] 4800e48d 3d20c128 39400002 3fe0c106 <91495200> 3bff8000 4806fa1d 481f7d75
[ 6.974902] ---[ end trace 1e397bacba4aa610 ]---
0xc1285200 corresponds to 'system_state' global var that the kernel is trying to set to
SYSTEM_RUNNING. This var is above the RO/RW limit so it shouldn't Oops.
It oopses because the dirty bit is missing.
Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/3d5800b0bbcd7b19761b98f50421358667b45331.1635520232.git.christophe.leroy@csgroup.eu
2021-11-01 21:39:03 +11:00
..
2021-08-26 21:21:07 +10:00
2021-09-08 15:32:35 -07:00
2021-06-17 00:09:00 +10:00
2021-04-30 12:22:28 -07:00
2021-07-29 23:13:12 +10:00
2020-03-25 11:50:48 +01:00
2021-10-22 15:22:05 +11:00
2021-09-03 22:54:12 +10:00
2021-10-27 22:30:32 +11:00
2020-10-25 14:51:49 -07:00
2021-08-04 10:53:39 +10:00
2021-10-27 22:30:32 +11:00
2020-06-02 20:59:11 +10:00
2020-12-05 21:49:18 +11:00
2020-12-04 01:01:29 +11:00
2021-01-29 10:05:51 +05:30
2021-06-17 00:09:00 +10:00
2021-08-13 22:04:26 +10:00
2021-02-09 00:10:49 +11:00
2020-11-27 10:33:42 +01:00
2021-01-29 10:05:51 +05:30
2019-11-13 19:27:40 +11:00
2021-08-13 22:04:26 +10:00
2020-08-07 18:48:15 -07:00
2020-10-07 22:34:47 +11:00
2020-07-26 23:34:20 +10:00
2021-10-13 16:45:33 +11:00
2021-08-25 13:35:47 +10:00
2021-08-15 13:49:24 +10:00
2021-06-17 00:09:00 +10:00
2021-08-26 21:21:07 +10:00
2021-08-20 22:35:18 +10:00
2021-08-13 22:04:26 +10:00
2021-10-09 00:15:59 +11:00
2021-08-18 23:49:55 +10:00
2021-08-25 13:35:47 +10:00
2021-11-01 21:39:03 +11:00
2021-06-25 00:07:10 +10:00
2021-06-17 00:09:10 +10:00
2021-08-25 13:35:47 +10:00
2021-07-26 20:38:51 +10:00
2021-08-07 08:53:59 +10:00
2021-10-29 23:12:37 +11:00
2021-09-03 11:22:50 -07:00
2021-10-22 15:22:06 +11:00
2021-08-13 22:04:26 +10:00
2021-03-29 13:22:10 +11:00
2021-04-08 21:17:45 +10:00
2021-03-29 13:22:10 +11:00
2020-11-24 16:47:35 +01:00
2020-05-07 17:25:54 +10:00
2021-09-13 22:34:11 +10:00
2021-10-27 22:33:47 +11:00
2021-05-28 22:54:27 +10:00
2020-12-04 01:01:09 +11:00
2021-09-03 11:22:50 -07:00
2021-08-12 22:21:57 +10:00
2021-04-30 11:20:40 -07:00
2021-06-17 00:09:00 +10:00
2021-08-13 22:04:26 +10:00
2021-06-25 00:06:55 +10:00
2021-06-25 00:06:55 +10:00
2021-08-09 16:31:54 +10:00
2020-10-08 21:17:13 +11:00
2021-05-12 11:07:39 +10:00
2021-10-27 22:30:32 +11:00
2021-06-21 21:13:19 +10:00
2021-09-13 22:34:12 +10:00
2021-08-25 13:35:47 +10:00
2021-08-25 13:35:47 +10:00
2021-08-25 13:35:47 +10:00
2021-06-16 00:16:48 +10:00
2021-06-16 00:16:48 +10:00
2021-06-21 21:13:20 +10:00
2021-03-08 11:43:27 +01:00
2020-07-26 23:34:19 +10:00
2021-04-21 22:52:32 +10:00
2021-06-25 14:46:51 +10:00
2021-05-17 15:27:15 +10:00
2021-04-30 11:20:40 -07:00
2021-02-09 00:01:05 +11:00
2020-01-06 16:25:29 +11:00
2021-08-10 23:14:57 +10:00
2020-05-18 21:58:44 +10:00
2020-04-04 21:40:57 +11:00
2020-02-04 03:05:26 +00:00
2021-08-26 21:21:07 +10:00
2021-09-03 15:33:47 -07:00
2021-09-03 15:33:47 -07:00
2021-08-25 13:35:47 +10:00
2020-02-04 03:05:26 +00:00
2020-06-09 09:39:13 -07:00
2021-04-14 23:04:16 +10:00
2021-06-25 14:47:20 +10:00
2021-08-19 09:02:55 +09:00
2021-08-10 23:14:56 +10:00
2020-07-16 14:49:53 +10:00
2021-08-13 22:04:26 +10:00
2019-11-13 00:33:22 +11:00
2019-11-13 00:33:22 +11:00
2021-06-17 00:09:00 +10:00
2021-08-13 22:04:26 +10:00
2021-10-22 15:22:05 +11:00
2021-02-09 00:10:50 +11:00
2021-06-25 00:06:55 +10:00
2021-06-25 00:06:55 +10:00
2021-06-25 00:06:55 +10:00
2021-05-12 11:07:39 +10:00
2021-08-27 00:56:54 +10:00
2021-08-03 22:33:37 +10:00
2021-10-22 15:22:05 +11:00
2020-06-02 20:59:11 +10:00
2021-10-22 15:22:05 +11:00
2021-10-22 15:22:05 +11:00
2021-02-11 23:35:07 +11:00
2021-08-25 13:35:48 +10:00
2021-10-09 00:16:00 +11:00
2021-04-14 23:04:16 +10:00
2021-08-20 17:00:53 +10:00
2021-10-22 15:22:05 +11:00
2020-10-06 23:22:25 +11:00
2021-09-08 12:55:35 -07:00
2021-06-21 21:16:31 +10:00
2021-08-19 09:02:55 +09:00
2021-06-25 00:06:55 +10:00
2021-01-30 22:23:42 +11:00
2021-01-30 22:23:42 +11:00
2021-04-14 23:04:44 +10:00
2020-05-19 00:10:37 +10:00
2021-08-18 23:49:55 +10:00
2021-10-14 21:47:34 +11:00
2021-08-30 16:36:10 +02:00