WSL icon indicating copy to clipboard operation
WSL copied to clipboard

WSL 2: Enabling 'Virtual Machine Platform' feature causes AMD Radeon driver to fail to load

Open pd5rm opened this issue 6 years ago • 65 comments

Environment

Windows build number: Microsoft Windows [Version 10.0.19041.388]
Your Distribution version: Ubuntu (but doesn't matter, since it's Windows/AMD issue).
Whether the issue is on WSL 2 and/or WSL 1: WSL 2

Additional graphics related details (this is relevant, see below):

AMD Driver): 20.7.2 (7/11/2020 release date)
My BIOS 'UMA Frame buffer' is set to auto (other options available are 256MB and 512MB).
Note my graphics chipset is onboard/integrated and not a dedicated card.

System

HP EliteDesk 705 G5

Steps to reproduce

  1. Install the 'Virtual Machine Platform' features, following steps here to install WSL 2.
  2. Reboot machine.
  3. Observe that resolutions seems odd (lower)
  4. Open Device manage, and notice that AMD Driver fails with: Windows has stopped this device because it has reported problems. (Code 43)
  5. Open WSL 2 based distro (Ubuntu), and verify that it works.
  6. Disable 'Virtual Machine Platform'
  7. Reboot.
  8. Observe that resolution is restored to normal, and AMD driver loads successfully.
  9. WSL 2 image no longer work. WSL 1 based image works fine.

Expected behavior

I would like to run WSL 2 based Linux and be able to run my native graphic card driver. ;-)

Actual behavior

Some conflict occurs between the Virtual Machine Platform feature and AMD drivers.

I'd like to know whether this is a Window or AMD issue, so I can followup for support accordingly. Any other logs/debugging I can gather or provide?

pd5rm avatar Jul 27 '20 22:07 pd5rm

Running Acer Nitro 5 AN515-43 here. I can't replicate this issue probably because the driver/GPU supports virtual GPUs via DirectX

sr229 avatar Aug 12 '20 01:08 sr229

I have the exact same issue as documented. My CPU is ryzen 5 pro 2400ge with Vega 11 integrated graphics.

linuxbliss avatar Aug 12 '20 12:08 linuxbliss

I would like to report same issue on HP Elitebook 745 G5 with latest available GPU drivers from vendor (9/9/2020 / 27.20.11023.9002).

Applies to: Windows Pro 2004 19041.572, Windows Pro 20H2 19042.630

Once you turn on the Virtual Machine Platform feature, and reboot the system.

dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart
Restart-Computer

The GPU drivers for Vega 8 will be stopped with the following message Windows has stopped this device because it has reported problems. (Code 43)

The rollback is disabling the above feature and restarting the system back to original state. Personally, I don't think this is a WSL2 issue, rather than Hyper-V one.

maroskukan avatar Aug 21 '20 21:08 maroskukan

Same issue found on HP Elitebook 745 G6 with AMD Ryzen 5 PRO 3500U + Radeon Vega Mobile

enalbert avatar Sep 14 '20 15:09 enalbert

Enabling SVM and disabling IOMMU in BIOS settings has solved the issue. AMD Ryzen 5 2400G

https://www.reddit.com/r/AMDHelp/comments/byaa8l/bootlopp_when_hyperv_and_amd_ryzensvm_enabled/

tamuratak avatar Sep 17 '20 05:09 tamuratak

Same issue found on HP Elitebook 755 G5 (Ryzen 7).

Disabling SVM has solved the issue but VirtualBox is KO. No IOMMU option in BIOS settings in my laptop.

