aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/bcm63xx/patches-5.4
diff options
context:
space:
mode:
authorÁlvaro Fernández Rojas <noltari@gmail.com>2020-05-14 16:14:52 +0200
committerÁlvaro Fernández Rojas <noltari@gmail.com>2020-05-14 16:28:31 +0200
commit29c3bb5f413f0962971c66e6516b8409a78e0135 (patch)
tree3ce1368a594d02ea07e8cfd783d267aefa067f9a /target/linux/bcm63xx/patches-5.4
parentf2f2cf07a61e9c170ab8d65e1e054f0131a84e2a (diff)
downloadupstream-29c3bb5f413f0962971c66e6516b8409a78e0135.tar.gz
upstream-29c3bb5f413f0962971c66e6516b8409a78e0135.tar.bz2
upstream-29c3bb5f413f0962971c66e6516b8409a78e0135.zip
bcm63xx: ext_intc: fix warning
In file included from ./arch/mips/include/asm/io.h:34, from ./arch/mips/include/asm/mmiowb.h:5, from ./include/linux/spinlock.h:60, from ./include/linux/irq.h:14, from drivers/irqchip/irq-bcm6345-ext.c:10: drivers/irqchip/irq-bcm6345-ext.c: In function 'bcm6345_ext_intc_of_init': ./arch/mips/include/asm/mach-bcm63xx/ioremap.h:48:9: warning: 'base' may be used uninitialized in this function [-Wmaybe-uninitialized] return is_bcm63xx_internal_registers((unsigned long)addr); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/irqchip/irq-bcm6345-ext.c:255:16: note: 'base' was declared here void __iomem *base; ^~~~ Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
Diffstat (limited to 'target/linux/bcm63xx/patches-5.4')
-rw-r--r--target/linux/bcm63xx/patches-5.4/325-irqchip-bcm6345-external-fix-base-uninitialized.patch28
1 files changed, 28 insertions, 0 deletions
diff --git a/target/linux/bcm63xx/patches-5.4/325-irqchip-bcm6345-external-fix-base-uninitialized.patch b/target/linux/bcm63xx/patches-5.4/325-irqchip-bcm6345-external-fix-base-uninitialized.patch
new file mode 100644
index 0000000000..45b5118a4a
--- /dev/null
+++ b/target/linux/bcm63xx/patches-5.4/325-irqchip-bcm6345-external-fix-base-uninitialized.patch
@@ -0,0 +1,28 @@
+--- a/drivers/irqchip/irq-bcm6345-ext.c
++++ b/drivers/irqchip/irq-bcm6345-ext.c
+@@ -271,21 +271,19 @@ static int __init bcm6345_ext_intc_of_in
+
+ for (i = 0; i < num_irqs; i++) {
+ irqs[i] = irq_of_parse_and_map(node, i);
+- if (!irqs[i]) {
+- ret = -ENOMEM;
+- goto out_unmap;
+- }
++ if (!irqs[i])
++ return -ENOMEM;
+ }
+
+ base = of_iomap(node, 0);
+ if (!base)
+- goto out_unmap;
++ return -ENXIO;
+
+ ret = __bcm6345_ext_intc_init(node, num_irqs, irqs, base, shift,
+ toggle_clear_on_ack);
+ if (!ret)
+ return 0;
+-out_unmap:
++
+ iounmap(base);
+
+ for (i = 0; i < num_irqs; i++)