]> Git Repo - linux.git/commitdiff
irqchip/irq-alpine-msi: Release the correct domain on error
authorDan Carpenter <[email protected]>
Fri, 11 Mar 2016 08:14:43 +0000 (11:14 +0300)
committerThomas Gleixner <[email protected]>
Fri, 11 Mar 2016 09:06:55 +0000 (10:06 +0100)
The "msi_domain" variable is NULL here so it leads to a NULL dereference.  It
looks like we actually intended to free "middle_domain".

Fixes: e6b78f2c3e14 ('irqchip: Add the Alpine MSIX interrupt controller')
Signed-off-by: Dan Carpenter <[email protected]>
Cc: Jason Cooper <[email protected]>
Cc: Marc Zyngier <[email protected]>
Cc: Antoine Tenart <[email protected]>
Cc: [email protected]
Cc: Tsahee Zidenberg <[email protected]>
Link: http://lkml.kernel.org/r/20160311081442.GE31887@mwanda
Signed-off-by: Thomas Gleixner <[email protected]>
drivers/irqchip/irq-alpine-msi.c

index f8712722a606289dd2420d9abd71ff6c36e687ff..25384255b30f5017eb3e2287a942aebede72c37e 100644 (file)
@@ -220,7 +220,7 @@ static int alpine_msix_init_domains(struct alpine_msix_data *priv,
                                               middle_domain);
        if (!msi_domain) {
                pr_err("Failed to create MSI domain\n");
-               irq_domain_remove(msi_domain);
+               irq_domain_remove(middle_domain);
                return -ENOMEM;
        }
 
This page took 0.061096 seconds and 4 git commands to generate.