Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

driver: interrupt_controller: nuclei_eclic: fixed interrupt level and CLIC enable #75580

Merged
merged 2 commits into from
Jul 12, 2024

Conversation

jimmyzhe
Copy link
Collaborator

@jimmyzhe jimmyzhe commented Jul 8, 2024

This PR fixes two issues in the Nuclei CLIC driver:

  1. Incorrect CLIC interrupt level configuration:
    The CLIC interrupt level controls preemption between IRQs, while multi-level interrupts in Zephyr are for nested controllers. Removed the incorrect setting of the CLIC interrupt level.

  2. Redundant CLIC mode enable:
    The RISC-V CLIC enable is already handled in vector.S in the RISC-V common code. Removed the redundant CLIC mode enable.

CLIC should be the first level interrupt controller because it replaces
the basic RISC-V local interrupt.
The interrupt level in CLIC controls preemption between IRQs, rather than
specifying the number of nested interrupt controllers.
Removed CONFIG_MULTI_LEVEL_INTERRUPTS and the incorrect interrupt level.

Signed-off-by: Jimmy Zheng <[email protected]>
RISC-V trap entry is handled in soc/common/riscv-privileged/vector.S.
Remove the redundant modification in CLIC driver.

Signed-off-by: Jimmy Zheng <[email protected]>
Copy link
Contributor

@cameled cameled left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Refer ECLIC and PLIC Connection Diagram. Looks currently Nuclei ECLIC not support multi-level (nested) interrupt controller arrangement.

@nashif nashif merged commit 7802fff into zephyrproject-rtos:main Jul 12, 2024
27 checks passed
@jimmyzhe jimmyzhe deleted the fixed_clic_driver branch July 12, 2024 21:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants