ValveSoftware / SteamOS

SteamOS community tracker
1.57k stars 70 forks source link

Screen stays off when switching to desktop mode #1542

Open dangerousdonut opened 3 months ago

dangerousdonut commented 3 months ago

Your system information

Please describe your issue in as much detail as possible:

When switching to Desktop Mode on the Steam Deck, I expect to the screen to output an image. Instead, the (vast) majority of the times I attempt to switch to desktop mode, the screen stays off and won't turn on. The touchpads provide haptic feedback so something's going on there. Trying to invisibly move the mouse to the top left to boot back into gaming mode doesn't seem to work. I have to force shutdown the Deck to give it another try.

An odd wrinkle: I use the Steam Deck docked sometimes. When docked, switching to desktop hasn't failed yet. The screen always turns on in all the times I've tried it. I made sure the internal screen set to primary and even disabled output to the external monitor, but the issue persists once disconnected from the dock.

Steps for reproducing this issue:

  1. Hold the Power button
  2. Select the option to Switch to Desktop
plexecutor commented 3 months ago

Same issue here. Running preview build. 50/50 whether desktop mode loads or not. Only fix is a hard reboot.

lostgoat commented 3 months ago

We aren't seeing this behaviour in any of our units.

Can you do the following please:

  1. Trigger the black screen issue
  2. Reboot the unit
  3. Go to settings->system and scroll to the bottom to submit a system report
  4. Send me your steam username so I can check the logs from your unit.
Managor commented 3 months ago

I made a submission. Here's my profile https://steamcommunity.com/id/managor/

I'm going to make one or two more just for good measure.

dangerousdonut commented 3 months ago

@lostgoat

I also submitted a report after triggering the issue a moment ago. Username is okcomputing.

matte-schwartz commented 3 months ago

had the same freeze on my first switch between Game Mode and Desktop on a fresh recovery image install -> 3.6 beta update. if it happens again i'll try to ssh in and grab any relevant logs. username for system report is njtransit215

plexecutor commented 3 months ago

Just happened to me again. Created and uploaded a system report.

here is my steam profile: https://steamcommunity.com/id/dcarpenter85/

dangerousdonut commented 3 months ago

Do all of you who experienced the issue also use the Steam Deck on conjunction with a dock, either Valve's or a third party's?

plexecutor commented 3 months ago

Do all of you who experienced the issue also use the Steam Deck on conjunction with a dock, either Valve's or a third party's?

No, I do not and have not ever used a dock. I’ve noticed the issue seems to happen most often when Steam downloads game or system updates after turning on or waking up the deck. Could just be coincidence but it’s the only common denominator I’ve noticed.

matte-schwartz commented 3 months ago

No dock used here. While downloads are occurring is pretty interesting though since that would also line up with why my desktop transition froze - it was doing all the initial shader cache downloads at the time of the black screen.

simpson30 commented 3 months ago

I'm also having this issue, always on 3.6.x builds. It's always a roll of dice if desktop mode will load or not, when it doesn't the screen stays black but I can hear the fan spinning and am able to put the unit to sleep and wake it, but the black screen remains.

Earlier when 3.6.x was on the preview channel I swapped back to beta channel 3.5.x and the problem went away, desktop mode worked everytime. Now beta channel is 3.6.x and the problem has returned.

I should also note that while I do have and use the official dock and a few third party docks/adapters, the problem has never occurred when connected to one, nor have I tried to swap to desktop mode while connected to one.

I submitted a system report with the instructions posted above, Steam username is alex11947 or dohboy15, not sure which one it uses.

matte-schwartz commented 3 months ago

