Skip to content

Commit

Permalink
drm/msm/dpu: don't clear IRQ register twice
Browse files Browse the repository at this point in the history
We already clear the IRQ status register before processing IRQs, so do
not clear the register again. Especially do not clear the IRQ status
_after_ processing the IRQ as this way we can loose the event.

Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Reviewed-by: Abhinav Kumar <abhinavk@codeaurora.org>
Link: https://lore.kernel.org/r/20210617222029.463045-3-dmitry.baryshkov@linaro.org
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Signed-off-by: Rob Clark <robdclark@chromium.org>
  • Loading branch information
Dmitry Baryshkov authored and Rob Clark committed Oct 15, 2021
1 parent a730336 commit 6087623
Showing 1 changed file with 0 additions and 17 deletions.
17 changes: 0 additions & 17 deletions drivers/gpu/drm/msm/disp/dpu1/dpu_hw_interrupts.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,21 +120,6 @@ static const struct dpu_intr_reg dpu_intr_set[] = {
#define DPU_IRQ_REG(irq_idx) (irq_idx / 32)
#define DPU_IRQ_MASK(irq_idx) (BIT(irq_idx % 32))

static void dpu_hw_intr_clear_intr_status_nolock(struct dpu_hw_intr *intr,
int irq_idx)
{
int reg_idx;

if (!intr)
return;

reg_idx = DPU_IRQ_REG(irq_idx);
DPU_REG_WRITE(&intr->hw, dpu_intr_set[reg_idx].clr_off, DPU_IRQ_MASK(irq_idx));

/* ensure register writes go through */
wmb();
}

/**
* dpu_core_irq_callback_handler - dispatch core interrupts
* @arg: private data of callback handler
Expand Down Expand Up @@ -203,8 +188,6 @@ irqreturn_t dpu_core_irq(struct dpu_kms *dpu_kms)

dpu_core_irq_callback_handler(dpu_kms, irq_idx);

dpu_hw_intr_clear_intr_status_nolock(intr, irq_idx);

/*
* When callback finish, clear the irq_status
* with the matching mask. Once irq_status
Expand Down

0 comments on commit 6087623

Please sign in to comment.