entry-macro-vic.S 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. /*
  2. * Copyright (C) 2007 Google, Inc.
  3. * Author: Brian Swetland <swetland@google.com>
  4. *
  5. * This software is licensed under the terms of the GNU General Public
  6. * License version 2, as published by the Free Software Foundation, and
  7. * may be copied, distributed, and modified under those terms.
  8. *
  9. * This program is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. * GNU General Public License for more details.
  13. *
  14. */
  15. #include <mach/msm_iomap.h>
  16. .macro disable_fiq
  17. .endm
  18. .macro get_irqnr_preamble, base, tmp
  19. @ enable imprecise aborts
  20. cpsie a
  21. mov \base, #MSM_VIC_BASE
  22. .endm
  23. .macro arch_ret_to_user, tmp1, tmp2
  24. .endm
  25. .macro get_irqnr_and_base, irqnr, irqstat, base, tmp
  26. @ 0xD0 has irq# or old irq# if the irq has been handled
  27. @ 0xD4 has irq# or -1 if none pending *but* if you just
  28. @ read 0xD4 you never get the first irq for some reason
  29. ldr \irqnr, [\base, #0xD0]
  30. ldr \irqnr, [\base, #0xD4]
  31. cmp \irqnr, #0xffffffff
  32. .endm