[Intel-xe] [PATCH v2 8/8] drm/xe/irq: Don't clobber display interrupts on multi-tile platforms
Matt Roper
matthew.d.roper at intel.com
Sat Apr 1 00:21:06 UTC 2023
Although our only multi-tile platform today (PVC) doesn't support
display, it's possible that some future multi-tile platform will.
If/when this happens, display interrupts (both traditional display and
ASLE backlight interrupts raised as a Gunit interrupt) should be
delivered to the primary tile. Save away tile0's master_ctl value so
that it can still be used for display interrupt handling after the GT
loop.
Reviewed-by: Lucas De Marchi <lucas.demarchi at intel.com>
Signed-off-by: Matt Roper <matthew.d.roper at intel.com>
---
drivers/gpu/drm/xe/xe_irq.c | 14 +++++++++++---
1 file changed, 11 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/xe/xe_irq.c b/drivers/gpu/drm/xe/xe_irq.c
index 9a119aa95cbb..13f9f220bca0 100644
--- a/drivers/gpu/drm/xe/xe_irq.c
+++ b/drivers/gpu/drm/xe/xe_irq.c
@@ -355,7 +355,7 @@ static irqreturn_t dg1_irq_handler(int irq, void *arg)
{
struct xe_device *xe = arg;
struct xe_gt *gt;
- u32 master_tile_ctl, master_ctl = 0, gu_misc_iir;
+ u32 master_tile_ctl, master_ctl = 0, tile0_master_ctl = 0, gu_misc_iir;
long unsigned int intr_dw[2];
u32 identity[32];
u8 id;
@@ -389,11 +389,19 @@ static irqreturn_t dg1_irq_handler(int irq, void *arg)
if (!xe_gt_is_media_type(gt))
xe_mmio_write32(gt, GFX_MSTR_IRQ.reg, master_ctl);
gt_irq_handler(xe, gt, master_ctl, intr_dw, identity);
+
+ /*
+ * Save primary tile's master interrupt register for display
+ * processing below.
+ */
+ if (id == 0)
+ tile0_master_ctl = master_ctl;
}
- xe_display_irq_handler(xe, master_ctl);
+ xe_display_irq_handler(xe, tile0_master_ctl);
- gu_misc_iir = gu_misc_irq_ack(gt, master_ctl);
+ /* Gunit GSE interrupts can trigger display backlight operations */
+ gu_misc_iir = gu_misc_irq_ack(gt, tile0_master_ctl);
dg1_intr_enable(xe, false);
--
2.39.2
More information about the Intel-xe
mailing list