[Windows Host] A hang when querying D3D capabilities will prevent the remote user from connecting |
||||
Issue descriptionWe've had reports of users unable to connect to their Windows machines, the symptom is a white screen which is displayed for ~25 seconds before disconnecting. Note that this occurs on machines with curtain mode enabled. I debugged the problem and found that it was due to a hang in D3D11CreateDevice() which is used when determining whether to support D3D rendering. The root cause is likely a driver or Windows update patch which is causing this new problem, since we don't control those, we should put a timeout into place to ensure a hang in that method won't prevent the user from connecting remotely.
,
Aug 6
,
Aug 15
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/ee9ee6345abd0cfeb8a5b94446a278acdfe69e24 commit ee9ee6345abd0cfeb8a5b94446a278acdfe69e24 Author: Joe Downing <joedow@chromium.org> Date: Wed Aug 15 16:30:02 2018 [Windows Host] Prevent connection hang for hosts with 3D Display Mode enabled This change prevents a hang when connecting to a Windows machine which has curtain mode and 3d display mode enabled. The root cause of the hang is that creating a D3D11 device takes several seconds so function calls which used to take a few milliseconds now take 5+ seconds. I did not see a mechanism to control this display mode programatically so I am adding code which can detect the condition and the logic to prevent D3D usage when 3D mode is enabled. Of note is the change in BasicDesktopEnvironment where I requery the D3D apis. DesktopEnvironmentOptions are queried in Session 0 and then passed on to the Desktop process. There is a non-obvious problem with this as many D3D methods cannot be queried or will not return reliable results. This results in a base set of options being set in Session 0 (which includes user / experiment overrides) and then passed into a session where D3D will return new values. In this CL, I requery the D3D APIs and update the capturer options if they should be disabled. BUG= 836007 Change-Id: Ib7a6e61fa7987bd093e93a6100b97cc49e3aff05 Reviewed-on: https://chromium-review.googlesource.com/1164403 Commit-Queue: Joe Downing <joedow@chromium.org> Reviewed-by: Jamie Walch <jamiewalch@chromium.org> Cr-Commit-Position: refs/heads/master@{#583276} [modify] https://crrev.com/ee9ee6345abd0cfeb8a5b94446a278acdfe69e24/remoting/host/basic_desktop_environment.cc [modify] https://crrev.com/ee9ee6345abd0cfeb8a5b94446a278acdfe69e24/remoting/host/desktop_environment_options.cc [modify] https://crrev.com/ee9ee6345abd0cfeb8a5b94446a278acdfe69e24/remoting/host/evaluate_capability.cc [modify] https://crrev.com/ee9ee6345abd0cfeb8a5b94446a278acdfe69e24/remoting/host/host_attributes.cc [modify] https://crrev.com/ee9ee6345abd0cfeb8a5b94446a278acdfe69e24/remoting/host/switches.cc [modify] https://crrev.com/ee9ee6345abd0cfeb8a5b94446a278acdfe69e24/remoting/host/switches.h [modify] https://crrev.com/ee9ee6345abd0cfeb8a5b94446a278acdfe69e24/remoting/host/win/BUILD.gn [add] https://crrev.com/ee9ee6345abd0cfeb8a5b94446a278acdfe69e24/remoting/host/win/evaluate_3d_display_mode.cc [add] https://crrev.com/ee9ee6345abd0cfeb8a5b94446a278acdfe69e24/remoting/host/win/evaluate_3d_display_mode.h [modify] https://crrev.com/ee9ee6345abd0cfeb8a5b94446a278acdfe69e24/remoting/host/win/evaluate_d3d.cc [modify] https://crrev.com/ee9ee6345abd0cfeb8a5b94446a278acdfe69e24/remoting/host/win/evaluate_d3d.h
,
Aug 15
,
Aug 18
,
Aug 19
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/8cc2653e5d8756652d3e7aabf603ceedcb92a756 commit 8cc2653e5d8756652d3e7aabf603ceedcb92a756 Author: Nico Weber <thakis@chromium.org> Date: Sun Aug 19 00:04:42 2018 Revert "[Windows Host] Prevent connection hang for hosts with 3D Display Mode enabled" This reverts commit ee9ee6345abd0cfeb8a5b94446a278acdfe69e24. Reason for revert: Likely broke remoting tests on Win7, https://crbug.com/875619 Original change's description: > [Windows Host] Prevent connection hang for hosts with 3D Display Mode enabled > > This change prevents a hang when connecting to a Windows machine > which has curtain mode and 3d display mode enabled. The root cause > of the hang is that creating a D3D11 device takes several seconds so > function calls which used to take a few milliseconds now take 5+ > seconds. I did not see a mechanism to control this display mode > programatically so I am adding code which can detect the condition > and the logic to prevent D3D usage when 3D mode is enabled. > > Of note is the change in BasicDesktopEnvironment where I requery the > D3D apis. DesktopEnvironmentOptions are queried in Session 0 and > then passed on to the Desktop process. There is a non-obvious > problem with this as many D3D methods cannot be queried or will > not return reliable results. This results in a base set of options > being set in Session 0 (which includes user / experiment overrides) > and then passed into a session where D3D will return new values. In > this CL, I requery the D3D APIs and update the capturer options if > they should be disabled. > > BUG= 836007 > > Change-Id: Ib7a6e61fa7987bd093e93a6100b97cc49e3aff05 > Reviewed-on: https://chromium-review.googlesource.com/1164403 > Commit-Queue: Joe Downing <joedow@chromium.org> > Reviewed-by: Jamie Walch <jamiewalch@chromium.org> > Cr-Commit-Position: refs/heads/master@{#583276} TBR=jamiewalch@chromium.org,joedow@chromium.org # Not skipping CQ checks because original CL landed > 1 day ago. Bug: 836007 Change-Id: I464ba6eb37560ef6fc687516e9e33682bee4ac7a Reviewed-on: https://chromium-review.googlesource.com/1180681 Reviewed-by: Nico Weber <thakis@chromium.org> Commit-Queue: Nico Weber <thakis@chromium.org> Cr-Commit-Position: refs/heads/master@{#584325} [modify] https://crrev.com/8cc2653e5d8756652d3e7aabf603ceedcb92a756/remoting/host/basic_desktop_environment.cc [modify] https://crrev.com/8cc2653e5d8756652d3e7aabf603ceedcb92a756/remoting/host/desktop_environment_options.cc [modify] https://crrev.com/8cc2653e5d8756652d3e7aabf603ceedcb92a756/remoting/host/evaluate_capability.cc [modify] https://crrev.com/8cc2653e5d8756652d3e7aabf603ceedcb92a756/remoting/host/host_attributes.cc [modify] https://crrev.com/8cc2653e5d8756652d3e7aabf603ceedcb92a756/remoting/host/switches.cc [modify] https://crrev.com/8cc2653e5d8756652d3e7aabf603ceedcb92a756/remoting/host/switches.h [modify] https://crrev.com/8cc2653e5d8756652d3e7aabf603ceedcb92a756/remoting/host/win/BUILD.gn [delete] https://crrev.com/430971390791ab478e404c174eb13cc56e49f8f8/remoting/host/win/evaluate_3d_display_mode.cc [delete] https://crrev.com/430971390791ab478e404c174eb13cc56e49f8f8/remoting/host/win/evaluate_3d_display_mode.h [modify] https://crrev.com/8cc2653e5d8756652d3e7aabf603ceedcb92a756/remoting/host/win/evaluate_d3d.cc [modify] https://crrev.com/8cc2653e5d8756652d3e7aabf603ceedcb92a756/remoting/host/win/evaluate_d3d.h |
||||
►
Sign in to add a comment |
||||
Comment 1 by joedow@chromium.org
, Jun 22 2018