Path: blob/master/arch/arm/mach-ixp2000/include/mach/entry-macro.S
10820 views
/*1* arch/arm/mach-ixp2000/include/mach/entry-macro.S2*3* Low-level IRQ helper macros for IXP2000-based platforms4*5* This file is licensed under the terms of the GNU General Public6* License version 2. This program is licensed "as is" without any7* warranty of any kind, whether express or implied.8*/9#include <mach/irqs.h>1011.macro disable_fiq12.endm1314.macro get_irqnr_preamble, base, tmp15.endm1617.macro arch_ret_to_user, tmp1, tmp218.endm1920.macro get_irqnr_and_base, irqnr, irqstat, base, tmp2122mov \irqnr, #0x0 @clear out irqnr as default23mov \base, #0xfe00000024orr \base, \base, #0x00e0000025orr \base, \base, #0x0826ldr \irqstat, [\base] @ get interrupts2728cmp \irqstat, #029beq 1001f3031clz \irqnr, \irqstat32mov \base, #3133subs \irqnr, \base, \irqnr3435/*36* We handle PCIA and PCIB here so we don't have an37* extra layer of code just to check these two bits.38*/39cmp \irqnr, #IRQ_IXP2000_PCI40bne 1001f4142mov \base, #0xfe00000043orr \base, \base, #0x00c0000044orr \base, \base, #0x0000010045orr \base, \base, #0x0000005846ldr \irqstat, [\base]4748mov \tmp, #(1<<26)49tst \irqstat, \tmp50movne \irqnr, #IRQ_IXP2000_PCIA51bne 1001f5253mov \tmp, #(1<<27)54tst \irqstat, \tmp55movne \irqnr, #IRQ_IXP2000_PCIB56571001:58.endm59606162