Patchwork Remove a BUG_ON that triggered when running under FSL Hypervisor

login
register
mail settings
Submitter Laurentiu TUDOR
Date July 7, 2011, 1:44 p.m.
Message ID <1310046270-6654-1-git-send-email-Laurentiu.Tudor@freescale.com>
Download mbox | patch
Permalink /patch/103669/
State Accepted
Commit 2647aa19fb36326ae4d2642072e1e072d176a2fc
Headers show

Comments

Laurentiu TUDOR - July 7, 2011, 1:44 p.m.
mpc85xx_smp_init platform init function assumed that smp_ops.message_pass
was set to default arch dependent smp_muxed_ipi_message_pass.
However this does not seem to happen. Moreover, the arch specific code
in arch/powerpc/kernel/smp.c handles smp_ops.message_pass == NULL and if so
calls the default implementation.

Signed-off-by: Laurentiu TUDOR <Laurentiu.Tudor@freescale.com>
---
 arch/powerpc/platforms/85xx/smp.c |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)
Kumar Gala - July 8, 2011, 4:12 a.m.
On Jul 7, 2011, at 8:44 AM, Laurentiu TUDOR wrote:

> mpc85xx_smp_init platform init function assumed that smp_ops.message_pass
> was set to default arch dependent smp_muxed_ipi_message_pass.
> However this does not seem to happen. Moreover, the arch specific code
> in arch/powerpc/kernel/smp.c handles smp_ops.message_pass == NULL and if so
> calls the default implementation.
> 
> Signed-off-by: Laurentiu TUDOR <Laurentiu.Tudor@freescale.com>
> ---
> arch/powerpc/platforms/85xx/smp.c |    9 +++++----
> 1 files changed, 5 insertions(+), 4 deletions(-)

Re-worded commit message a bit, applied to next

- k

Patch

diff --git a/arch/powerpc/platforms/85xx/smp.c b/arch/powerpc/platforms/85xx/smp.c
index f5aa619..5b9b901 100644
--- a/arch/powerpc/platforms/85xx/smp.c
+++ b/arch/powerpc/platforms/85xx/smp.c
@@ -2,7 +2,7 @@ 
  * Author: Andy Fleming <afleming@freescale.com>
  * 	   Kumar Gala <galak@kernel.crashing.org>
  *
- * Copyright 2006-2008 Freescale Semiconductor Inc.
+ * Copyright 2006-2008, 2011 Freescale Semiconductor Inc.
  *
  * This program is free software; you can redistribute  it and/or modify it
  * under  the terms of  the GNU General  Public License as published by the
@@ -239,12 +239,13 @@  void __init mpc85xx_smp_init(void)
 	}
 
 	if (cpu_has_feature(CPU_FTR_DBELL)) {
-		/* .message_pass defaults to smp_muxed_ipi_message_pass */
+		/*
+		 * If left NULL, .message_pass defaults to
+		 * smp_muxed_ipi_message_pass
+		 */
 		smp_85xx_ops.cause_ipi = doorbell_cause_ipi;
 	}
 
-	BUG_ON(!smp_85xx_ops.message_pass);
-
 	smp_ops = &smp_85xx_ops;
 
 #ifdef CONFIG_KEXEC