Merge branch irq/misc-5.17 into irq/irqchip-next
* irq/misc-5.17: : . : Misc irqchip fixes: : : - Disable GICv4.1 RD's VPE table at boot time to avoid RAS errors : - Fix Ingenic TCU's u32/unsigned long abuse : - Some GICv2m constifying : - Mark imx_gpcv2_instance as __ro_after_init : - Enable a few missing IRQs on Spear : - Conversion to platform_get_irq_optional() for the Renesas irqchips : . irqchip/renesas-intc-irqpin: Use platform_get_irq_optional() to get the interrupt irqchip/renesas-irqc: Use platform_get_irq_optional() to get the interrupt irqchip/gic-v4: Disable redistributors' view of the VPE table at boot time irqchip/ingenic-tcu: Use correctly sized arguments for bit field irqchip/gic-v2m: Add const to of_device_id irqchip/imx-gpcv2: Mark imx_gpcv2_instance with __ro_after_init irqchip/spear-shirq: Add support for IRQ 0..6 Signed-off-by: Marc Zyngier <maz@kernel.org>
This commit is contained in:
commit
cd448b24c6
@ -405,7 +405,7 @@ err_free_v2m:
|
||||
return ret;
|
||||
}
|
||||
|
||||
static struct of_device_id gicv2m_device_id[] = {
|
||||
static const struct of_device_id gicv2m_device_id[] = {
|
||||
{ .compatible = "arm,gic-v2m-frame", },
|
||||
{},
|
||||
};
|
||||
|
@ -920,6 +920,22 @@ static int __gic_update_rdist_properties(struct redist_region *region,
|
||||
{
|
||||
u64 typer = gic_read_typer(ptr + GICR_TYPER);
|
||||
|
||||
/* Boot-time cleanip */
|
||||
if ((typer & GICR_TYPER_VLPIS) && (typer & GICR_TYPER_RVPEID)) {
|
||||
u64 val;
|
||||
|
||||
/* Deactivate any present vPE */
|
||||
val = gicr_read_vpendbaser(ptr + SZ_128K + GICR_VPENDBASER);
|
||||
if (val & GICR_VPENDBASER_Valid)
|
||||
gicr_write_vpendbaser(GICR_VPENDBASER_PendingLast,
|
||||
ptr + SZ_128K + GICR_VPENDBASER);
|
||||
|
||||
/* Mark the VPE table as invalid */
|
||||
val = gicr_read_vpropbaser(ptr + SZ_128K + GICR_VPROPBASER);
|
||||
val &= ~GICR_VPROPBASER_4_1_VALID;
|
||||
gicr_write_vpropbaser(val, ptr + SZ_128K + GICR_VPROPBASER);
|
||||
}
|
||||
|
||||
gic_data.rdists.has_vlpis &= !!(typer & GICR_TYPER_VLPIS);
|
||||
|
||||
/* RVPEID implies some form of DirectLPI, no matter what the doc says... :-/ */
|
||||
|
@ -26,7 +26,7 @@ struct gpcv2_irqchip_data {
|
||||
u32 cpu2wakeup;
|
||||
};
|
||||
|
||||
static struct gpcv2_irqchip_data *imx_gpcv2_instance;
|
||||
static struct gpcv2_irqchip_data *imx_gpcv2_instance __ro_after_init;
|
||||
|
||||
static void __iomem *gpcv2_idx_to_reg(struct gpcv2_irqchip_data *cd, int i)
|
||||
{
|
||||
|
@ -28,6 +28,7 @@ static void ingenic_tcu_intc_cascade(struct irq_desc *desc)
|
||||
struct irq_chip_generic *gc = irq_get_domain_generic_chip(domain, 0);
|
||||
struct regmap *map = gc->private;
|
||||
uint32_t irq_reg, irq_mask;
|
||||
unsigned long bits;
|
||||
unsigned int i;
|
||||
|
||||
regmap_read(map, TCU_REG_TFR, &irq_reg);
|
||||
@ -36,8 +37,9 @@ static void ingenic_tcu_intc_cascade(struct irq_desc *desc)
|
||||
chained_irq_enter(irq_chip, desc);
|
||||
|
||||
irq_reg &= ~irq_mask;
|
||||
bits = irq_reg;
|
||||
|
||||
for_each_set_bit(i, (unsigned long *)&irq_reg, 32)
|
||||
for_each_set_bit(i, &bits, 32)
|
||||
generic_handle_domain_irq(domain, i);
|
||||
|
||||
chained_irq_exit(irq_chip, desc);
|
||||
|
@ -375,7 +375,6 @@ static int intc_irqpin_probe(struct platform_device *pdev)
|
||||
struct intc_irqpin_priv *p;
|
||||
struct intc_irqpin_iomem *i;
|
||||
struct resource *io[INTC_IRQPIN_REG_NR];
|
||||
struct resource *irq;
|
||||
struct irq_chip *irq_chip;
|
||||
void (*enable_fn)(struct irq_data *d);
|
||||
void (*disable_fn)(struct irq_data *d);
|
||||
@ -418,12 +417,14 @@ static int intc_irqpin_probe(struct platform_device *pdev)
|
||||
|
||||
/* allow any number of IRQs between 1 and INTC_IRQPIN_MAX */
|
||||
for (k = 0; k < INTC_IRQPIN_MAX; k++) {
|
||||
irq = platform_get_resource(pdev, IORESOURCE_IRQ, k);
|
||||
if (!irq)
|
||||
ret = platform_get_irq_optional(pdev, k);
|
||||
if (ret == -ENXIO)
|
||||
break;
|
||||
if (ret < 0)
|
||||
goto err0;
|
||||
|
||||
p->irq[k].p = p;
|
||||
p->irq[k].requested_irq = irq->start;
|
||||
p->irq[k].requested_irq = ret;
|
||||
}
|
||||
|
||||
nirqs = k;
|
||||
|
@ -126,7 +126,6 @@ static int irqc_probe(struct platform_device *pdev)
|
||||
struct device *dev = &pdev->dev;
|
||||
const char *name = dev_name(dev);
|
||||
struct irqc_priv *p;
|
||||
struct resource *irq;
|
||||
int ret;
|
||||
int k;
|
||||
|
||||
@ -142,13 +141,15 @@ static int irqc_probe(struct platform_device *pdev)
|
||||
|
||||
/* allow any number of IRQs between 1 and IRQC_IRQ_MAX */
|
||||
for (k = 0; k < IRQC_IRQ_MAX; k++) {
|
||||
irq = platform_get_resource(pdev, IORESOURCE_IRQ, k);
|
||||
if (!irq)
|
||||
ret = platform_get_irq_optional(pdev, k);
|
||||
if (ret == -ENXIO)
|
||||
break;
|
||||
if (ret < 0)
|
||||
goto err_runtime_pm_disable;
|
||||
|
||||
p->irq[k].p = p;
|
||||
p->irq[k].hw_irq = k;
|
||||
p->irq[k].requested_irq = irq->start;
|
||||
p->irq[k].requested_irq = ret;
|
||||
}
|
||||
|
||||
p->number_of_irqs = k;
|
||||
|
@ -149,6 +149,8 @@ static struct spear_shirq spear320_shirq_ras3 = {
|
||||
.offset = 0,
|
||||
.nr_irqs = 7,
|
||||
.mask = ((0x1 << 7) - 1) << 0,
|
||||
.irq_chip = &dummy_irq_chip,
|
||||
.status_reg = SPEAR320_INT_STS_MASK_REG,
|
||||
};
|
||||
|
||||
static struct spear_shirq spear320_shirq_ras1 = {
|
||||
|
Loading…
x
Reference in New Issue
Block a user