zephyr/drivers/interrupt_controller/Kconfig.plic
Yong Cong Sin e9fa6f8b4a drivers: intc: plic: add shell cmd to get irq stats for debugging
Introduced `CONFIG_PLIC_SHELL` to enable the build of shell
debugging command to get the hit count of each interrupt
controller's IRQ line. This is especially useful when working
with dynamically installed ISRs, which will be the case for
`plic_sw`.

Example usage:

```
uart:~$ plic stats get interrupt-controller@c000000
   IRQ        Hits
==================
    10         177

uart:~$ plic stats get interrupt-controller@c000000
   IRQ        Hits
==================
    10         236

uart:~$ plic stats clear interrupt-controller@c000000
Cleared stats of interrupt-controller@c000000.

uart:~$ plic stats get interrupt-controller@c000000
   IRQ        Hits
==================
    10          90

```

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Maxim Adelman <imax@meta.com>
2023-11-24 09:23:33 +01:00

24 lines
627 B
Plaintext

# Copyright (c) 2022 Carlo Caione <ccaione@baylibre.com>
# SPDX-License-Identifier: Apache-2.0
config PLIC
bool "Platform Level Interrupt Controller (PLIC)"
default y
depends on DT_HAS_SIFIVE_PLIC_1_0_0_ENABLED
select MULTI_LEVEL_INTERRUPTS
select 2ND_LEVEL_INTERRUPTS
help
Platform Level Interrupt Controller provides support
for external interrupt lines defined by the RISC-V SoC.
if PLIC
config PLIC_SHELL
bool "PLIC shell commands"
depends on SHELL
help
Enable additional shell commands useful for debugging.
Caution: This can use quite a bit of RAM (PLICs * IRQs * sizeof(uint16_t)).
endif # PLIC