NVIDIA 615.71.09 DKMS build fails on Proxmox kernel 7.0.14-20/-23: incomplete type 'struct cxl_dev_state'

Open
#1,433 2 comments 2 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

  • #1438 by @theaathish — closed without merging

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
c, linux

Research direction

The failing declaration is at common/inc/nv-linux.h line 1270, guarded by NV_CXL_CXL_H_PRESENT. Compare the generated kernel-open/conftest/headers.h and functions.h, where NV_CXL_INIT_SUPPORTED is undefined, to see how the guard should depend on the functional check. Done means the DKMS build succeeds against 7.0.14-20-pve and 7.0.14-23-pve while still building on 7.0.14-19-pve.

Written by the indexing model from the issue text.

Description

build-problem
NVIDIA Open GPU Kernel Modules Version

NVIDIA Open GPU Kernel Modules 615.71.09 Debian package: nvidia-kernel-open-dkms 615.71.09-2 Installed from the official NVIDIA CUDA repository for Debian 13 (trixie), using APT/DKMS. No custom Git commit or local patches.

Operating System and Version

Debian GNU/Linux 13 (trixie) Proxmox VE: pve-manager/9.2.21/4f6e0ac86f9e8c7f. Kernel packages from the official Proxmox pve-no-subscription repository.

Kernel Release

Currently running (working): Linux pve-p520 7.0.14-19-pve #1 SMP PREEMPT_DYNAMIC PMX 7.0.14-19 (2026-09-18T07:31Z) x86_64 GNU/Linux Affected stable Proxmox kernels: - 7.0.14-20-pve - 7.0.14-23-pve Both affected kernels are official Proxmox packages, not locally compiled kernels or release candidates. The NVIDIA DKMS module builds successfully on 7.0.14-19-pve but fails to compile on both newer kernels.

Please confirm you are running a stable release kernel (e.g. not a -rc). We do not accept bug reports for unreleased kernels.
  • I am running on a stable kernel release.
Build Command

The issue occurs automatically during a standard Proxmox APT upgrade:

apt update
apt full-upgrade

The kernel package post-installation script invokes DKMS automatically:

run-parts: executing /etc/kernel/postinst.d/dkms 7.0.14-23-pve /boot/vmlinuz-7.0.14-23-pve
Autoinstall of module nvidia/615.71.09 for kernel 7.0.14-23-pve (x86_64)

DKMS then invokes:

make -j20 KERNEL_UNAME=7.0.14-23-pve IGNORE_PREEMPT_RT_PRESENCE=1 IGNORE_XEN_PRESENCE=1 modules

The same failure occurs with kernel 7.0.14-20-pve.

Terminal output/Build Log

Relevant output from /var/lib/dkms/nvidia/615.71.09/build/make.log:

././common/inc/nv-linux.h:1270:34: error: field 'cxlds' has incomplete type

This error is repeated across multiple compilation units.

DKMS reports:

Autoinstall of module nvidia/615.71.09 for kernel 7.0.14-23-pve (x86_64)
Building module(s)...............(bad exit status: 2)
Error! Bad return status for module build on kernel: 7.0.14-23-pve (x86_64)
Autoinstall on 7.0.14-23-pve failed for module(s) nvidia(10).

Generated NVIDIA conftest results:

kernel-open/conftest/headers.h:

#define NV_CXL_CXL_H_PRESENT
#undef NV_CXL_PCI_H_PRESENT

kernel-open/conftest/functions.h:

#define NV_PCIE_IS_CXL_PRESENT
#undef NV_CXL_INIT_SUPPORTED

The build fails because nv-linux.h declares a field of type struct cxl_dev_state when NV_CXL_CXL_H_PRESENT is defined, even though the required CXL API is unavailable.

More Info

The currently running 7.0.14-19-pve kernel works correctly with the NVIDIA 615.71.09 driver and RTX A4000 GPU. The failure is reproducible during DKMS compilation against both newer kernel header versions, without booting those kernels.

Suspected root cause: CXL header-presence detection enables code requiring an unavailable CXL API

I investigated the difference between the working Proxmox kernel 7.0.14-19-pve and the failing kernels 7.0.14-20-pve and 7.0.14-23-pve.

The only difference found when comparing the include/cxl/ header directories between -19 and -20 is the addition of:

include/cxl/cxl.h

The new header contains only the declaration of cxl_region_contains_resource() (and its fallback implementation). It does not define struct cxl_dev_state.

On kernel 7.0.14-19-pve (working)
  • include/cxl/cxl.h is absent.
  • NVIDIA does not define NV_CXL_CXL_H_PRESENT.
  • The NVIDIA DKMS module builds successfully.
On kernels 7.0.14-20-pve and 7.0.14-23-pve (failing)
  • include/cxl/cxl.h exists.
  • NVIDIA defines NV_CXL_CXL_H_PRESENT.
  • NVIDIA correctly reports #undef NV_CXL_INIT_SUPPORTED.
  • However, common/inc/nv-linux.h still enables code containing struct cxl_dev_state cxlds.
  • Compilation fails because struct cxl_dev_state is incomplete.

The relevant declaration is at common/inc/nv-linux.h:1270.

The generated NVIDIA conftest results confirm:

kernel-open/conftest/headers.h:

#define NV_CXL_CXL_H_PRESENT
#undef NV_CXL_PCI_H_PRESENT

kernel-open/conftest/functions.h:

#define NV_PCIE_IS_CXL_PRESENT
#undef NV_CXL_INIT_SUPPORTED

The cxl_init_supported conftest appears to correctly detect the missing API, but the affected declaration is guarded by NV_CXL_CXL_H_PRESENT rather than the functional capability test.

This suggests that the declaration in nv-linux.h should also be conditional on NV_CXL_INIT_SUPPORTED, or otherwise guarded by a more specific API compatibility check.

Expected behavior

When the CXL API required by NVIDIA is unavailable, CXL-specific declarations should be disabled so the driver can compile successfully.

Actual behavior

The presence of a cxl/cxl.h header that does not provide the required CXL API activates incompatible CXL code, causing DKMS compilation to fail:

././common/inc/nv-linux.h:1270:34: error: field 'cxlds' has incomplete type
Hardware
  • GPU: NVIDIA RTX A4000 (16 GB)
  • CPU: Intel Xeon W-2255
  • System: Lenovo ThinkStation P520
  • Architecture: x86_64
  • OS: Debian GNU/Linux 13 (trixie)
  • Hypervisor: Proxmox VE 9.2.21
  • NVIDIA package: nvidia-kernel-open-dkms 615.71.09-2

No local patches have been applied to the NVIDIA driver or kernel sources.

Dominant language
C
Stars
17.5k
Forks
1.9k
PR merge metrics
No merged PRs in 30d

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from NVIDIA/open-gpu-kernel-modules

All issues in NVIDIA/open-gpu-kernel-modules

Similar issues

More C issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.