bcm2835_ic.h 801 B

123456789101112131415161718192021222324252627282930313233343536
  1. /*
  2. * Raspberry Pi emulation (c) 2012 Gregory Estrade
  3. *
  4. * This work is licensed under the terms of the GNU GPL, version 2 or later.
  5. * See the COPYING file in the top-level directory.
  6. */
  7. #ifndef BCM2835_IC_H
  8. #define BCM2835_IC_H
  9. #include "hw/sysbus.h"
  10. #include "qom/object.h"
  11. #define TYPE_BCM2835_IC "bcm2835-ic"
  12. OBJECT_DECLARE_SIMPLE_TYPE(BCM2835ICState, BCM2835_IC)
  13. #define BCM2835_IC_GPU_IRQ "gpu-irq"
  14. #define BCM2835_IC_ARM_IRQ "arm-irq"
  15. struct BCM2835ICState {
  16. /*< private >*/
  17. SysBusDevice busdev;
  18. /*< public >*/
  19. MemoryRegion iomem;
  20. qemu_irq irq;
  21. qemu_irq fiq;
  22. /* 64 GPU IRQs + 8 ARM IRQs = 72 total (GPU first) */
  23. uint64_t gpu_irq_level, gpu_irq_enable;
  24. uint8_t arm_irq_level, arm_irq_enable;
  25. bool fiq_enable;
  26. uint8_t fiq_select;
  27. };
  28. #endif