diff options
author | Hongbo Li <lihongbo22@huawei.com> | 2024-08-28 14:27:24 +0200 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2024-08-29 16:42:07 +0200 |
commit | 4609c6eab67bb1785a5337ddafb5c74c796bcd35 (patch) | |
tree | 1b9df6aad665e2fc7988b430c87dfaed6743e1f4 /kernel/irq | |
parent | genirq/msi: Use kmemdup_array() instead of kmemdup() (diff) | |
download | linux-4609c6eab67bb1785a5337ddafb5c74c796bcd35.tar.xz linux-4609c6eab67bb1785a5337ddafb5c74c796bcd35.zip |
irqdomain: Use IS_ERR_OR_NULL() in irq_domain_trim_hierarchy()
Use IS_ERR_OR_NULL() instead of open-coding a NULL and a error pointer
check.
Signed-off-by: Hongbo Li <lihongbo22@huawei.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lore.kernel.org/all/20240828122724.3697447-1-lihongbo22@huawei.com
Diffstat (limited to 'kernel/irq')
-rw-r--r-- | kernel/irq/irqdomain.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/irq/irqdomain.c b/kernel/irq/irqdomain.c index 5df8780100bb..e0bff21f30e0 100644 --- a/kernel/irq/irqdomain.c +++ b/kernel/irq/irqdomain.c @@ -1403,7 +1403,7 @@ static int irq_domain_trim_hierarchy(unsigned int virq) tail = NULL; /* The first entry must have a valid irqchip */ - if (!irq_data->chip || IS_ERR(irq_data->chip)) + if (IS_ERR_OR_NULL(irq_data->chip)) return -EINVAL; /* |