void main_init_gic(void) { void *gicc_base; void *gicd_base; gicc_base = phys_to_virt(GIC_BASE + GICC_OFFSET, MEM_AREA_IO_SEC); gicd_base = phys_to_virt(GIC_BASE + GICD_OFFSET, MEM_AREA_IO_SEC); if (!gicc_base || !gicd_base) panic(); gic_init(&gic_data, (vaddr_t)gicc_base, (vaddr_t)gicd_base); itr_init(&gic_data.chip); }
void main_init_gic(void) { #if PLATFORM_FLAVOR_IS(fvp) || PLATFORM_FLAVOR_IS(juno) || \ PLATFORM_FLAVOR_IS(qemu_armv8a) /* On ARMv8, GIC configuration is initialized in ARM-TF */ gic_init_base_addr(&gic_data, GIC_BASE + GICC_OFFSET, GIC_BASE + GICD_OFFSET); #else /* Initialize GIC */ gic_init(&gic_data, GIC_BASE + GICC_OFFSET, GIC_BASE + GICD_OFFSET); #endif itr_init(&gic_data.chip); }
void main_init_gic(void) { vaddr_t gicc_base; vaddr_t gicd_base; gicc_base = (vaddr_t)phys_to_virt(GICC_BASE, MEM_AREA_IO_SEC); gicd_base = (vaddr_t)phys_to_virt(GICD_BASE, MEM_AREA_IO_SEC); if (!gicc_base || !gicd_base) panic(); gic_init(&gic_data, gicc_base, gicd_base); itr_init(&gic_data.chip); }