Skip to contentSkip to conversation

drivers: irqchip: pdc: setup all edge interrupts as rising edge at GIC

PATCH In review Lina Iyer 3 participants 4 messages Sep 27, 2018 – Sep 28, 2018

Subsystems (2)
lore
Share & tools
lore

Lina Iyer

author
#0 lore raw

PATCH 1/1 drivers: irqchip: pdc: setup all edge interrupts as rising edge at GIC

The PDC irqchp can convert a falling edge or level low interrupt to a rising edge or level high interrupt at the GIC. We just need to setup the GIC correctly. Set up the interrupt type for the IRQ_TYPE_EDGE_BOTH as IRQ_TYPE_EDGE_RISING at the GIC.

---
 drivers/irqchip/qcom-pdc.c | 1 +
 1 file changed, 1 insertion(+)
drivers/irqchip/qcom-pdc.c +1 -0
index b1b47a40a278..faa7d61b9d6c 100644
@@ -124,6 +124,7 @@ static int qcom_pdc_gic_set_type(struct irq_data *d, unsigned int type)
 		break;
 	case IRQ_TYPE_EDGE_BOTH:
 		pdc_type = PDC_EDGE_DUAL;
+		type = IRQ_TYPE_EDGE_RISING;
 		break;
 	case IRQ_TYPE_LEVEL_HIGH:
 		pdc_type = PDC_LEVEL_HIGH;
Signature · 2 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project
Reviewed-by on v1 1/1
#1 lore raw
Quoted 6 lines · Lina Iyer

The PDC irqchp can convert a falling edge or level low interrupt to a rising edge or level high interrupt at the GIC. We just need to setup the GIC correctly. Set up the interrupt type for the IRQ_TYPE_EDGE_BOTH as IRQ_TYPE_EDGE_RISING at the GIC.

Quoted 6 lines
---
 drivers/irqchip/qcom-pdc.c | 1 +
 1 file changed, 1 insertion(+)
#2 lore raw
In reply to Lina Iyer
Quoted 17 lines · Lina Iyer

The PDC irqchp can convert a falling edge or level low interrupt to a rising edge or level high interrupt at the GIC. We just need to setup the GIC correctly. Set up the interrupt type for the IRQ_TYPE_EDGE_BOTH as IRQ_TYPE_EDGE_RISING at the GIC.

---
  drivers/irqchip/qcom-pdc.c | 1 +
  1 file changed, 1 insertion(+)
drivers/irqchip/qcom-pdc.c +0 -0
index b1b47a40a278..faa7d61b9d6c 100644

drivers/irqchip/qcom-pdc.c static int qcom_pdc_gic_set_type(struct irq_data *d, unsigned int type) · line 130

Quoted 7 lines
drivers/irqchip/qcom-pdc.c +1 -0
@@ -124,6 +124,7 @@ static int qcom_pdc_gic_set_type(struct irq_data *d, unsigned int type)
  		break;
  	case IRQ_TYPE_EDGE_BOTH:
  		pdc_type = PDC_EDGE_DUAL;
+		type = IRQ_TYPE_EDGE_RISING;
  		break;
  	case IRQ_TYPE_LEVEL_HIGH:
  		pdc_type = PDC_LEVEL_HIGH;

Queued for 4.20, with

Fixes f55c73aef890 ("irqchip/pdc: Add PDC interrupt controller for QCOM SoCs")

added. Please consider providing these tags in the future.

Thanks,

	M.
Signature · 1 line
Jazz is not dead. It just smells funny...
author
#3 lore raw
Quoted 28 lines · Marc Zyngier
Quoted 17 lines · Lina Iyer

The PDC irqchp can convert a falling edge or level low interrupt to a rising edge or level high interrupt at the GIC. We just need to setup the GIC correctly. Set up the interrupt type for the IRQ_TYPE_EDGE_BOTH as IRQ_TYPE_EDGE_RISING at the GIC.

---
 drivers/irqchip/qcom-pdc.c | 1 +
 1 file changed, 1 insertion(+)
drivers/irqchip/qcom-pdc.c +0 -0
index b1b47a40a278..faa7d61b9d6c 100644

drivers/irqchip/qcom-pdc.c static int qcom_pdc_gic_set_type(struct irq_data *d, unsigned int type) · line 130

Quoted 7 lines
drivers/irqchip/qcom-pdc.c +1 -0
@@ -124,6 +124,7 @@ static int qcom_pdc_gic_set_type(struct irq_data *d, unsigned int type)
 		break;
 	case IRQ_TYPE_EDGE_BOTH:
 		pdc_type = PDC_EDGE_DUAL;
+		type = IRQ_TYPE_EDGE_RISING;
 		break;
 	case IRQ_TYPE_LEVEL_HIGH:
 		pdc_type = PDC_LEVEL_HIGH;

Queued for 4.20, with

Quoted 4 lines
Fixes f55c73aef890 ("irqchip/pdc: Add PDC interrupt controller for

QCOM SoCs")

added. Please consider providing these tags in the future.

Thanks Marc. Will do.

-- Lina