]> www.infradead.org Git - users/hch/misc.git/commitdiff
drm/i915: Remove struct_mutex in i915_irq.c
authorLuiz Otavio Mello <luiz.mello@estudante.ufscar.br>
Mon, 8 Sep 2025 13:15:10 +0000 (09:15 -0400)
committerRodrigo Vivi <rodrigo.vivi@intel.com>
Tue, 9 Sep 2025 14:34:25 +0000 (10:34 -0400)
Remove struct_mutex from ivb_parity_work() function.

The ivb_parity_work runs in a workqueue so it cannot race with itself.

Also, it is not protecting anything with the other remaining usage of
struct_mutex.

Signed-off-by: Luiz Otavio Mello <luiz.mello@estudante.ufscar.br>
Suggested-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Link: https://lore.kernel.org/r/20250908131518.36625-3-luiz.mello@estudante.ufscar.br
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
drivers/gpu/drm/i915/i915_irq.c

index 5916a648efbb4fc8a5e79cd376078047445e2c23..8d5da222a18792f135edda8b082416b7c43fc763 100644 (file)
@@ -163,11 +163,6 @@ static void ivb_parity_work(struct work_struct *work)
        u32 misccpctl;
        u8 slice = 0;
 
-       /* We must turn off DOP level clock gating to access the L3 registers.
-        * In order to prevent a get/put style interface, acquire struct mutex
-        * any time we access those registers.
-        */
-       mutex_lock(&dev_priv->struct_mutex);
 
        /* If we've screwed up tracking, just let the interrupt fire again */
        if (drm_WARN_ON(&dev_priv->drm, !dev_priv->l3_parity.which_slice))
@@ -225,7 +220,6 @@ out:
        gen5_gt_enable_irq(gt, GT_PARITY_ERROR(dev_priv));
        spin_unlock_irq(gt->irq_lock);
 
-       mutex_unlock(&dev_priv->struct_mutex);
 }
 
 static irqreturn_t valleyview_irq_handler(int irq, void *arg)