diff options
| author | Anup Patel <[email protected]> | 2026-02-13 11:23:41 +0530 |
|---|---|---|
| committer | Anup Patel <[email protected]> | 2026-03-22 10:55:08 +0530 |
| commit | e8ebd1fbc615774f0452e74c850a3dbe00b5c80d (patch) | |
| tree | effa65550444586c0efa9ece94b3bb069b567e91 /include | |
| parent | e82d20122dcf97a357053636c1fc6d268bd4db5c (diff) | |
lib: sbi_irqchip: Associate 32-bit unique ID for each irqchip device
Allow locating irqchip device instance using a unique 32-bit ID. This
32-bit unique ID can be set by the irqchip driver at the time of adding
irqchip device.
Signed-off-by: Anup Patel <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Anup Patel <[email protected]>
Diffstat (limited to 'include')
| -rw-r--r-- | include/sbi/sbi_irqchip.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/sbi/sbi_irqchip.h b/include/sbi/sbi_irqchip.h index c3ded271..d2c47ae8 100644 --- a/include/sbi/sbi_irqchip.h +++ b/include/sbi/sbi_irqchip.h @@ -21,6 +21,9 @@ struct sbi_irqchip_device { /** Node in the list of irqchip devices */ struct sbi_dlist node; + /** Unique ID of this irqchip */ + u32 id; + /** Set of harts targetted by this irqchip */ struct sbi_hartmask target_harts; @@ -41,6 +44,9 @@ struct sbi_irqchip_device { */ int sbi_irqchip_process(void); +/** Find an irqchip device based on unique ID */ +struct sbi_irqchip_device *sbi_irqchip_find_device(u32 id); + /** Register an irqchip device to receive callbacks */ int sbi_irqchip_add_device(struct sbi_irqchip_device *chip); |
