All of lore.kernel.org
 help / color / mirror / Atom feed
diff for duplicates of <56E9DB85.9090405@gmail.com>

diff --git a/a/2.txt b/N1/2.txt
index 8b13789..8405c69 100644
--- a/a/2.txt
+++ b/N1/2.txt
@@ -1 +1,45 @@
+>From fca2323ade4dd67e5fed6933a32e6739d3707ff7 Mon Sep 17 00:00:00 2001
+From: Qais Yousef <qsyousef@gmail.com>
+Date: Wed, 16 Mar 2016 21:55:04 +0000
+Subject: [PATCH] MIPS: Fix broken malta qemu
 
+Malta defconfig compile with GIC on. Hence when compiling for SMP it causes the
+new IPI code to be activated. But on qemu malta there's no GIC causing a
+BUG_ON(!ipidomain) to be hit in mips_smp_ipi_init().
+
+Introduce an extra check that gic_preset is true and skip initialising IPIs if
+it's not.
+
+Signed-off-by: Qais Yousef <qsyousef@gmail.com>
+---
+ arch/mips/kernel/smp.c | 8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+diff --git a/arch/mips/kernel/smp.c b/arch/mips/kernel/smp.c
+index 37708d9..972f64d 100644
+--- a/arch/mips/kernel/smp.c
++++ b/arch/mips/kernel/smp.c
+@@ -33,6 +33,7 @@
+ #include <linux/cpu.h>
+ #include <linux/err.h>
+ #include <linux/ftrace.h>
++#include <linux/irqchip/mips-gic.h>
+ #include <linux/irqdomain.h>
+ #include <linux/of.h>
+ #include <linux/of_irq.h>
+@@ -243,6 +244,13 @@ static int __init mips_smp_ipi_init(void)
+ 	struct irq_domain *ipidomain;
+ 	struct device_node *node;
+ 
++	/*
++	 * If the config says GIC is present, but the harware doesn't actually
++	 * have it we could get stuffed, so double check that GIC is present
++	 */
++	if (WARN_ON(!gic_present))
++		return 0;
++
+ 	node = of_irq_find_parent(of_root);
+ 	ipidomain = irq_find_matching_host(node, DOMAIN_BUS_IPI);
+ 
+-- 
+1.9.1
diff --git a/a/content_digest b/N1/content_digest
index 320dfed..9a42966 100644
--- a/a/content_digest
+++ b/N1/content_digest
@@ -79,5 +79,50 @@
  "\01:2\0"
  "fn\00001-MIPS-Fix-broken-malta-qemu.patch\0"
  "b\0"
+ ">From fca2323ade4dd67e5fed6933a32e6739d3707ff7 Mon Sep 17 00:00:00 2001\n"
+ "From: Qais Yousef <qsyousef@gmail.com>\n"
+ "Date: Wed, 16 Mar 2016 21:55:04 +0000\n"
+ "Subject: [PATCH] MIPS: Fix broken malta qemu\n"
+ "\n"
+ "Malta defconfig compile with GIC on. Hence when compiling for SMP it causes the\n"
+ "new IPI code to be activated. But on qemu malta there's no GIC causing a\n"
+ "BUG_ON(!ipidomain) to be hit in mips_smp_ipi_init().\n"
+ "\n"
+ "Introduce an extra check that gic_preset is true and skip initialising IPIs if\n"
+ "it's not.\n"
+ "\n"
+ "Signed-off-by: Qais Yousef <qsyousef@gmail.com>\n"
+ "---\n"
+ " arch/mips/kernel/smp.c | 8 ++++++++\n"
+ " 1 file changed, 8 insertions(+)\n"
+ "\n"
+ "diff --git a/arch/mips/kernel/smp.c b/arch/mips/kernel/smp.c\n"
+ "index 37708d9..972f64d 100644\n"
+ "--- a/arch/mips/kernel/smp.c\n"
+ "+++ b/arch/mips/kernel/smp.c\n"
+ "@@ -33,6 +33,7 @@\n"
+ " #include <linux/cpu.h>\n"
+ " #include <linux/err.h>\n"
+ " #include <linux/ftrace.h>\n"
+ "+#include <linux/irqchip/mips-gic.h>\n"
+ " #include <linux/irqdomain.h>\n"
+ " #include <linux/of.h>\n"
+ " #include <linux/of_irq.h>\n"
+ "@@ -243,6 +244,13 @@ static int __init mips_smp_ipi_init(void)\n"
+ " \tstruct irq_domain *ipidomain;\n"
+ " \tstruct device_node *node;\n"
+ " \n"
+ "+\t/*\n"
+ "+\t * If the config says GIC is present, but the harware doesn't actually\n"
+ "+\t * have it we could get stuffed, so double check that GIC is present\n"
+ "+\t */\n"
+ "+\tif (WARN_ON(!gic_present))\n"
+ "+\t\treturn 0;\n"
+ "+\n"
+ " \tnode = of_irq_find_parent(of_root);\n"
+ " \tipidomain = irq_find_matching_host(node, DOMAIN_BUS_IPI);\n"
+ " \n"
+ "-- \n"
+ 1.9.1
 
-eec2ebc9b42149903dd83238156ef7f9ec6a43c09a97e5c6c035b51aa5fdea9b
+f194cd398962320c6b6010ef2794eaa64675524509479a7bd8ed63c8e12e0e63

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.