linux_dsm_epyc7002/drivers/gpu/drm/nouveau/dispnv50
Lyude Paul 6f85f73821 drm/dp_mst: Add basic topology reprobing when resuming
Finally! For a very long time, our MST helpers have had one very
annoying issue: They don't know how to reprobe the topology state when
coming out of suspend. This means that if a user has a machine connected
to an MST topology and decides to suspend their machine, we lose all
topology changes that happened during that period. That can be a big
problem if the machine was connected to a different topology on the same
port before resuming, as we won't bother reprobing any of the ports and
likely cause the user's monitors not to come back up as expected.

So, we start fixing this by teaching our MST helpers how to reprobe the
link addresses of each connected topology when resuming. As it turns
out, the behavior that we want here is identical to the behavior we want
when initially probing a newly connected MST topology, with a couple of
important differences:

- We need to be more careful about handling the potential races between
  events from the MST hub that could change the topology state as we're
  performing the link address reprobe
- We need to be more careful about handling unlikely state changes on
  ports - such as an input port turning into an output port, something
  that would be far more likely to happen in situations like the MST hub
  we're connected to being changed while we're suspend

Both of which have been solved by previous commits. That leaves one
requirement:

- We need to prune any MST ports in our in-memory topology state that
  were present when suspending, but have not appeared in the post-resume
  link address response from their parent branch device

Which we can now handle in this commit by modifying
drm_dp_send_link_address(). We then introduce suspend/resume reprobing
by introducing drm_dp_mst_topology_mgr_invalidate_mstb(), which we call
in drm_dp_mst_topology_mgr_suspend() to traverse the in-memory topology
state to indicate that each mstb needs it's link address resent and PBN
resources reprobed.

On resume, we start back up &mgr->work and have it reprobe the topology
in the same way we would on a hotplug, removing any leftover ports that
no longer appear in the topology state.

Changes since v4:
* Split indenting changes in drm_dp_mst_topology_mgr_resume() into a
  separate patch
* Only fire hotplugs when something has actually changed after a link
  address probe
* Don't try to change port->connector at all on ports, just throw out
  ports that need their connectors removed to make things easier.

Cc: Juston Li <juston.li@intel.com>
Cc: Imre Deak <imre.deak@intel.com>
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Cc: Harry Wentland <hwentlan@amd.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Sean Paul <sean@poorly.run>
Signed-off-by: Lyude Paul <lyude@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20191022023641.8026-14-lyude@redhat.com
2019-10-24 14:29:48 -04:00
..
atom.h drm/nouveau/kms/gv100-: attach pixel blend mode property to planes 2019-08-23 12:55:33 +10:00
base507c.c drm/nouveau/kms/nv50-: add fp16 scanout support 2019-08-23 12:55:31 +10:00
base827c.c drm/nouveau/kms/nv50-: add fp16 scanout support 2019-08-23 12:55:31 +10:00
base907c.c drm/nouveau/kms/gv100-: implement csc + enable modern colour managment properties 2019-08-23 12:55:32 +10:00
base917c.c drm/nouveau/kms/nv50-: add fp16 scanout support 2019-08-23 12:55:31 +10:00
base.c
base.h
core507d.c
core827d.c
core907d.c
core917d.c
core.c drm/nouveau/disp/tu102: rename implementation from tu104 2019-02-20 08:59:58 +10:00
core.h
corec37d.c drm/nouveau/kms/gv100: allow windows to use PACKED8BPP formats 2019-08-23 12:55:31 +10:00
corec57d.c
curs507a.c
curs907a.c
curs.c drm/nouveau/disp/tu102: rename implementation from tu104 2019-02-20 08:59:58 +10:00
curs.h
cursc37a.c
dac507d.c
dac907d.c
disp.c drm/dp_mst: Add basic topology reprobing when resuming 2019-10-24 14:29:48 -04:00
disp.h drm/nouveau/kms/gv100-: fix spurious window immediate interlocks 2019-05-14 16:58:05 +10:00
head507d.c
head827d.c
head907d.c
head917d.c
head.c drm/nouveau/kms/nv50-: create primary plane before overlay planes 2019-08-23 12:55:33 +10:00
head.h
headc37d.c
headc57d.c
Kbuild drm/nouveau: fix bogus GPL-2 license header 2019-07-19 16:26:51 +10:00
lut.c
lut.h
oimm507b.c
oimm.c
oimm.h
ovly507e.c drm/nouveau/kms/nv50-: remove overlay alpha formats 2019-08-23 12:55:32 +10:00
ovly827e.c drm/nouveau/kms/nv50-: remove overlay alpha formats 2019-08-23 12:55:32 +10:00
ovly907e.c drm/nouveau/kms/nv50-: remove overlay alpha formats 2019-08-23 12:55:32 +10:00
ovly917e.c drm/nouveau/kms/nv50-: remove overlay alpha formats 2019-08-23 12:55:32 +10:00
ovly.c
ovly.h
pior507d.c
sor507d.c
sor907d.c
sorc37d.c
wimm.c drm/nouveau/disp/tu102: rename implementation from tu104 2019-02-20 08:59:58 +10:00
wimm.h
wimmc37b.c drm/nouveau/kms/gv100-: fix spurious window immediate interlocks 2019-05-14 16:58:05 +10:00
wndw.c drm/atomic: Rename crtc_state->pageflip_flags to async_flip 2019-09-18 18:43:36 +02:00
wndw.h drm/nouveau/kms/gv100-: add support for plane zpos property 2019-08-23 12:55:33 +10:00
wndwc37e.c drm/nouveau/kms/gv100-: attach pixel blend mode property to planes 2019-08-23 12:55:33 +10:00
wndwc57e.c drm/nouveau/kms/gv100-: add support for plane zpos property 2019-08-23 12:55:33 +10:00