from what I can tell by watching my journal via ssh during a successful switch vs a failed switch and then diffing logs, during a failed switch, kscreen_backend_launcher seems to believe it needs to change the screen resolution for some reason which leads to the black screen. here is a good transition to desktop:

Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper: Detected XRandR 1.6
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper: Event Base:  89
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper: Event Error:  147
Jun 28 17:39:29 steamdeck kded5[2778]: kscreen.kded: PowerDevil SuspendSession action not available!
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xrandr: XRandR::setConfig
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xrandr: Requested screen size is QSize(1280, 800)
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xrandr: Needed CRTCs:  1
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xrandr: Actions to perform:
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xrandr:         Output 82 
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xrandr:         Change Screen Size: false
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xrandr:         Disable outputs: false
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xrandr:         Change outputs: false
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xrandr:         Enable outputs: false
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xrandr: RRSetOutputPrimary 
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xrandr: RRSetOutputPrimary 
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xrandr: XRandR::setConfig done!
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper: RRNotify_OutputProperty (ignored)
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper:         Timestamp:  69864
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper:         Output:  82
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper:         Property:  _KDE_SCREEN_INDEX
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper:         State (newValue, Deleted):  0
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper: RRNotify_OutputProperty (ignored)
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper:         Timestamp:  69864
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper:         Output:  82
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper:         Property:  _KDE_SCREEN_INDEX
Jun 28 17:39:29 steamdeck kscreen_backend_launcher[2950]: kscreen.xcb.helper:         State (newValue, Deleted):  0

and here is a bad transition to desktop:

Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper: Detected XRandR 1.6
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper: Event Base:  89
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper: Event Error:  147
Jun 28 17:50:40 steamdeck kded5[21128]: kscreen.kded: PowerDevil SuspendSession action not available!
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: XRandR::setConfig
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: Requested screen size is QSize(1280, 800)
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: Needed CRTCs:  1
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: Actions to perform:
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr:         Output 82 
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr:         Change Screen Size: true
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr:                 Old: QSize(320, 200) 
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr:         Disable outputs: false
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr:         Change outputs: false
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr:         Enable outputs: true
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr:                  (82)
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: RRSetScreenSize 
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: QMap((78, XRandRCrtc(0x555fa93281e0))(79, XRandRCrtc(0x555fa93283c0))(80, XRandRCrtc(0x555fa9324dc0))(81, XRandRCrtc(0x555fa9324610)))
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: Testing CRTC 78 
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: RRSetCrtcConfig (enable output) 
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: XRandRCrtc  78  m_timestamp update  0  =>  737616
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr:         Result:  3  timestamp:  737616
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: Output failed to be Enabled:  "eDP"
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: RRSetOutputPrimary 
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: RRSetOutputPrimary 
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: Requested screen size is QSize(1280, 800)
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: Forced to change screen size:  QSize(1280, 800)
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: RRSetScreenSize 
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xrandr: XRandR::setConfig done!
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper: RRScreenChangeNotify
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Timestamp:  737616
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Config_timestamp:  737759
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Window: 44040197
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Root: 1320
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Rotation:  "Rotate_0"
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Size ID: 65535
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Size:  1280 800
Jun 28 17:50:40 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         SizeMM:  332 208
Jun 28 17:50:41 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper: RRNotify_OutputProperty (ignored)
Jun 28 17:50:41 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Timestamp:  740959
Jun 28 17:50:41 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Output:  82
Jun 28 17:50:41 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Property:  _KDE_SCREEN_INDEX
Jun 28 17:50:41 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         State (newValue, Deleted):  0
Jun 28 17:50:41 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper: RRNotify_OutputProperty (ignored)
Jun 28 17:50:41 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Timestamp:  740959
Jun 28 17:50:41 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Output:  82
Jun 28 17:50:41 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         Property:  _KDE_SCREEN_INDEX
Jun 28 17:50:41 steamdeck kscreen_backend_launcher[21241]: kscreen.xcb.helper:         State (newValue, Deleted):  0
Jun 28 17:50:41 steamdeck kded5[21128]: kscreen.kded: Config does not have at least one screen enabled, WILL NOT save this config, this is not what user wants.

