This is v2 of the second part of [1] refactoring the DP link capability
logic in patches 27-57 of [1]. The first part of [1] was merged, see
[2]. For the rationale of this patchset, please refer to the link
capability parts in the cover letter of [1].
This v2 version has the following changes:
- Address the review comments from Jani:
- Remove unneeded function documentation.
- Add a helper to debug print the link rates tracked by link_caps
instead of exposing the rates.
- Simplify tracking of link capability changes as suggested by Ville,
removing the need to track changes or adjust the maximum link
parameter limits set by the fallback logic. This is possible, since the
limits are reset now (after patchset [3]) whenever any link parameter
changes. This resulted in dropping patches 46, 48, 51 from patchset [1].
Cc: Jani Nikula <[email protected]>
Cc: Ville Syrjälä <[email protected]>
[1] https://lore.kernel.org/all/[email protected]
[2] https://lore.kernel.org/all/[email protected]
[3] https://lore.kernel.org/all/[email protected]
Imre Deak (28):
drm/i915/dp: Rename intel_dp_link_config to intel_dp_link_config_entry
drm/i915/dp: Add struct intel_dp_link_config
drm/i915/dp_link_caps: Introduce DP link capability module
drm/i915/dp_link_caps: Move common rate helpers to link caps
drm/i915/dp_link_caps: Move forced link param helpers to link caps
drm/i915/dp: Simplify querying of forced link parameters
drm/i915/dp_link_caps: Move forced and max link debugfs entries to
link caps
drm/i915/dp_link_training: Use helpers to get forced link params
drm/i915/dp_link_caps: Move forced link params to link_caps
drm/i915/dp_link_caps: Move link config helpers to link caps
drm/i915/dp_link_caps: Move link config tracking to link_caps
drm/i915/dp_link_caps: Rename helper updating the link configurations
drm/i915/dp: Factor out helper to get link rate capabilities
drm/i915/dp_link_caps: Pass supported link rates to link caps update
drm/i915/dp_link_caps: Add helper to print all supported link rates
drm/i915/dp_link_caps: Add helper to get the number of supported link
rates
drm/i915/dp_link_caps: Add helper to get common rate index
drm/i915/dp_link_caps: Move tracking of common rates to link_caps
struct
drm/i915/dp_link_caps: Track max common lane count in link_caps
drm/i915/dp_link_caps: Use max common lane count from link_caps
drm/i915/dp_link_caps: Add helpers to get max link limits
drm/i915/dp_link_caps: Add helpers to set max link limits
drm/i915/dp_link_caps: Add helper to reset max link limits
drm/i915/dp_link_caps: Add helper to reset link_caps state
drm/i915/dp_link_caps: Move max link limits to link_caps
drm/i915/dp_link_caps: Pass link_caps to static functions
drm/i915/dp_link_caps: Pass link_caps to config update/lookup helpers
drm/i915/dp_link_caps: Pass link_caps to common rate helpers
drivers/gpu/drm/i915/Makefile | 1 +
.../drm/i915/display/intel_display_debugfs.c | 2 +
.../drm/i915/display/intel_display_types.h | 32 +-
drivers/gpu/drm/i915/display/intel_dp.c | 272 ++-----
drivers/gpu/drm/i915/display/intel_dp.h | 6 +-
.../gpu/drm/i915/display/intel_dp_link_caps.c | 675 ++++++++++++++++++
.../gpu/drm/i915/display/intel_dp_link_caps.h | 47 ++
.../drm/i915/display/intel_dp_link_training.c | 320 +--------
drivers/gpu/drm/i915/display/intel_dp_test.c | 7 +-
.../gpu/drm/i915/display/intel_dp_tunnel.c | 6 +-
drivers/gpu/drm/xe/Makefile | 1 +
11 files changed, 854 insertions(+), 515 deletions(-)
create mode 100644 drivers/gpu/drm/i915/display/intel_dp_link_caps.c
create mode 100644 drivers/gpu/drm/i915/display/intel_dp_link_caps.h
--
2.49.1