Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/i915/dp: Ack only the handled device service IRQs

Only those IRQs should be acked that are handled, however for SST all
IRQs triggered by the sink are acked. This can be a problem for flags
that are reserved/reading zero at a given moment, but become used for
some purpose - with a side-effect if set - in a future DPCD revision.

Fix the above by acking only those device service IRQs that will be
handled. While at it add asserts that only the known/acked device
service IRQs are handled both in the MST and SST case.

Reviewed-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Imre Deak <imre.deak@intel.com>
Link: https://patch.msgid.link/20260225164618.1261368-20-imre.deak@intel.com

Imre Deak 683853b1 0f3675d6

+14
+14
drivers/gpu/drm/i915/display/intel_dp.c
··· 4929 4929 drm_dp_mst_topology_mgr_set_mst(&intel_dp->mst.mgr, intel_dp->is_mst); 4930 4930 } 4931 4931 4932 + #define INTEL_DP_DEVICE_SERVICE_IRQ_MASK_SST (DP_AUTOMATED_TEST_REQUEST | \ 4933 + DP_CP_IRQ | \ 4934 + DP_SINK_SPECIFIC_IRQ) 4935 + 4936 + #define INTEL_DP_DEVICE_SERVICE_IRQ_MASK_MST (DP_CP_IRQ | \ 4937 + DP_DOWN_REP_MSG_RDY | \ 4938 + DP_UP_REQ_MSG_RDY) 4939 + 4932 4940 static bool 4933 4941 intel_dp_get_sink_irq_esi(struct intel_dp *intel_dp, u8 *esi) 4934 4942 { ··· 5033 5025 connector->base.base.id, connector->base.name, 5034 5026 encoder->base.base.id, encoder->base.name, 5035 5027 esi); 5028 + 5029 + esi[1] &= INTEL_DP_DEVICE_SERVICE_IRQ_MASK_SST; 5036 5030 5037 5031 if (mem_is_zero(&esi[1], 3)) 5038 5032 return true; ··· 5580 5570 if (mem_is_zero(ack, sizeof(ack))) 5581 5571 break; 5582 5572 5573 + drm_WARN_ON(display->drm, ack[1] & ~INTEL_DP_DEVICE_SERVICE_IRQ_MASK_MST); 5574 + 5583 5575 if (!intel_dp_ack_sink_irq_esi(intel_dp, ack)) 5584 5576 drm_dbg_kms(display->drm, "Failed to ack ESI\n"); 5585 5577 ··· 5865 5853 static void intel_dp_handle_device_service_irq(struct intel_dp *intel_dp, u8 irq_mask) 5866 5854 { 5867 5855 struct intel_display *display = to_intel_display(intel_dp); 5856 + 5857 + drm_WARN_ON(display->drm, irq_mask & ~INTEL_DP_DEVICE_SERVICE_IRQ_MASK_SST); 5868 5858 5869 5859 if (irq_mask & DP_AUTOMATED_TEST_REQUEST) 5870 5860 intel_dp_test_request(intel_dp);