there are also a couple additional ways to recover from a failed switch from game mode to desktop. steamos-session-select gamescope will send you back to gamescope-session, and steamos-session-select plasma will actually launch you into a successful plasma session after a few seconds.

(deck@steamdeck ~)$ steamos-session-select plasma
Updated user selected session to plasma-steamos-oneshot.desktop
Updated user selected session to plasma-steamos-oneshot.desktop
Updated system autologin session to plasma-steamos-oneshot.desktop
Restarted SDDM

I have not found a reliable way to reproduce this yet, just recover from it when it happens.

Edit: I tried to submit a report with drm-debugging disabled but it must be too large since it failed to send. of interest is what happens when it fails:

[   80.710173] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:113:eDP-1]
[   80.710193] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] Supported Monitor Refresh rate range is 0 Hz - 0 Hz
[   80.710201] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] Assigning EDID-1.4 digital sink color depth as 8 bpc.
[   80.710205] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] ELD monitor ANX7530 U
[   80.710209] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] ELD size 32, SAD count 0
[   80.711974] [drm:update_stream_scaling_settings [amdgpu]] Destination Rectangle x:0  y:0  width:800  height:1280
[   80.712875] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:113:eDP-1] probed modes :
[   80.712886] [drm:drm_mode_debug_printmodeline] Modeline "800x1280": 90 102000 800 818 822 858 1280 1288 1290 1320 0x48 0x5
[   80.713121] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:122:DP-1]
[   80.713128] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:122:DP-1] disconnected
[   81.118110] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:113:eDP-1]
[   81.118130] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] Supported Monitor Refresh rate range is 0 Hz - 0 Hz
[   81.118138] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] Assigning EDID-1.4 digital sink color depth as 8 bpc.
[   81.118143] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] ELD monitor ANX7530 U
[   81.118148] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] ELD size 32, SAD count 0
[   81.119901] [drm:update_stream_scaling_settings [amdgpu]] Destination Rectangle x:0  y:0  width:800  height:1280
[   81.120605] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:113:eDP-1] probed modes :
[   81.120615] [drm:drm_mode_debug_printmodeline] Modeline "800x1280": 90 102000 800 818 822 858 1280 1288 1290 1320 0x48 0x5
[   81.120865] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:122:DP-1]
[   81.120878] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:122:DP-1] disconnected
[   81.225333] amdgpu 0000:04:00.0: [drm:drm_mode_addfb2] [FB:146]
[   81.225613] amdgpu 0000:04:00.0: [drm:drm_mode_addfb2] [FB:147]
[   81.225989] [drm:drm_mode_setcrtc] [CRTC:99:crtc-0]
[   81.226005] amdgpu 0000:04:00.0: [drm:drm_framebuffer_check_src_coords] Invalid source coordinates 1280.000000x800.000000+0.000000+0.000000 (fb 800x1280)
[   84.865020] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:113:eDP-1]
[   84.865050] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] Supported Monitor Refresh rate range is 0 Hz - 0 Hz
[   84.865064] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] Assigning EDID-1.4 digital sink color depth as 8 bpc.
[   84.865074] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] ELD monitor ANX7530 U
[   84.865082] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] ELD size 32, SAD count 0
[   84.866908] [drm:update_stream_scaling_settings [amdgpu]] Destination Rectangle x:0  y:0  width:800  height:1280
[   84.867933] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:113:eDP-1] probed modes :
[   84.867944] [drm:drm_mode_debug_printmodeline] Modeline "800x1280": 90 102000 800 818 822 858 1280 1288 1290 1320 0x48 0x5
[   84.868314] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:122:DP-1]
[   84.868323] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:122:DP-1] disconnected
[   84.984565] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:113:eDP-1]
[   84.984589] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] Supported Monitor Refresh rate range is 0 Hz - 0 Hz
[   84.984599] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] Assigning EDID-1.4 digital sink color depth as 8 bpc.
[   84.984606] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] ELD monitor ANX7530 U
[   84.984611] amdgpu 0000:04:00.0: [drm:update_display_info.part.0] [CONNECTOR:113:eDP-1] ELD size 32, SAD count 0
[   84.986396] [drm:update_stream_scaling_settings [amdgpu]] Destination Rectangle x:0  y:0  width:800  height:1280
[   84.987246] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:113:eDP-1] probed modes :
[   84.987255] [drm:drm_mode_debug_printmodeline] Modeline "800x1280": 90 102000 800 818 822 858 1280 1288 1290 1320 0x48 0x5
[   84.987561] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:122:DP-1]
[   84.987569] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:122:DP-1] disconnected
matte-schwartz commented 3 months ago

