linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Christophe Leroy <christophe.leroy@csgroup.eu>
To: Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	Paul Mackerras <paulus@samba.org>,
	Michael Ellerman <mpe@ellerman.id.au>
Cc: linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org
Subject: [RFC PATCH v1 08/11] powerpc/corenet: Change criteria to set MPIC_ENABLE_COREINT
Date: Fri,  3 Sep 2021 11:18:43 +0000 (UTC)	[thread overview]
Message-ID: <c8ef82ee5f2713f4c36eb5d2d49b0905c7472801.1630667612.git.christophe.leroy@csgroup.eu> (raw)
In-Reply-To: <cover.1630667612.git.christophe.leroy@csgroup.eu>

Don't use ppc_md function comparison.

Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
---
 arch/powerpc/platforms/85xx/corenet_generic.c | 2 +-
 arch/powerpc/sysdev/mpic.c                    | 4 +---
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/arch/powerpc/platforms/85xx/corenet_generic.c b/arch/powerpc/platforms/85xx/corenet_generic.c
index 8d6029099848..17ae75d62518 100644
--- a/arch/powerpc/platforms/85xx/corenet_generic.c
+++ b/arch/powerpc/platforms/85xx/corenet_generic.c
@@ -37,7 +37,7 @@ void __init corenet_gen_pic_init(void)
 	unsigned int flags = MPIC_BIG_ENDIAN | MPIC_SINGLE_DEST_CPU |
 		MPIC_NO_RESET;
 
-	if (ppc_md.get_irq == mpic_get_coreint_irq)
+	if (!IS_ENABLED(CONFIG_HOTPLUG_CPU) && !IS_ENABLED(CONFIG_KEXEC_CORE))
 		flags |= MPIC_ENABLE_COREINT;
 
 	mpic = mpic_alloc(NULL, 0, flags, 0, 512, " OpenPIC  ");
diff --git a/arch/powerpc/sysdev/mpic.c b/arch/powerpc/sysdev/mpic.c
index 995fb2ada507..68ff5c87294e 100644
--- a/arch/powerpc/sysdev/mpic.c
+++ b/arch/powerpc/sysdev/mpic.c
@@ -1405,10 +1405,8 @@ struct mpic * __init mpic_alloc(struct device_node *node,
 	 * with device trees generated by older versions of QEMU.
 	 * fsl_version will be zero if MPIC_FSL is not set.
 	 */
-	if (fsl_version < 0x400 && (flags & MPIC_ENABLE_COREINT)) {
-		WARN_ON(ppc_md.get_irq != mpic_get_coreint_irq);
+	if (fsl_version < 0x400 && (flags & MPIC_ENABLE_COREINT))
 		ppc_md.get_irq = mpic_get_irq;
-	}
 
 	/* Reset */
 
-- 
2.25.0


  parent reply	other threads:[~2021-09-03 11:19 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-03 11:18 [RFC PATCH v1 00/11] powerpc/machdep: Remove dust and convert to static calls Christophe Leroy
2021-09-03 11:18 ` [RFC PATCH v1 01/11] powerpc/time: Remove generic_suspend_{dis/en}able_irqs() Christophe Leroy
2021-09-03 11:18 ` [RFC PATCH v1 02/11] powerpc/machdep: Remove stale functions from ppc_md structure Christophe Leroy
2021-09-03 11:18 ` [RFC PATCH v1 03/11] powerpc/machdep: Remove CONFIG_PPC_HAS_FEATURE_CALLS Christophe Leroy
2021-09-03 11:18 ` [RFC PATCH v1 04/11] powerpc/machdep: Make probe_machine() static Christophe Leroy
2021-09-03 11:18 ` [RFC PATCH v1 05/11] powerpc/machdep: Move sys_ctrler_t definition into pmac.h Christophe Leroy
2022-02-07 11:18   ` Michael Ellerman
2021-09-03 11:18 ` [RFC PATCH v1 06/11] powerpc/machdep: Add helpers to use ppc_md. functions Christophe Leroy
2021-09-03 11:18 ` [RFC PATCH v1 07/11] powerpc/mpc86xx_hpcn: Remove obsolete statement Christophe Leroy
2021-09-03 11:18 ` Christophe Leroy [this message]
2021-09-03 11:18 ` [RFC PATCH v1 09/11] powerpc/platforms: Use ppc_md. helpers Christophe Leroy
2021-09-03 11:18 ` [RFC PATCH v1 10/11] powerpc/platforms: Use ppc_md_update() instead of define_machine() Christophe Leroy
2021-09-03 11:18 ` [RFC PATCH v1 11/11] powerpc/machdep: Convert ppc_md to static calls Christophe Leroy
2022-02-16 12:25 ` [RFC PATCH v1 00/11] powerpc/machdep: Remove dust and convert " Michael Ellerman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c8ef82ee5f2713f4c36eb5d2d49b0905c7472801.1630667612.git.christophe.leroy@csgroup.eu \
    --to=christophe.leroy@csgroup.eu \
    --cc=benh@kernel.crashing.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mpe@ellerman.id.au \
    --cc=paulus@samba.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).