[tip: irq/drivers] irqchip/al-fic: Fix coding style issues

From: tip-bot2 for Eliav Farber

Date: Thu Oct 15 2026 - 08:41:57 EST


The following commit has been merged into the irq/drivers branch of tip:

Commit-ID: ad38b8836a828042262532c8f77659820be01d3d
Gitweb: https://git.kernel.org/tip/ad38b8836a828042262532c8f77659820be01d3d
Author: Eliav Farber <farbere@xxxxxxxxxx>
AuthorDate: Sun, 11 Oct 2026 05:04:40
Committer: Thomas Gleixner <tglx@xxxxxxxxxx>
CommitterDate: Thu, 15 Oct 2026 14:25:06 +02:00

irqchip/al-fic: Fix coding style issues

Remove pointless line breaks and align continuations and struct
declarations properly.

No functional change.

[ tglx: Do a full sweep of the code instead of fixing a single instance ]

Signed-off-by: Eliav Farber <farbere@xxxxxxxxxx>
Signed-off-by: Thomas Gleixner <tglx@xxxxxxxxxx>
Reviewed-by: Radu Rendec <radu@xxxxxxxxxx>
Link: https://patch.msgid.link/20261011050449.41903-2-farbere@xxxxxxxxxx
---
drivers/irqchip/irq-al-fic.c | 66 ++++++++++++-----------------------
1 file changed, 24 insertions(+), 42 deletions(-)

diff --git a/drivers/irqchip/irq-al-fic.c b/drivers/irqchip/irq-al-fic.c
index 760317d..adcdc05 100644
--- a/drivers/irqchip/irq-al-fic.c
+++ b/drivers/irqchip/irq-al-fic.c
@@ -34,19 +34,18 @@ enum al_fic_state {
};

struct al_fic {
- void __iomem *base;
- struct irq_domain *domain;
- const char *name;
- unsigned int parent_irq;
- enum al_fic_state state;
+ void __iomem *base;
+ struct irq_domain *domain;
+ const char *name;
+ unsigned int parent_irq;
+ enum al_fic_state state;
};

-static void al_fic_set_trigger(struct al_fic *fic,
- struct irq_chip_generic *gc,
+static void al_fic_set_trigger(struct al_fic *fic, struct irq_chip_generic *gc,
enum al_fic_state new_state)
{
- irq_flow_handler_t handler;
u32 control = readl_relaxed(fic->base + AL_FIC_CONTROL);
+ irq_flow_handler_t handler;

if (new_state == AL_FIC_CONFIGURED_LEVEL) {
handler = handle_level_irq;
@@ -98,8 +97,8 @@ static int al_fic_irq_set_type(struct irq_data *data, unsigned int flow_type)
static void al_fic_irq_handler(struct irq_desc *desc)
{
struct al_fic *fic = irq_desc_get_handler_data(desc);
- struct irq_domain *domain = fic->domain;
struct irq_chip *irqchip = irq_desc_get_chip(desc);
+ struct irq_domain *domain = fic->domain;
struct irq_chip_generic *gc = irq_get_domain_generic_chip(domain, 0);
unsigned long pending;
u32 hwirq;
@@ -125,25 +124,20 @@ static int al_fic_irq_retrigger(struct irq_data *data)
return 1;
}

-static int al_fic_register(struct device_node *node,
- struct al_fic *fic)
+static int al_fic_register(struct device_node *node, struct al_fic *fic)
{
struct irq_chip_generic *gc;
int ret;

- fic->domain = irq_domain_create_linear(of_fwnode_handle(node),
- NR_FIC_IRQS,
- &irq_generic_chip_ops,
- fic);
+ fic->domain = irq_domain_create_linear(of_fwnode_handle(node), NR_FIC_IRQS,
+ &irq_generic_chip_ops, fic);
if (!fic->domain) {
pr_err("fail to add irq domain\n");
return -ENOMEM;
}

- ret = irq_alloc_domain_generic_chips(fic->domain,
- NR_FIC_IRQS,
- 1, fic->name,
- handle_level_irq,
+ ret = irq_alloc_domain_generic_chips(fic->domain, NR_FIC_IRQS,
+ 1, fic->name, handle_level_irq,
0, 0, IRQ_GC_INIT_MASK_CACHE);
if (ret) {
pr_err("fail to allocate generic chip (%d)\n", ret);
@@ -162,14 +156,11 @@ static int al_fic_register(struct device_node *node,
gc->chip_types->chip.flags = IRQCHIP_SKIP_SET_WAKE;
gc->private = fic;

- irq_set_chained_handler_and_data(fic->parent_irq,
- al_fic_irq_handler,
- fic);
+ irq_set_chained_handler_and_data(fic->parent_irq, al_fic_irq_handler, fic);
return 0;

err_domain_remove:
irq_domain_remove(fic->domain);
-
return ret;
}

@@ -185,14 +176,12 @@ err_domain_remove:
* Interrupt can be generated based on positive edge or level - configuration is
* to be determined based on connected hardware to this fic.
*/
-static struct al_fic *al_fic_wire_init(struct device_node *node,
- void __iomem *base,
- const char *name,
- unsigned int parent_irq)
+static struct al_fic *al_fic_wire_init(struct device_node *node, void __iomem *base,
+ const char *name, unsigned int parent_irq)
{
+ u32 control = CONTROL_MASK_MSI_X;
struct al_fic *fic;
int ret;
- u32 control = CONTROL_MASK_MSI_X;

fic = kzalloc_obj(*fic);
if (!fic)
@@ -226,17 +215,15 @@ err_free:
return ERR_PTR(ret);
}

-static int __init al_fic_init_dt(struct device_node *node,
- struct device_node *parent)
+static int __init al_fic_init_dt(struct device_node *node, struct device_node *parent)
{
- int ret;
- void __iomem *base;
unsigned int parent_irq;
struct al_fic *fic;
+ void __iomem *base;
+ int ret;

if (!parent) {
- pr_err("%s: unsupported - device require a parent\n",
- node->name);
+ pr_err("%s: unsupported - device require a parent\n", node->name);
return -EINVAL;
}

@@ -253,14 +240,10 @@ static int __init al_fic_init_dt(struct device_node *node,
goto err_unmap;
}

- fic = al_fic_wire_init(node,
- base,
- node->name,
- parent_irq);
+ fic = al_fic_wire_init(node, base, node->name, parent_irq);
+
if (IS_ERR(fic)) {
- pr_err("%s: fail to initialize irqchip (%lu)\n",
- node->name,
- PTR_ERR(fic));
+ pr_err("%s: fail to initialize irqchip (%lu)\n", node->name, PTR_ERR(fic));
ret = PTR_ERR(fic);
goto err_irq_dispose;
}
@@ -271,7 +254,6 @@ err_irq_dispose:
irq_dispose_mapping(parent_irq);
err_unmap:
iounmap(base);
-
return ret;
}