From efc9cb2f76c4921b979c31cfaebc915aefa526be Mon Sep 17 00:00:00 2001 From: Ram Chandrasekar Date: Wed, 15 Jul 2020 11:15:29 -0700 Subject: [PATCH] drivers: thermal: pe_sensor: Clear the victim IRQ status Clear the victim interrupt status when the master interrupt is triggered. Clearing the victim interrupt status along with the other interrupt status will ensure that the master interrupt status is cleared. Change-Id: I20fe3af5481156cf77d951001ce6eceb96b8e3aa Signed-off-by: Ram Chandrasekar --- drivers/thermal/qcom/policy_engine.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/thermal/qcom/policy_engine.c b/drivers/thermal/qcom/policy_engine.c index f8ea6c9f0d2c..39c0fd1f9fb6 100644 --- a/drivers/thermal/qcom/policy_engine.c +++ b/drivers/thermal/qcom/policy_engine.c @@ -93,7 +93,7 @@ static irqreturn_t pe_handle_irq(int irq, void *data) } else mutex_unlock(&pe_sens->mutex); writel_relaxed(PE_INTR_CLEAR, pe_sens->regmap + PE_INT_STATUS_OFFSET); - writel_relaxed(PE_STS_CLEAR, pe_sens->regmap + PE_INT_STATUS_OFFSET); + writel_relaxed(PE_STS_CLEAR, pe_sens->regmap + PE_INT_STATUS1_OFFSET); return IRQ_HANDLED; } @@ -144,7 +144,7 @@ static int pe_sens_device_probe(struct platform_device *pdev) } writel_relaxed(PE_INTR_CFG, pe_sens->regmap + PE_INT_ENABLE_OFFSET); writel_relaxed(PE_INTR_CLEAR, pe_sens->regmap + PE_INT_STATUS_OFFSET); - writel_relaxed(PE_STS_CLEAR, pe_sens->regmap + PE_INT_STATUS_OFFSET); + writel_relaxed(PE_STS_CLEAR, pe_sens->regmap + PE_INT_STATUS1_OFFSET); ret = devm_request_threaded_irq(dev, pe_sens->irq_num, NULL, pe_handle_irq, IRQF_TRIGGER_HIGH | IRQF_ONESHOT,