]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
irqchip/renesas-rzv2h: Kill swint_names[]
authorGeert Uytterhoeven <geert+renesas@glider.be>
Fri, 3 Apr 2026 08:48:22 +0000 (10:48 +0200)
committerThomas Gleixner <tglx@kernel.org>
Tue, 7 Apr 2026 09:19:01 +0000 (11:19 +0200)
The array swint_names[] just contains expansions of "int-ca55-%u".
Replace it by formatting the strings where needed, to improve
readability.

Despite the two error messages can no longer be shared with the ICU
error cases, this reduces generated code size by 56 bytes.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Thomas Gleixner <tglx@kernel.org>
Reviewed-by: Biju Das <biju.das.jz@bp.renesas.com>
Link: https://patch.msgid.link/aceab3fbc307ef428dfd62d8d846b68704dea012.1775205874.git.geert+renesas@glider.be
drivers/irqchip/irq-renesas-rzv2h.c

index 9461f19fc38c8bcea12ff3327fa10935dd48284b..c701e468261eb6a6a7521655fe6d6f77e70f0328 100644 (file)
@@ -755,10 +755,6 @@ static int rzv2h_icu_setup_irqs(struct platform_device *pdev, struct irq_domain
 {
        const struct rzv2h_hw_info *hw_info = rzv2h_icu_data->info;
        bool irq_inject = IS_ENABLED(CONFIG_GENERIC_IRQ_INJECTION);
-       static const char * const rzv2h_swint_names[] = {
-               "int-ca55-0", "int-ca55-1",
-               "int-ca55-2", "int-ca55-3",
-       };
        static const char *icu_err = "icu-error-ca55";
        void __iomem *base = rzv2h_icu_data->base;
        struct device *dev = &pdev->dev;
@@ -774,16 +770,14 @@ static int rzv2h_icu_setup_irqs(struct platform_device *pdev, struct irq_domain
 
                virq = irq_create_fwspec_mapping(&fwspec);
                if (!virq) {
-                       return dev_err_probe(dev, -EINVAL, "failed to create IRQ mapping for %s\n",
-                                            rzv2h_swint_names[i]);
+                       return dev_err_probe(dev, -EINVAL,
+                                            "failed to create int-ca55-%u IRQ mapping\n", i);
                }
 
                ret = devm_request_irq(dev, virq, rzv2h_icu_swint_irq, 0, dev_name(dev),
                                       (void *)(uintptr_t)i);
-               if (ret) {
-                       return dev_err_probe(dev, ret, "Failed to request %s IRQ\n",
-                                            rzv2h_swint_names[i]);
-               }
+               if (ret)
+                       return dev_err_probe(dev, ret, "Failed to request int-ca55-%u IRQ\n", i);
        }
 
        /* Unmask and clear all IP/CA55 error interrupts */