drm/i915/dp_mst: Fix race between connector registration and setup
authorImre Deak <imre.deak@intel.com>
Sun, 29 Oct 2023 23:13:08 +0000 (01:13 +0200)
committerImre Deak <imre.deak@intel.com>
Wed, 8 Nov 2023 15:22:04 +0000 (17:22 +0200)
commit560ea72c76eb6d0c59f77580414e64cc09f1093d
tree9f05a4362c159242329197713e8835244f2c69a7
parent607a2c64e879580ef361af65d6052367057bee14
drm/i915/dp_mst: Fix race between connector registration and setup

After drm_connector_init() is called the connector is visible to the
rest of the kernel via the drm_mode_config::connector_list. Make
sure that the DSC AUX device and capabilities are setup by that time.

Another race condition is adding the connector to the connector list
before drm_connector_helper_add() sets the connector helper functions.
That's an unrelated issue, for which the fix is for a follow-up. One
solution would be adding the connector to the connector list only
during its registration in drm_connector_register().

Cc: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com>
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Fixes: 808b43fa7e56 ("drm/i915/dp_mst: Set connector DSC capabilities and decompression AUX")
Reviewed-by: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com>
Signed-off-by: Imre Deak <imre.deak@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20231030155843.2251023-2-imre.deak@intel.com
drivers/gpu/drm/i915/display/intel_dp_mst.c