diff options
author | Antonio Borneo | 2022-05-12 18:05:44 +0200 |
---|---|---|
committer | Marc Zyngier | 2022-07-07 09:04:13 +0100 |
commit | 95001b756467ecc9f5973eb5e74e97699d9bbdf1 (patch) | |
tree | b221ff1c9839db11b588d49a35a9e29e1559af11 /kernel/irq | |
parent | a111daf0c53ae91e71fd2bfe7497862d14132e3e (diff) |
genirq: Don't return error on missing optional irq_request_resources()
Function irq_chip::irq_request_resources() is reported as optional
in the declaration of struct irq_chip.
If the parent irq_chip does not implement it, we should ignore it
and return.
Don't return error if the functions is missing.
Signed-off-by: Antonio Borneo <antonio.borneo@foss.st.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20220512160544.13561-1-antonio.borneo@foss.st.com
Diffstat (limited to 'kernel/irq')
-rw-r--r-- | kernel/irq/chip.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/irq/chip.c b/kernel/irq/chip.c index 886789dcee43..c19040530789 100644 --- a/kernel/irq/chip.c +++ b/kernel/irq/chip.c @@ -1516,7 +1516,8 @@ int irq_chip_request_resources_parent(struct irq_data *data) if (data->chip->irq_request_resources) return data->chip->irq_request_resources(data); - return -ENOSYS; + /* no error on missing optional irq_chip::irq_request_resources */ + return 0; } EXPORT_SYMBOL_GPL(irq_chip_request_resources_parent); |