entry-macro.S 957 B

1234567891011121314151617181920212223242526272829303132333435
  1. /*
  2. * include/asm-arm/arch-iop33x/entry-macro.S
  3. *
  4. * Low-level IRQ helper macros for IOP33x-based platforms
  5. *
  6. * This file is licensed under the terms of the GNU General Public
  7. * License version 2. This program is licensed "as is" without any
  8. * warranty of any kind, whether express or implied.
  9. */
  10. #include <asm/arch/irqs.h>
  11. .macro disable_fiq
  12. .endm
  13. /*
  14. * Note: only deal with normal interrupts, not FIQ
  15. */
  16. .macro get_irqnr_and_base, irqnr, irqstat, base, tmp
  17. mov \irqnr, #0
  18. ldr \base, =IOP3XX_REG_ADDR(0x7A0)
  19. ldr \irqstat, [\base] @ Read IINTSRC0
  20. cmp \irqstat, #0
  21. bne 1002f
  22. ldr \irqstat, [\base, #4] @ Read IINTSRC1
  23. cmp \irqstat, #0
  24. beq 1001f
  25. clz \irqnr, \irqstat
  26. rsbs \irqnr,\irqnr,#31 @ recommend by RMK
  27. add \irqnr,\irqnr,#IRQ_IOP331_XINT8
  28. b 1001f
  29. 1002: clz \irqnr, \irqstat
  30. rsbs \irqnr,\irqnr,#31 @ recommend by RMK
  31. add \irqnr,\irqnr,#IRQ_IOP331_DMA0_EOT
  32. 1001:
  33. .endm