So sad.... :(

chemoms avatar Sep 17 '20 08:09 chemoms

SVM is enabled (at least on my desktop HP 705). There's no ability to disable IOMMU from my BIOS. This seems like a HP BIOS specific issue. I suspect I can could disable onboard video and install a video card to make this problem go away, however laptop users don't have that option obviously.

Note that I spotted a forum post (with no responses/solutions) with similar issues posted back in April 2020.

@tamuratak Can you tell me what make/model of your system is?

Just for fun I 'disabled' SVM as well (thinking perhaps the option was working in opposite way). I noticed that the Window features seems to detect this when displaying the HyperV options (they're greyed out). SVM-Disabled SVM-Enabled

pd5rm avatar Sep 19 '20 21:09 pd5rm

Have an issue with Ryzen 5 mobile 2500u with vega 8 graphics. When I install either Hyper V or Virtual Machine Platform, I cannot even launch visual studio code or windows terminal because they use gpu acceleration :) So it looks like the driver is failing. When I uninstall Cirtual Machine Platform, it works again, but no WSL 2 ...

remisharrock avatar Nov 08 '20 20:11 remisharrock

I had the same issue with my HP EliteBook 755 G5 with AMD Ryzen 7 PRO 2700U w/ Radeon Vega Mobile Gfx on Windows version 2004. The issue has fixed somehow by updating Windows to version 20H2. I suggest you give it a try 🤞

shpark0603 avatar Nov 09 '20 04:11 shpark0603

I had the same issue with my HP EliteBook 755 G5 with AMD Ryzen 7 PRO 2700U w/ Radeon Vega Mobile Gfx on Windows version 2004. The issue has fixed somehow by updating Windows to version 20H2. I suggest you give it a try 🤞

Well, on windows 20H2 that I just tried, still have the same issue with windows terminal and visual studio code ... so until it is fixed I don't use WSL but virtualbox instead...

remisharrock avatar Nov 09 '20 09:11 remisharrock

You can try code --disable-gpu. See https://code.visualstudio.com/docs/supporting/FAQ#_vs-code-is-blank

tamuratak avatar Nov 10 '20 11:11 tamuratak

You can try code --disable-gpu. See https://code.visualstudio.com/docs/supporting/FAQ#_vs-code-is-blank

yes it works. But still I have GPU acceleration off everywhere, for example in chrome/edge :

when I go to edge://gpu/ here is the result:

Graphics Feature Status Canvas: Software only, hardware acceleration unavailable Compositing: Software only. Hardware acceleration disabled Multiple Raster Threads: Enabled Out-of-process Rasterization: Disabled OpenGL: Disabled Hardware Protected Video Decode: Disabled Rasterization: Software only. Hardware acceleration disabled Skia Renderer: Disabled Video Decode: Software only. Hardware acceleration disabled Vulkan: Disabled WebGL: Software only, hardware acceleration unavailable WebGL2: Software only, hardware acceleration unavailable

I sent a bug report to AMD, maybe that will help ... I don't know if it is a "windows" problem or a "AMD driver" problem...

PS: disabling virtual machine platform re-enables the hardware acceleration:

Canvas: Hardware accelerated Compositing: Hardware accelerated Multiple Raster Threads: Enabled Out-of-process Rasterization: Hardware accelerated OpenGL: Enabled Hardware Protected Video Decode: Hardware accelerated Rasterization: Hardware accelerated Skia Renderer: Disabled Video Decode: Hardware accelerated Vulkan: Disabled WebGL: Hardware accelerated WebGL2: Hardware accelerated

my system (hardware and software details) are here https://0bin.net/paste/tvDUAO2+#yA9dvkIxXpvaqkzdLpj+dwaJxkehwVB6zi4eftCBOEm

remisharrock avatar Nov 13 '20 21:11 remisharrock

For those of you with HP systems having this issue, do you have the systems set to "Legacy Support Enable and Secure Boot Disable" (BIOS F10 > Advanced > Secure Boot Configuration). If so try changing to "Legacy Support Disable and Secure Boot Enable" or "Legacy Support Disable and Secure Boot Disable".

I can only reproduce the issue on an HP EliteBook 745 G5 and 745 G6 when set to Legacy Support Enable and Secure Boot Disable. When set to "Legacy Support Disable and Secure Boot Enable" or "Legacy Support Disable and Secure Boot Disable" I do not see the issue. As long as your Windows install is using UEFI you should be able to switch without having to reinstall Windows. If you do have bit locker enabled make sure to suspend or disable before making the change.

uastack avatar Nov 23 '20 20:11 uastack

@uastack , I tried to do the legacy boot thing, it did not work, it still resulted in BSOD.

pankaj-nikam avatar Dec 03 '20 13:12 pankaj-nikam

@pankaj-nikam To be clear you do not want legacy boot. You want "Legacy Support Disable and Secure Boot Disable" or "Legacy Support Disable and Secure Boot Enable".

A BSOD is different then the issue initially reported in this thread. The issue initially reported and the one I was able to reproduce is that when Virtual Machine Platform is enabled AMD Radeon Graphics fails to load showing, Windows has stopped this device because it has reported problems. (Code 43) For a BSOD make sure BIOS and drivers are up to date.
Which platform are you using?

uastack avatar Dec 05 '20 02:12 uastack

Hi @uastack, I tried either way, it does not work. When I enable "Virtualization Platform", it results into BSOD with HP Laptop (Ryzen 4600H) and 24 GB RAM. The drivers and BIOS are up to date as per HP site. If I install non OEM drivers, it results into slow booting.

pankaj-nikam avatar Dec 05 '20 07:12 pankaj-nikam

@pankaj-nikam sorry to hear this did not work. Is this an Omen 15z? When you say you have an HP system with a 4600H that leads me to thinking you also have an Nvidia discrete card. My 2 cents on a few things to try: Use DDU to fully remove both the AMD and Nvidia graphics drivers. With no graphics drivers installed enable Virtual Machine Platform, do you still get a BSOD? If you do get a BSOD then there is something beyond the graphics drivers causing the issue most likely. If you do not get a BSOD with no graphics driver installed then try disabling Virtual Machine Platform. After Virtual Machine Platform is disabled Install the AMD graphics driver. Once the AMD graphics driver is fully installed and you have rebooted, enable Virtual Machine Platform. If you get a BSOD then I would try removing the AMD driver and try the latest from AMD https://www.amd.com/en/support/apu/amd-ryzen-processors/amd-ryzen-5-mobile-processors-radeon-graphics/amd-ryzen-5-4600h. If you do not get a BSOD with just the AMD graphics driver then I would move on to testing Nvidia drivers.

uastack avatar Dec 06 '20 00:12 uastack

Hi @uastack, so far, I have tried the following: A. Uninstalled both AMD and Nvidia drivers using DDU in safe mode (Didnt knew what ddu is till now, thanks for that) B. Enabled virtualization platform it works without any drivers. I will update this post after installing AMD drivers. Edit 1: I uninstalled the virtualization platform and then installed AMD drivers from HP website. Then I enabled the virtualization platform. Surprisingly it worked! I guess DDU removed some old unwanted junk from the driver repository which caused the issue. I am proceeding with installing the Nvidia drivers and will update this post. Edit 2: I installed the Nvidia drivers and it does not result in BSOD. My previous guess may be correct - old drivers must be present and may be causing issues. DDU is a great tool to uninstall it. I used it with following options:

image

pankaj-nikam avatar Dec 06 '20 02:12 pankaj-nikam

@pankaj-nikam glad to hear it worked and you are up and running!

uastack avatar Dec 06 '20 04:12 uastack

@uastack Thank you so much for your input, I forgot to mention my model number in previous post, it is HP Pavilion - 15-ec1051ax.

pankaj-nikam avatar Dec 06 '20 04:12 pankaj-nikam