arch/armv8-r: new config to set SPIs Configuration to edge-triggered
Configure all SPIs(Shared Peripheral Interrupts) as edge-triggered by default Signed-off-by: chao an <anchao@lixiang.com>
This commit is contained in:
parent
091372069c
commit
95a9facf3a
@ -13,7 +13,7 @@ config ARMV8R_HAVE_GICv3
|
|||||||
Selected by the configuration tool if the architecture supports the
|
Selected by the configuration tool if the architecture supports the
|
||||||
Generic Interrupt Controller (GIC)
|
Generic Interrupt Controller (GIC)
|
||||||
|
|
||||||
if ARMV8R_HAVE_GICv2
|
if ARMV8R_HAVE_GICv3
|
||||||
|
|
||||||
config ARMV8R_GIC_EOIMODE
|
config ARMV8R_GIC_EOIMODE
|
||||||
bool
|
bool
|
||||||
@ -22,7 +22,13 @@ config ARMV8R_GIC_EOIMODE
|
|||||||
Enable GICC_CTLR.EOImode, this will separates the priority drop and interrupt
|
Enable GICC_CTLR.EOImode, this will separates the priority drop and interrupt
|
||||||
deactivation operations.
|
deactivation operations.
|
||||||
|
|
||||||
endif # ARMV8R_GIC_EOIMODE
|
config ARMV8R_GIC_SPI_EDGE
|
||||||
|
bool "Configure all SPIs(Shared Peripheral Interrupts) as edge-triggered by default"
|
||||||
|
default n
|
||||||
|
---help---
|
||||||
|
Configure all SPIs(Shared Peripheral Interrupts) as edge-triggered by default.
|
||||||
|
|
||||||
|
endif # ARMV8R_HAVE_GICv3
|
||||||
|
|
||||||
config ARMV8R_MEMINIT
|
config ARMV8R_MEMINIT
|
||||||
bool
|
bool
|
||||||
|
@ -528,7 +528,15 @@ static void gicv3_dist_init(void)
|
|||||||
intid += GIC_NUM_CFG_PER_REG)
|
intid += GIC_NUM_CFG_PER_REG)
|
||||||
{
|
{
|
||||||
idx = intid / GIC_NUM_CFG_PER_REG;
|
idx = intid / GIC_NUM_CFG_PER_REG;
|
||||||
|
#ifdef CONFIG_ARMV8R_GIC_SPI_EDGE
|
||||||
|
/* Configure all SPIs as edge-triggered by default */
|
||||||
|
|
||||||
|
putreg32(0xaaaaaaaa, ICFGR(base, idx));
|
||||||
|
#else
|
||||||
|
/* Configure all SPIs as level-sensitive by default */
|
||||||
|
|
||||||
putreg32(0, ICFGR(base, idx));
|
putreg32(0, ICFGR(base, idx));
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/* TODO: Some arrch64 Cortex-A core maybe without security state
|
/* TODO: Some arrch64 Cortex-A core maybe without security state
|
||||||
|
Loading…
x
Reference in New Issue
Block a user