This appears to have been resolved on my OLED Deck with SteamOS Main 20240702.1000 and the addition of drm_janitor. I suspect it'll be rolled out to SteamOS Preview soon as Main is the dev branch for bleeding-edge packages.

Mockordio commented 2 months ago

I'm on preview channel and still having this issue. Tried every solution I could find, nothing helped. Sometimes it would switch to Desktop mode the first try, other times it requires 1-3 manual reboots until I can get there. Very annoying to deal with because I need to switch to desktop often and the startup time after the manual reboot is always longer (it always does the "extracting package" thing). Is that update supposed to be up on the preview channel by now?

matte-schwartz commented 2 months ago

It is not on the Preview channel last I checked, I would expect mention of it in a SteamOS Preview changelog via the Steam Official News section of the Steam client when an update gets rolled out. For now, I'd recommend using Stable if switching to desktop is something you do often.

Managor commented 2 months ago

I am also on the Main branch now and I haven't encountered this issue any more. Expect it to be rolled out to Beta/Preview some day.

dangerousdonut commented 2 months ago

I am also on the Main branch now and I haven't encountered this issue any more. Expect it to be rolled out to Beta/Preview some day.

That's heartening. It's one of the more troublesome issues I'm encountering at the moment.

AwkwaBear commented 1 month ago

I have had this issue as well and I suspect it has something to do with not properly initializing the display as the primary (or only) display connected. I think it boots properly into desktop mode but the internal display is not being set.

I have had similar behavior in a different situation when I set my external display connected via USBC to the primary display and duplicate it to the internal one as a secondary cloned output. When I switched to game mode, then unplugged the external display, then booted back into desktop mode, I was met with a black screen. This was due to some bug where my external monitor was still trying to be set as the primary and the internal display was just left blank due to it bugging out attempting to duplicate a display that was not connected.

I will test further but I believe that if you swap to desktop mode with an external display connected, it will properly boot into desktop and show on the external display every time. Further investigation into settings associated with this may expose the bugged behavior.

matte-schwartz commented 1 month ago

It's already solved on SteamOS Main as of a few weeks ago, it just hasn't made it into a Preview image yet.

Managor commented 1 month ago

I assume this is now fixed in preview

philfycasual commented 2 weeks ago

Personally still seeing this -- not only when switching to desktop mode, but also when just starting up (into gaming mode). It got fixed sometime in 3.6.x but then regressed and since it was supposedly fixed again I've still been experiencing it.

matte-schwartz commented 2 weeks ago

Hmm, sounds like maybe a different issue if it's also happening when booting into Game Mode? this specific regression was only when switching to desktop, and has not reappeared for me on 3.6 or Main since being fixed with drm_janitor

philfycasual commented 2 weeks ago

Just went back to check if it might have been related to VRR being enabled but it looks like what I did to enable it had been reset (possibly due to the updates), so it wasn't that. It had worked for me, albeit briefly, both on regular boot and switching into Desktop mode. Is it possible to select particular beta versions to see when it may have been fixed the first time?

matte-schwartz commented 2 weeks ago

Not that I'm aware, although it would certainly be helpful for troubleshooting scenarios like this. I think you can only downgrade package versions individually after unlocking the rootfs.