Home Home > GIT Browse
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMian Yousaf Kaukab <ykaukab@suse.de>2018-08-22 17:23:33 +0200
committerMian Yousaf Kaukab <ykaukab@suse.de>2018-08-22 17:23:33 +0200
commit3307a951b6a210e1fc5a3f02a885186aea89a8ab (patch)
tree51713a89f5c25f733f0ced4984e73fb3cc22e516
parent6f5456baf2b2303543085e80c2522547efe7c1fc (diff)
irqdomain: Prevent potential NULL pointer dereference in
irq_domain_push_irq() (bsc#1105378). suse-commit: 7f467182ddf5d6ab2efcac40f9c33ed065608a4c
-rw-r--r--kernel/irq/irqdomain.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/irq/irqdomain.c b/kernel/irq/irqdomain.c
index 1090f970884b..8c519ff14915 100644
--- a/kernel/irq/irqdomain.c
+++ b/kernel/irq/irqdomain.c
@@ -1368,10 +1368,10 @@ int irq_domain_push_irq(struct irq_domain *domain, int virq, void *arg)
if (WARN_ON(!irq_domain_is_hierarchy(domain)))
return -EINVAL;
- if (domain->parent != root_irq_data->domain)
+ if (!root_irq_data)
return -EINVAL;
- if (!root_irq_data)
+ if (domain->parent != root_irq_data->domain)
return -EINVAL;
child_irq_data = kzalloc_node(sizeof(*child_irq_data), GFP_KERNEL,