-
Notifications
You must be signed in to change notification settings - Fork 855
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
make of 5.10.60.1 fails #7558
Comments
@tyhicks - any idea? |
@tadam98 @benhillis the Microsoft Dxgkrnl driver is relying on undefined behavior in C that triggers a build failure in older GCC releases (prior to GCC 8.1). Details can be found in the upstream GCC bugzilla. Ubuntu 18.04 shipped with GCC 7.5.0. We (Microsoft) build WSL2 kernels with GCC 9.3.0 so we didn't notice this issue. A quick workaround that's only been build-tested (I can't guarantee that this works) would be:
I'll work with the author of our dxgkrnl driver to get this fixed properly for the next WSL2 kernel update. |
I have installed gcc 9.4 following the instructions at: It could be that your compilation tests did not have what I selected in the sudo make menuconfig. Thus I attached my menu config as well. The below errors also happen. See attached terminal log. Z:\home\mickey\Documents\make.log.txt (2 hits) |
Not sure how it got closed. Maybe I pressed the wrong button. |
Hey @tadam98 - The issues that you're reporting under arch/x86/kvm/hyperv.c are not reproducible using Ubuntu 18.04's GCC 7.5.0 using the production WSL2 config file. I'm unable to support patched or reconfigured kernels at this time. You could likely disable CONFIG_KVM_WERROR to workaround the problem you're seeing. We've got a fix in the works for your original report, though. :) |
CONFIG_KVM_WERROR=y is set in the original /proc/config.gz than came with the distribution. For now I am good. You can close the ticket after you decided whether CONFIG_KVM_WERROR needs to be attended. When commented as you suggested, compilation completed successfully. This is the config section from config.gz
When doing the sudo make install I got the following message:
But nvidia-smi reports the latest drivers installed in the underlying windows 11 Insider host: |
The Dxgkrnl build failure is fixed by 5.10.74.3. |
This issue has been automatically closed since it has not had any activity for the past year. If you're still experiencing this issue please re-file this as a new issue or feature request. Thank you! |
Version
Microsoft Verion 2200.258
WSL Version
Kernel Version
5.10.60.1
Distro Version
Ubuntu 18.04
Other Software
No response
Repro Steps
cd /usr/src &&
TAGVERNUM=5.10.60.1 &&
TAGVER=linux-msft-wsl-${TAGVERNUM} &&
sudo git clone -b ${TAGVER}
https://github.com/microsoft/WSL2-Linux-Kernel.git
${TAGVERNUM}-microsoft-standard &&
cd ${TAGVERNUM}-microsoft-standard
Copy in your current kernel configuration
$ sudo cp /proc/config.gz config.gz
$ sudo gunzip config.gz
$ sudo mv config .config
sudo make clean && sudo make -j 8 && sudo make modules_install -j 12 && sudo make install -j 8
Expected Behavior
no errors during make
Actual Behavior
CC drivers/md/dm-target.o
drivers/hv/dxgkrnl/dxgmodule.c:392:39: error: initializer element is not constant
const int DXGK_VMBUS_VERSION_OFFSET = DXGK_VMBUS_CHANNEL_ID_OFFSET +
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/hv/dxgkrnl/dxgmodule.c:395:41: error: initializer element is not constant
const int DXGK_VMBUS_VGPU_LUID_OFFSET = DXGK_VMBUS_VERSION_OFFSET +
^~~~~~~~~~~~~~~~~~~~~~~~~
drivers/hv/dxgkrnl/dxgmodule.c:398:41: error: initializer element is not constant
const int DXGK_VMBUS_GUESTCAPS_OFFSET = DXGK_VMBUS_VERSION_OFFSET +
^~~~~~~~~~~~~~~~~~~~~~~~~
AR drivers/vhost/built-in.a
CC fs/btrfs/ulist.o
scripts/Makefile.build:280: recipe for target 'drivers/hv/dxgkrnl/dxgmodule.o' failed
make[3]: *** [drivers/hv/dxgkrnl/dxgmodule.o] Error 1
scripts/Makefile.build:497: recipe for target 'drivers/hv/dxgkrnl' failed
make[2]: *** [drivers/hv/dxgkrnl] Error 2
scripts/Makefile.build:497: recipe for target 'drivers/hv' failed
make[1]: *** [drivers/hv] Error 2
log.txt
log.html.txt
Diagnostic Logs
No response
The text was updated successfully, but these errors were encountered: