SteamVR-for-Linux icon indicating copy to clipboard operation
SteamVR-for-Linux copied to clipboard

SteamVR fails to use direct display

Open dbgasaway opened this issue 2 years ago • 29 comments

Describe the bug Whenever I launch SteamVR, it currently always shows the 2 eye displays on desktop. No graphics are sent to the Index at all, so it's not usable.

There are also occasional minor graphical glitches on the eye displays, where parts are grayed out for a split second (hard to grab a screenshot), but that's a minor issue and has been going on for longer.

Troubleshooting steps I already tried:

  • Reset headset
  • Power-cycle the computer and Index
  • Re-plug-in cables

To Reproduce Steps to reproduce the behavior:

  1. Launch SteamVR
  2. See the VRCompositor window and a warning about direct display mode

Expected behavior No window appears on the screen, and graphics appear on the Index display

System Information (please complete the following information):

  • Distribution: Pop!_OS 22.04
  • SteamVR version: 1.22.12 (1652742976)
  • Steam client version: May 21, 2022 - 1653101165? It is fully up-to-date though.
  • Opted into Steam client beta?: No
  • Graphics driver version: 510.68.02
  • Gist for SteamVR System Information: https://gist.github.com/dbgasaway/688e7823c53f62e6357b3787dd313501

Screenshots (like other posts where it just shows on desktop only)

Additional context

The interesting part from the logs I think is:

Sun May 29 2022 17:14:49.674008 - HMD deviceUUID is 537207a7b7f41b67
Sun May 29 2022 17:14:49.674045 - Looking for direct display through RandR
Sun May 29 2022 17:14:49.674059 -  - Root 0x93c
Sun May 29 2022 17:14:49.717859 -    - Output 0x41 - 115 modes, 1 preferred
Sun May 29 2022 17:14:49.717893 -      - Mode 0 0x43 3840x2160 (looking for 2880x1600)
Sun May 29 2022 17:14:49.719423 -    - Output 0x242 - 0 modes, 0 preferred
Sun May 29 2022 17:14:49.724531 -    - Output 0x243 - 0 modes, 0 preferred
Sun May 29 2022 17:14:49.727061 -    - Output 0x244 - 0 modes, 0 preferred
Sun May 29 2022 17:14:49.727186 -    - Output 0x245 - 0 modes, 0 preferred
Sun May 29 2022 17:14:49.727284 -    - Output 0x246 - 0 modes, 0 preferred
Sun May 29 2022 17:14:49.727341 -    - Output 0x247 - 0 modes, 0 preferred
Sun May 29 2022 17:14:49.727395 -    - Output 0x248 - 0 modes, 0 preferred
Sun May 29 2022 17:14:49.727421 -    - Output 0x249 - 0 modes, 0 preferred
Sun May 29 2022 17:14:49.727433 - Tried to find direct display through RandR: (nil)
Sun May 29 2022 17:14:49.727442 - Looking for direct display through Vulkan WSI
Sun May 29 2022 17:14:49.733127 -  - Vulkan output 0: 2880x1600 resolution, 0x0 dimensions - Valve Corporation Index HMD (DP-5)
Sun May 29 2022 17:14:49.733240 - Tried to find direct display through Vulkan WSI: 0x561c6299da20
Sun May 29 2022 17:14:49.736357 - Trying to match desired rate of 90.003006Hz.
Sun May 29 2022 17:14:49.736389 - 4 modes on display:
Sun May 29 2022 17:14:49.736403 -  - 0: [email protected]
Sun May 29 2022 17:14:49.736414 -  - 1: [email protected]
Sun May 29 2022 17:14:49.736423 -  - 2: [email protected]
Sun May 29 2022 17:14:49.736432 -  - 3: [email protected]
Sun May 29 2022 17:14:49.736441 - Selected mode 0.
Sun May 29 2022 17:14:49.738494 - Failed to acquire xlib display
Sun May 29 2022 17:14:49.738513 - CHmdWindowSDL: Failed to create direct mode surface

Some ~months ago, this used to not be the case - I would only have this issue intermittently, and it could be fixed by resetting the Index and adjusting cables. I tried to use it again recently, and discovered the above new issue. I'm wondering if it's due to new nvidia drivers (going from 4?? to 510) as I did upgrade to 22.04 during that time, but it's hard to say due to the long time difference. I had also adusted VK_ICD_FILENAMES to get display working, and pulse settings to fix sound a while earlier, before it had the current issue.

This seems to be different than existing issues given that

  • While I am using a laptop, I am not using prime or any other hybrid setup
  • I am using xorg, not wayland
  • I am just using the GPU that came with the laptop, no external GPUs

Note: Commenters who are also experiencing this issue are encouraged to include the "System Information" section in their replies.

dbgasaway avatar May 30 '22 00:05 dbgasaway

Same issue here for multiple months now i belive since nvidia driver 510 or something.

YourSandwich avatar Jun 01 '22 12:06 YourSandwich

i'm having this issue now, on arch with nvidia glad to see that this issue isn't fixed, seeing as steam support sent me here

headassbtw avatar Jun 23 '22 06:06 headassbtw

I am still having the same issue with the 515 drivers

dbgasaway avatar Jun 25 '22 08:06 dbgasaway

Seems like the same issue as #514 and same symptoms as @dbgasaway described, when this happens previously(few months ago) readjusting cables, turning index on and off, rebooting PC it would work fine. But now it's just permanent and the Index HMD is of no use.

glad to see that this issue isn't fixed, seeing as steam support sent me here

Really wished that Valve dedicated a bit more to Linux VR(given they are fully embracing it now with Proton + Steamdeck), I'm happy to provide every kind of logs you need, happy to test out debug patches etc. But you're just left wandering around and regretting your purchase(Well Linux VR is experimental, not able to use your product at all and no workaround whatsoever is really bad and not what you'd expect when it first just worked fine).

Gusted avatar Jun 26 '22 11:06 Gusted

I have this problem too.

  • Distribution: Arch
  • SteamVR version: 1.22.13 (1654131162)
  • Steam client version: Jun 7 2022, v020, 1654574690
  • Opted into Steam client beta?: No
  • Graphics driver version: nvidia 515.57-4
  • SteamVR-2022-07-10-AM_12_51_29.txt

The HMD was previously working when I was using the mesa drivers instead of the nvidia drivers, but neither the motherboard display port or the nvidia card display ports work now that I've decided to use nvidia.

exodrifter avatar Jul 10 '22 06:07 exodrifter

same on steam deck

Ensber avatar Jul 22 '22 16:07 Ensber

Same issue on a brand new install of Manjaro, latest nvidia graphics 515.65.01 and kernel 5.15.60-1-MANJARO.

Seems like this bug is flooding the forums, interesting...

earldbjr avatar Aug 15 '22 02:08 earldbjr

Can also confirm this problem affects both of my kubuntu gaming rigs, 22.04, 5.15.0-46-generic kernel, 510.47.03 nvidia driver.

Also affects kubuntu and manjaro on Lenovo Yoga 9i, latest updates.

The headsets have the blue light on the front, but are otherwise paperweights.

earldbjr avatar Aug 20 '22 10:08 earldbjr

Seems like everyone in this thread is using Nvidia, but I have some similar issues with Radeon 6800XT. Using Fedora 36, KDE Plasma Wayland. Kernel 5.18.18, Valve Index.

After starting up my PC and Steam:

  1. Start SteamVR -> Image shows up on the headset -> Crashes SteamVR within 10 seconds

  2. Start SteamVR again -> Image now shows up on my monitor. Close SteamVR by closing the SteamVR Status Monitor window.

  3. Repeat step 2 multiple times, same result: image only shows up on the monitor.

  4. Start SteamVR -> Image shows up on my monitor -> Go to SteamVR Status Monitor hamburger-menu -> Select Devices -> Restart Headset -> SteamVR restarts and now the image is on the headset. SteamVR Status Monitor window is now on the center of my monitor instead of the top left corner and the window cannot be moved.

  5. Select Devices -> Restart Headset -> Status Monitor window is now on the top left and image is showing up on the headset and I can play a game normally (Usually have to restart SteamVR after closing a game).

I just want to make sure that people have tried the "Devices -> Restart Headset" trick :)

wallcarpet40 avatar Aug 20 '22 13:08 wallcarpet40

As for myself there is no image on the headset, the screens arent lit up. No amount of restarting the headset via the gui, replugging all cables, or trying different ports makes a difference.

earldbjr avatar Aug 20 '22 14:08 earldbjr

As for myself there is no image on the headset, the screens arent lit up. No amount of restarting the headset via the gui, replugging all cables, or trying different ports makes a difference.

Same experience :(

YourSandwich avatar Aug 24 '22 07:08 YourSandwich

This workaround may help: https://github.com/ValveSoftware/SteamVR-for-Linux/issues/355#issuecomment-635919607

pss959 avatar Aug 24 '22 18:08 pss959

Same issue here:

System Information (please complete the following information):

Distribution: ArchLinux
SteamVR version: 1.24.7
Steam client version: Dec 15 2022
Opted into Steam client beta?: No
Graphics driver version: nvidia  525.78.01 

mwestphal avatar Jan 06 '23 18:01 mwestphal

Same exact issue on Fedora (Nobara) 37. Completely borked and will sometimes even crash my plasma session sending me back to the login.

System info: https://gist.github.com/CorneliusCornbread/b3e2c47b49e20fe09524574d68500d8d

CorneliusCornbread avatar Feb 05 '23 19:02 CorneliusCornbread

Same issue with my 7900 XTX on wayland.

bblacher avatar Feb 16 '23 16:02 bblacher

The issue is gone for me after Valve Replaced my Index Cable.

Check with lsusb and dmesg if your device is detected properly and there are no warnings like "USB might be broken"

YourSandwich avatar Feb 16 '23 18:02 YourSandwich

Same issue, GTX 1080 and a valve index

Frityet avatar Feb 20 '23 04:02 Frityet

To add onto debugging the original problem, I was able to use the Index just fine when running Windows on the same computer. So at least in my case it is likely a software issue. IIRC I also tested the 525 driver, and it failed as well.

dbgasaway avatar Feb 27 '23 04:02 dbgasaway

Same issue as others have reported with HTC Vive 1st gen Arch 6.1 Wayland wlroots RX 6700xt

minilandl avatar Mar 04 '23 10:03 minilandl

Same issue on AMD RX6900 XT Manjaro with Wayland.

Wayland is the default now. I assume that valve doesn't support it yet fully.

Reproduction:

  • Install steamvr in steam normally
  • Plug in headset
  • Direct display mode broken
  • Potato performance

I wonder what patch we need to make if its just to SDL2 to resolve it. Maybe we can inject our own SDL 2 into SteamVR or forcefully replace it with a working version.

RevoluPowered avatar Mar 07 '23 13:03 RevoluPowered

I checked the latest SDL release from today it didn't improve the situation or make it worse.

RevoluPowered avatar Mar 07 '23 13:03 RevoluPowered

So I've fixed this issue for my setup.

System Information:

  • Distribution: Arch Linux
  • WM: sway 1.8.1
  • Xwayland version: 22.1.8
  • SteamVR version: 1.25.5
  • Steam client version: This one
  • Opted into Steam client beta?: Yes
  • CPU: AMD Ryzen 9 7950X
  • GPU: AMD Radeon RX 7900 XTX
  • Graphics driver version: Mesa 22.3.6

My display setup:

  • 1920x1080p@144hz
  • 1920x1080p@60hz
  • 3840x2160p@144hz
  • Valve Index

This is just too much for my GPU to handle as of Linux 6.2.5. Using swaymsg output [output] power off I can disable the two 1920x1080p displays which results in SteamVR being able to start correctly.

I haven't tried this but it seems like the kernel branch mentioned in this comment has this issue fixed. If this is the case, Linux 6.3 would fix this issue for me without disabling the two 1920x1080p displays.

bblacher avatar Mar 12 '23 17:03 bblacher

I am still having the same issue with the 515 drivers

Would reverting drivers to <510 work?

Frityet avatar Mar 21 '23 23:03 Frityet

After much debugging, I am still having this issue.

When I lauch SteamVR, the headset display is completely off and the vrcompositor shows up on my main display (single display setup over HDMI from Radeon 5700 XT). The VR compositor reacts correctly, showing the hub world and reacting to headset motion and controllers. But the display is blank and the Index speakers don't show up as an output device on my computer (though the Index HMD mic shows up as an input). The VR Monitor has a message saying that Direct Mode is off. I enable direct mode, SteamVR starts, but nothing has changed, and the prompt to enable direct mode is still there.

This issue has been driving me crazy. Adding all the things I tried here to help debug:

  • Updated to kernel 6.3rc-3 which other people said should fix it
  • Uninstalled and reinstalled everything relevant
  • Tried a new index cable
  • Power cycled and plugged / unplugged everything

I even tried manually configuring the Index display with Xrandr, and this was the closest I got to making this work. I used the command xrandr --output DisplayPort-2 --mode 2880x1600 --rate 90.00 --set non-desktop 1 --left-of HDMI-A-0 then launched SteamVR. The headset display turned on and the VR Compositor showed up on the display! However the speakers still weren't working as an audio output device, and the framerate was very stuttery (not a performance issue), making it somewhat nauseating to use. I think this is because Direct Mode still isn't working.

System Information (please complete the following information):

Distribution: Fedora Workstation 38
SteamVR version: 1.25.7, also tried linux_v1.14
Steam client version: Mar 20, 2023 - 1679359315
Opted into Steam client beta?: Yes
Graphics driver version: Fedora Package xorg-x11-drv-amdgpu 23.0.0, 
Gist for SteamVR System Information: https://gist.github.com/IsaacFehr/be97e427d038615c875f5713aac40829

Other Info: Kernel: 6.3.0.0.rc3 Window Manager: Gnome 44.0 on Xorg GPU: AMD Radeon 5700 XT

Has anyone gotten this working on a similar setup to mine?

IsaacFehr avatar Mar 26 '23 05:03 IsaacFehr

@kisak-valve, sorry to @ you, but I haven't been able to use SteamVR on Linux for months. Is there any update on this and related issues?

IsaacFehr avatar Apr 15 '23 22:04 IsaacFehr

Hello @IsaacFehr, friendly reminder that I'm a moderator for Valve's issue trackers on Github, and not a SteamVR developer myself.

I generally don't have access to any information past what is publicly available. There is a VR test box here with an HTC Vive, Ubuntu 22.04, and an AMD RX 480. That does generally work and is used at least once per mesa update.

kisak-valve avatar Apr 15 '23 22:04 kisak-valve

I just started getting this problem intermittently again out of the blue on Garuda Dragonized. The thing is, on this distro apparently, I can tell on boot if it is going to be a problem because the login-screen will be set to some ridiculously low resolution (after logging in it'll be fine again), and the HMD will be showing as a a second screen in display settings before even starting Steam.

The solution for me here, is to shut down and turn off power to everything, wait a couple of seconds until everything is completely off (motherboards have some residual power that lets them keep going for a while), then power back on. I got everything on a power-strip so that's relatively easy.

Just rebooting is not enough apparently. Spent a whole evening troubleshooting trying reinstalling steamvr, rebooting several times to try different kernels and snapshots and whatnot without any progress. I also tried unplugging the pc-connections and rebooting to no avail. Next day I tried cutting the power, and it worked first try. It has happened a couple of times since then, with the same solution working every time.

If I were to venture an uneducated guess, I'd say there's something on the HMD-side that somehow gets it stuck in extended mode, since headset-power isn't affected by a system reboot, perhaps with some kind of "being attached to a powered pc"-component that is throwing people off. @YourSandwich said replacing the cable fixed his problem, which would include powering off the HMD completely and breaking the connection to the pc/reseating the usb/DP-plugs, perhaps with a powered off pc?

Edit: Wanted to try simulating a brief power-outage by turning my powerstrip off and on quickly (with pc shut down ofc), trying to check if perhaps I could replicate the problem working off the hypothesis that perhaps a brief power-outage during downtime that resets the headset but doesn't stay off long enough to power down the motherboard could be the culprit. Long story short: I fried my powerstrip, and the only other one I have is one of those power-saving ones with a master-plug that turns off the other plug when not active, so can't test.

Edit: Got the error again today. Soft-rebooted a bunch of times, updated, soft-rebooted some more, no dice, tried shutting down without cutting power, still no dice. Cut the power to the powerstrip where pc and hmd was plugged in, waited 15 seconds, powered on, booted up, works again first try.

Update: I seem to have fixed the problem on my end. The solution for me was to open SteamVR, open Settings --> Devices --> Restart Headset. After that the headset rebooted and started up fine in Direct Display Mode. Apparently this way of restarting the headset is not the same as the one that presents itself when clicking "Enable Direct Display Mode".

ZarathustraDK avatar May 15 '23 06:05 ZarathustraDK

Replying to https://github.com/ValveSoftware/SteamVR-for-Linux/issues/520#issuecomment-1547284784

Thanks this was the only thing that worked for me. Like you I am on Garuda and am seeing all the same symptoms.

alisonjenkins avatar May 26 '23 07:05 alisonjenkins

I encountered the issue where after a couple of reboots, my Index randomly started failing to use direct display mode. Thus, issues seem to randomly reappear and my Linux install gets very confused again, making Linux terminal and X desktop fall back to the lowest possible resolution.

Sure, it is possible to fix by navigating to SteamVR > Devices > Restart headset on the super low resolution desktop, but that is pretty inconvenient.

Would it be possible to restart the headset directly with a command and enter it in ex. .xinitrc so that the issue fixes itself automatically?


~~Edit: This might work:~~ Edit 2: The below does not work.

/usr/share/X11/xorg.conf.d/60-index-hmd.conf

# Disables the monitor if Valve Index HMD does not use direct display mode
Section "Monitor"
        Identifier "Index HMD"
        Option "ignore" "true"
EndSection

purplebar0 avatar Jun 20 '23 11:06 purplebar0