Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1706065 > unrolled thread

[PATCH] powerpc/32: Fix boot failure on non 6xx platforms

Started byChristophe Leroy <christophe.leroy@c-s.fr>
First post2017-08-08 08:40 +0200
Last post2017-08-08 13:00 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] powerpc/32: Fix boot failure on non 6xx platforms Christophe Leroy <christophe.leroy@c-s.fr> - 2017-08-08 08:40 +0200
    Re: powerpc/32: Fix boot failure on non 6xx platforms Michael Ellerman <patch-notifications@ellerman.id.au> - 2017-08-08 13:00 +0200

#1706065 — [PATCH] powerpc/32: Fix boot failure on non 6xx platforms

FromChristophe Leroy <christophe.leroy@c-s.fr>
Date2017-08-08 08:40 +0200
Subject[PATCH] powerpc/32: Fix boot failure on non 6xx platforms
Message-ID<uc6lj-3ZY-13@gated-at.bofh.it>
commit d300627c6a536 ("powerpc/6xx: Handle DABR match before
calling do_page_fault") breaks non 6xx platforms.

[    6.029556] Failed to execute /init (error -14)
[    6.034623] Starting init: /bin/sh exists but couldn't execute it
(error -14)
[    6.041489] Kernel panic - not syncing: No working init found.  Try
passing init= option to kernel. See Linux
Documentation/admin-guide/init.rst for guidance.
[    6.055518] CPU: 0 PID: 1 Comm: init Not tainted
4.13.0-rc3-s3k-dev-00143-g7aa62e972a56 #56
[    6.063745] Call Trace:
[    6.066224] [c60f1ed0] [c001a624] panic+0x108/0x250 (unreliable)
[    6.072140] [c60f1f30] [c0002640] rootfs_mount+0x0/0x58
[    6.077311] [c60f1f40] [c000cb80] ret_from_kernel_thread+0x5c/0x64
[    6.083405] Rebooting in 180 seconds..

This is because in handle_page_fault(), the call to do_page_fault()
has been mistakenly enclosed inside an #ifdef CONFIG_6xx

Fixes: d300627c6a536 ("powerpc/6xx: Handle DABR match before
calling do_page_fault")

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
---
 arch/powerpc/kernel/entry_32.S | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/powerpc/kernel/entry_32.S b/arch/powerpc/kernel/entry_32.S
index dff51ea52e49..b14bf7def2e2 100644
--- a/arch/powerpc/kernel/entry_32.S
+++ b/arch/powerpc/kernel/entry_32.S
@@ -586,11 +586,11 @@ ppc_swapcontext:
 handle_page_fault:
 	stw	r4,_DAR(r1)
 	addi	r3,r1,STACK_FRAME_OVERHEAD
-	andis.  r0,r5,DSISR_DABRMATCH@h
 #ifdef CONFIG_6xx
+	andis.  r0,r5,DSISR_DABRMATCH@h
 	bne-    handle_dabr_fault
-	bl	do_page_fault
 #endif
+	bl	do_page_fault
 	cmpwi	r3,0
 	beq+	ret_from_except
 	SAVE_NVGPRS(r1)
-- 
2.13.3

[toc] | [next] | [standalone]


#1706331 — Re: powerpc/32: Fix boot failure on non 6xx platforms

FromMichael Ellerman <patch-notifications@ellerman.id.au>
Date2017-08-08 13:00 +0200
SubjectRe: powerpc/32: Fix boot failure on non 6xx platforms
Message-ID<ucaoX-7av-31@gated-at.bofh.it>
In reply to#1706065
On Tue, 2017-08-08 at 06:37:24 UTC, Christophe Leroy wrote:
> commit d300627c6a536 ("powerpc/6xx: Handle DABR match before
> calling do_page_fault") breaks non 6xx platforms.
> 
> [    6.029556] Failed to execute /init (error -14)
> [    6.034623] Starting init: /bin/sh exists but couldn't execute it
> (error -14)
> [    6.041489] Kernel panic - not syncing: No working init found.  Try
> passing init= option to kernel. See Linux
> Documentation/admin-guide/init.rst for guidance.
> [    6.055518] CPU: 0 PID: 1 Comm: init Not tainted
> 4.13.0-rc3-s3k-dev-00143-g7aa62e972a56 #56
> [    6.063745] Call Trace:
> [    6.066224] [c60f1ed0] [c001a624] panic+0x108/0x250 (unreliable)
> [    6.072140] [c60f1f30] [c0002640] rootfs_mount+0x0/0x58
> [    6.077311] [c60f1f40] [c000cb80] ret_from_kernel_thread+0x5c/0x64
> [    6.083405] Rebooting in 180 seconds..
> 
> This is because in handle_page_fault(), the call to do_page_fault()
> has been mistakenly enclosed inside an #ifdef CONFIG_6xx
> 
> Fixes: d300627c6a536 ("powerpc/6xx: Handle DABR match before
> calling do_page_fault")
> 
> Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>

Applied to powerpc next, thanks.

https://git.kernel.org/powerpc/c/64d0a506fbdd64906f168539bee32a

cheers

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web