lkml.org 
[lkml]   [2018]   [Sep]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] irqchip/mmp: use cpu_is_pj4() instead of CONFIG_CPU_MMP2
Date
CONFIG_CPU_MMP2 is not there on multiplatform kernels with MACH_MMP2_DT.
The MMP2 platform uses the PJ4 CPU.

Signed-off-by: Lubomir Rintel <lkundrak@v3.sk>
---
drivers/irqchip/irq-mmp.c | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/drivers/irqchip/irq-mmp.c b/drivers/irqchip/irq-mmp.c
index 25f32e1d7764..10aa2b553145 100644
--- a/drivers/irqchip/irq-mmp.c
+++ b/drivers/irqchip/irq-mmp.c
@@ -22,6 +22,7 @@
#include <linux/of_address.h>
#include <linux/of_irq.h>

+#include <asm/cputype.h>
#include <asm/exception.h>
#include <asm/hardirq.h>

@@ -74,11 +75,11 @@ static void icu_mask_ack_irq(struct irq_data *d)
r |= data->conf_disable;
writel_relaxed(r, mmp_icu_base + (hwirq << 2));
} else {
-#ifdef CONFIG_CPU_MMP2
- if ((data->virq_base == data->clr_mfp_irq_base)
- && (hwirq == data->clr_mfp_hwirq))
- mmp2_clear_pmic_int();
-#endif
+ if (cpu_is_pj4()) {
+ if ((data->virq_base == data->clr_mfp_irq_base)
+ && (hwirq == data->clr_mfp_hwirq))
+ mmp2_clear_pmic_int();
+ }
r = readl_relaxed(data->reg_mask) | (1 << hwirq);
writel_relaxed(r, data->reg_mask);
}
--
2.17.1
\
 
 \ /
  Last update: 2018-09-10 14:14    [W:0.055 / U:0.192 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site