Skip to contentSkip to conversation

drivers/irqchip: remove redundant ret variable

PATCH New [email protected] 1 participant 1 message Dec 15, 2021

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drivers/irqchip: remove redundant ret variable

From: Minghao Chi <[email protected]>

Return value directly instead of taking this
in another redundant variable.

---
 drivers/irqchip/irq-mtk-cirq.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)
drivers/irqchip/irq-mtk-cirq.c +1 -4
index 9bca0918078e..2f895473d9d3 100644
@@ -60,8 +60,6 @@ static void mtk_cirq_unmask(struct irq_data *data)
 
 static int mtk_cirq_set_type(struct irq_data *data, unsigned int type)
 {
-	int ret;
-
 	switch (type & IRQ_TYPE_SENSE_MASK) {
 	case IRQ_TYPE_EDGE_FALLING:
 		mtk_cirq_write_mask(data, CIRQ_POL_CLR);
@@ -84,8 +82,7 @@ static int mtk_cirq_set_type(struct irq_data *data, unsigned int type)
 	}
 
 	data = data->parent_data;
-	ret = data->chip->irq_set_type(data, type);
-	return ret;
+	return data->chip->irq_set_type(data, type);
 }
 
 static struct irq_chip mtk_cirq_chip = {
Signature · 1 line
2.25.1