mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-26 13:05:08 +07:00
c24b31147a
Merge irq-pxa168 and irq-mmp2. And support device tree also. Since CONFIG_SPARSE_IRQ is enabled in arch-mmp, base irq starts from NR_IRQS_LEGACY. Signed-off-by: Haojian Zhuang <haojian.zhuang@gmail.com> Acked-by: Arnd Bergmann <arnd@arndb.de>
27 lines
716 B
ArmAsm
27 lines
716 B
ArmAsm
/*
|
|
* linux/arch/arm/mach-mmp/include/mach/entry-macro.S
|
|
*
|
|
* This program is free software; you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License version 2 as
|
|
* published by the Free Software Foundation.
|
|
*/
|
|
|
|
#include <asm/irq.h>
|
|
#include <mach/regs-icu.h>
|
|
|
|
.macro get_irqnr_preamble, base, tmp
|
|
mrc p15, 0, \tmp, c0, c0, 0 @ CPUID
|
|
and \tmp, \tmp, #0xff00
|
|
cmp \tmp, #0x5800
|
|
ldr \base, =mmp_icu_base
|
|
ldr \base, [\base, #0]
|
|
addne \base, \base, #0x10c @ PJ1 AP INT SEL register
|
|
addeq \base, \base, #0x104 @ PJ4 IRQ SEL register
|
|
.endm
|
|
|
|
.macro get_irqnr_and_base, irqnr, irqstat, base, tmp
|
|
ldr \tmp, [\base, #0]
|
|
and \irqnr, \tmp, #0x3f
|
|
tst \tmp, #(1 << 6)
|
|
.endm
|