NVIDIA / NVIDIA/open-gpu-kernel-modules

`nv_module_resources_init` tried to execute NX-protected page

Open
#765 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

NVIDIA Open GPU Kernel Modules Version

565.77

Please confirm this issue does not happen with the proprietary driver (of the same version). This issue tracker is only for bugs specific to the open kernel driver.
  • I confirm that this does not happen with the proprietary driver package.
Operating System and Version

Artix Linux

Kernel Release

Linux unknown 6.11.10-hardened1-1-hardened

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.
Hardware: GPU

Nvidia Geforce RTX 4070 (nvidia-smi don't work since driver can't load)

Describe the bug

On linux kernel 6.11.10 (and 6.12.6) (linux-hardened patches applied), built with Clang CFI and Thin LTO, the open driver tries to execute an NX page.

I was able to reproduce this on 6.12.6 but another unrelated bug make me unable to profit from any GPU.
I downgraded to 6.11.10 but issue stay the same.
This issue DO NOT happen on the official linux-hardened arch linux package compiled with GCC.

Kernel stack trace (truncated for privacy concerns, can add additional details if required):
dmesg_nvidia_open.log

To Reproduce
  • Pull up a release from https://github.com/anthraxx/linux-hardened/releases.
  • Configure kernel for using clang, enable CFI and Thin LTO.
  • Compile it and install it
  • Install NVIDIA open driver through DKMS or manually.
  • sudo modprobe nvidia
  • Should say Killed
  • dmesg will give this stack trace.
Bug Incidence

Always

nvidia-bug-report.log.gz

No point since neither nvidia driver loads, neither is it runtime feature related. Also i don't like sharing my whole PCI tree in public github.

More Info

No response

Contributor guide

Open the contributing guide

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.

Research direction

Start with the attached dmesg_nvidia_open.log and the nv_module_resources_init entry point, then reproduce with linux-hardened, Clang CFI, Thin LTO, and the NVIDIA open driver as described. Done means determining why modprobe nvidia executes an NX-protected page in that build configuration and validating the result by loading the module without the reported failure.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, linux
Domain
operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.