Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1402743
| From | Matt Redfearn <matt.redfearn@imgtec.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 3/3] irqchip: mips-gic: Setup EIC mode on each CPU if it's in use |
| Date | 2016-05-18 09:00 +0200 |
| Message-ID | <rA3Cx-6WR-5@gated-at.bofh.it> (permalink) |
| References | <rzOka-5Kj-9@gated-at.bofh.it> <rzOka-5Kj-35@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 17/05/16 15:31, Paul Burton wrote:
> When EIC mode is in use (cpu_has_veic is true) enable it on each CPU
> during GIC initialisation. Otherwise there may be a mismatch between the
> hardware default interrupt model & that expected by the kernel.
>
> Signed-off-by: Paul Burton <paul.burton@imgtec.com>
> ---
>
> drivers/irqchip/irq-mips-gic.c | 10 +++++++++-
> 1 file changed, 9 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/irqchip/irq-mips-gic.c b/drivers/irqchip/irq-mips-gic.c
> index 4dffccf..bc23c92 100644
> --- a/drivers/irqchip/irq-mips-gic.c
> +++ b/drivers/irqchip/irq-mips-gic.c
> @@ -956,7 +956,7 @@ static void __init __gic_init(unsigned long gic_base_addr,
> unsigned int cpu_vec, unsigned int irqbase,
> struct device_node *node)
> {
> - unsigned int gicconfig;
> + unsigned int gicconfig, cpu;
> unsigned int v[2];
>
> __gic_base_addr = gic_base_addr;
> @@ -973,6 +973,14 @@ static void __init __gic_init(unsigned long gic_base_addr,
> gic_vpes = gic_vpes + 1;
>
> if (cpu_has_veic) {
> + /* Set EIC mode for all VPEs */
> + for_each_present_cpu(cpu) {
> + gic_write(GIC_REG(VPE_LOCAL, GIC_VPE_OTHER_ADDR),
> + mips_cm_vp_id(cpu));
> + gic_write(GIC_REG(VPE_OTHER, GIC_VPE_CTL),
> + GIC_VPE_CTL_EIC_MODE_MSK);
> + }
> +
> /* Always use vector 1 in EIC mode */
> gic_cpu_pin = 0;
> timer_cpu_pin = gic_cpu_pin;
Hi Paul
Reviewed-by: Matt Redfearn <matt.redfearn@imgtec.com>
Tested-by: Matt Redfearn <matt.redfearn@imgtec.com>
Thanks,
Matt
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 0/3] External Interrupt Controller (EIC) fixes Paul Burton <paul.burton@imgtec.com> - 2016-05-17 16:40 +0200
[PATCH 3/3] irqchip: mips-gic: Setup EIC mode on each CPU if it's in use Paul Burton <paul.burton@imgtec.com> - 2016-05-17 16:40 +0200
Re: [PATCH 3/3] irqchip: mips-gic: Setup EIC mode on each CPU if it's in use Matt Redfearn <matt.redfearn@imgtec.com> - 2016-05-18 09:00 +0200
[PATCH 2/3] MIPS: smp-cps: Clear Status IPL field when using EIC Paul Burton <paul.burton@imgtec.com> - 2016-05-17 16:40 +0200
Re: [PATCH 2/3] MIPS: smp-cps: Clear Status IPL field when using EIC Matt Redfearn <matt.redfearn@imgtec.com> - 2016-05-18 09:00 +0200
Re: [PATCH 0/3] External Interrupt Controller (EIC) fixes Thomas Gleixner <tglx@linutronix.de> - 2016-05-19 11:30 +0200
Re: [PATCH 0/3] External Interrupt Controller (EIC) fixes Ralf Baechle <ralf@linux-mips.org> - 2016-05-19 14:40 +0200
csiph-web