irqchip/gic: Remove the unnecessary sync_access argument
Subsystems (2)
PATCH 1/1 irqchip/gic: Remove the unnecessary sync_access argument
Commit 63f13483f068 ("irqchip/gic-v3: Relax polling of GIC{R,D}_CTLR.RWP") has removed some instances of RWP polling where it's not required and left the sync_access argument of gic_configure_irq() and gic_dist_config() no longer needed.
Remove the now unnecessary argument.
Signed-off-by Zenghui Yu <[email protected]>
---
This is just a cleanup discovered by code inspection and can wait for the 6.7 window.
drivers/irqchip/irq-gic-common.c | 12 ++---------- drivers/irqchip/irq-gic-common.h | 6 ++---- drivers/irqchip/irq-gic-v3.c | 4 ++-- drivers/irqchip/irq-gic.c | 4 ++-- drivers/irqchip/irq-hip04.c | 4 ++-- 5 files changed, 10 insertions(+), 20 deletions(-)
drivers/irqchip/irq-gic-common.c +2 -10
@@ -44,8 +44,7 @@ void gic_enable_quirks(u32 iidr, const struct gic_quirk *quirks, } } -int gic_configure_irq (unsigned int irq,unsigned int type, -void __iomem *base,void (*sync_access)(void )) +int gic_configure_irq (unsigned int irq,unsigned int type,void __iomem *base) {u32 confmask =0x2 << ((irq %16 ) *2 );u32 confoff = (irq /16 ) *4 ;
@@ -84,14 +83,10 @@ int gic_configure_irq(unsigned int irq, unsigned int type,raw_spin_unlock_irqrestore (&irq_controller_lock, flags); -if (sync_access) -sync_access (); -return ret; } -void gic_dist_config (void __iomem *base,int gic_irqs, -void (*sync_access)(void )) +void gic_dist_config (void __iomem *base,int gic_irqs) {unsigned int i;
@@ -118,9 +113,6 @@ void gic_dist_config(void __iomem *base, int gic_irqs,writel_relaxed (GICD_INT_EN_CLR_X32 , base +GIC_DIST_ENABLE_CLEAR + i /8 ); } - -if (sync_access) -sync_access (); }void gic_cpu_config (void __iomem *base,int nr,void (*sync_access)(void ))
drivers/irqchip/irq-gic-common.h +2 -4
@@ -19,10 +19,8 @@ struct gic_quirk {u32 mask; }; -int gic_configure_irq (unsigned int irq,unsigned int type, -void __iomem *base,void (*sync_access)(void )); -void gic_dist_config (void __iomem *base,int gic_irqs, -void (*sync_access)(void )); +int gic_configure_irq (unsigned int irq,unsigned int type,void __iomem *base); +void gic_dist_config (void __iomem *base,int gic_irqs);void gic_cpu_config (void __iomem *base,int nr,void (*sync_access)(void ));void gic_enable_quirks (u32 iidr,const struct gic_quirk *quirks,void *data);
drivers/irqchip/irq-gic-v3.c +2 -2
@@ -670,7 +670,7 @@ static int gic_set_type(struct irq_data *d, unsigned int type) offset =convert_offset_index (d,GICD_ICFGR , &index); - ret =gic_configure_irq (index, type, base + offset,NULL ); + ret =gic_configure_irq (index, type, base + offset);if (ret && (range ==PPI_RANGE || range ==EPPI_RANGE )) {/* Misconfigured PPIs are usually not fatal */ pr_warn ("GIC: PPI INTID%d is secure or misconfigured\n" , irq);
@@ -940,7 +940,7 @@ static void __init gic_dist_init(void)writel_relaxed (GICD_INT_DEF_PRI_X4 , base + GICD_IPRIORITYRnE + i);/* Now do the common stuff */ -gic_dist_config (base,GIC_LINE_NR ,NULL ); +gic_dist_config (base,GIC_LINE_NR ); val =GICD_CTLR_ARE_NS |GICD_CTLR_ENABLE_G1A |GICD_CTLR_ENABLE_G1 ;if (gic_data.rdists.gicd_typer2 & GICD_TYPER2_nASSGIcap) {
drivers/irqchip/irq-gic.c +2 -2
@@ -306,7 +306,7 @@ static int gic_set_type(struct irq_data *d, unsigned int type) type != IRQ_TYPE_EDGE_RISING)return -EINVAL ; - ret =gic_configure_irq (gicirq, type, base +GIC_DIST_CONFIG ,NULL ); + ret =gic_configure_irq (gicirq, type, base +GIC_DIST_CONFIG );if (ret && gicirq <32 ) {/* Misconfigured PPIs are usually not fatal */ pr_warn ("GIC: PPI%d is secure or misconfigured\n" , gicirq -16 );
@@ -482,7 +482,7 @@ static void gic_dist_init(struct gic_chip_data *gic)for (i =32 ; i < gic_irqs; i +=4 )writel_relaxed (cpumask, base +GIC_DIST_TARGET + i *4 /4 ); -gic_dist_config (base, gic_irqs,NULL ); +gic_dist_config (base, gic_irqs);writel_relaxed (GICD_ENABLE , base +GIC_DIST_CTRL ); }
drivers/irqchip/irq-hip04.c +2 -2
@@ -130,7 +130,7 @@ static int hip04_irq_set_type(struct irq_data *d, unsigned int type)raw_spin_lock (&irq_controller_lock); - ret =gic_configure_irq (irq, type, base +GIC_DIST_CONFIG ,NULL ); + ret =gic_configure_irq (irq, type, base +GIC_DIST_CONFIG );if (ret && irq <32 ) {/* Misconfigured PPIs are usually not fatal */ pr_warn ("GIC: PPI%d is secure or misconfigured\n" , irq -16 );
@@ -260,7 +260,7 @@ static void __init hip04_irq_dist_init(struct hip04_irq_data *intc)for (i =32 ; i < nr_irqs; i +=2 )writel_relaxed (cpumask, base +GIC_DIST_TARGET + ((i *2 ) & ~3 )); -gic_dist_config (base, nr_irqs,NULL ); +gic_dist_config (base, nr_irqs);writel_relaxed (1 , base +GIC_DIST_CTRL ); }
Signature · 1 line
2.33.0