forked from zephyrproject-rtos/zephyr
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
drivers: intc: gic: implement set pending interrupt
Implement a function to set pending interrupts for Arm GIC. Signed-off-by: Manuel Argüelles <[email protected]>
- Loading branch information
1 parent
42c8732
commit 2786cb9
Showing
3 changed files
with
27 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,7 @@ | |
* Copyright (c) 2018 Marvell | ||
* Copyright (c) 2018 Lexmark International, Inc. | ||
* Copyright (c) 2019 Stephanos Ioannidis <[email protected]> | ||
* Copyright 2024 NXP | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
@@ -79,6 +80,16 @@ bool arm_gic_irq_is_pending(unsigned int irq) | |
return (enabler & (1 << int_off)) != 0; | ||
} | ||
|
||
void arm_gic_irq_set_pending(unsigned int irq) | ||
{ | ||
int int_grp, int_off; | ||
|
||
int_grp = irq / 32; | ||
int_off = irq % 32; | ||
|
||
sys_write32((1 << int_off), (GICD_ISPENDRn + int_grp * 4)); | ||
} | ||
|
||
void arm_gic_irq_clear_pending(unsigned int irq) | ||
{ | ||
int int_grp, int_off; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters