MCPcopy Index your code
hub / github.com/NVIDIA/open-gpu-kernel-modules

github.com/NVIDIA/open-gpu-kernel-modules @610.43.02

Chat with this repo
repository ↗ · DeepWiki ↗ · release 610.43.02 ↗ · + Follow
57,350 symbols 141,185 edges 3,811 files 13,100 documented · 23%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

NVIDIA Linux Open GPU Kernel Module Source

This is the source release of the NVIDIA Linux open GPU kernel modules, version 610.43.02.

How to Build

To build:

make modules -j$(nproc)

To install, first uninstall any existing NVIDIA kernel modules. Then, as root:

make modules_install -j$(nproc)

Note that the kernel modules built here must be used with GSP firmware and user-space NVIDIA GPU driver components from a corresponding 610.43.02 driver release. This can be achieved by installing the NVIDIA GPU driver from the .run file using the --no-kernel-modules option. E.g.,

sh ./NVIDIA-Linux-[...].run --no-kernel-modules

Supported Target CPU Architectures

Currently, the kernel modules can be built for x86_64 or aarch64. If cross-compiling, set these variables on the make command line:

TARGET_ARCH=aarch64|x86_64
CC
LD
AR
CXX
OBJCOPY

E.g.,

# compile on x86_64 for aarch64
make modules -j$(nproc)         \
    TARGET_ARCH=aarch64         \
    CC=aarch64-linux-gnu-gcc    \
    LD=aarch64-linux-gnu-ld     \
    AR=aarch64-linux-gnu-ar     \
    CXX=aarch64-linux-gnu-g++   \
    OBJCOPY=aarch64-linux-gnu-objcopy

Other Build Knobs

NV_VERBOSE - Set this to "1" to print each complete command executed; otherwise, a succinct "CC" line is printed.

DEBUG - Set this to "1" to build the kernel modules as debug. By default, the build compiles without debugging information. This also enables various debug log messages in the kernel modules.

These variables can be set on the make command line. E.g.,

make modules -j$(nproc) NV_VERBOSE=1

Supported Toolchains

Any reasonably modern version of GCC or Clang can be used to build the kernel modules. Note that the kernel interface layers of the kernel modules must be built with the toolchain that was used to build the kernel.

Supported Linux Kernel Versions

The NVIDIA open kernel modules support the same range of Linux kernel versions that are supported with the proprietary NVIDIA kernel modules. This is currently Linux kernel 4.15 or newer.

How to Contribute

Contributions can be made by creating a pull request on https://github.com/NVIDIA/open-gpu-kernel-modules We'll respond via GitHub.

Note that when submitting a pull request, you will be prompted to accept a Contributor License Agreement.

This code base is shared with NVIDIA's proprietary drivers, and various processing is performed on the shared code to produce the source code that is published here. This has several implications for the foreseeable future:

  • The GitHub repository will function mostly as a snapshot of each driver release.

  • We do not expect to be able to provide revision history for individual changes that were made to NVIDIA's shared code base. There will likely only be one git commit per driver release.

  • We may not be able to reflect individual contributions as separate git commits in the GitHub repository.

  • Because the code undergoes various processing prior to publishing here, contributions made here require manual merging to be applied to the shared code base. Therefore, large refactoring changes made here may be difficult to merge and accept back into the shared code base. If you have large refactoring to suggest, please contact us in advance, so we can coordinate.

How to Report Issues

Problems specific to the Open GPU Kernel Modules can be reported in the Issues section of the https://github.com/NVIDIA/open-gpu-kernel-modules repository.

Further, any of the existing bug reporting venues can be used to communicate problems to NVIDIA, such as our forum:

https://forums.developer.nvidia.com/c/gpu-graphics/linux/148

or linux-bugs@nvidia.com.

Please see the 'NVIDIA Contact Info and Additional Resources' section of the NVIDIA GPU Driver README for details.

Please see the separate SECURITY.md document if you believe you have discovered a security vulnerability in this software.

Kernel Interface and OS-Agnostic Components of Kernel Modules

Most of NVIDIA's kernel modules are split into two components:

  • An "OS-agnostic" component: this is the component of each kernel module that is independent of operating system.

  • A "kernel interface layer": this is the component of each kernel module that is specific to the Linux kernel version and configuration.

When packaged in the NVIDIA .run installation package, the OS-agnostic component is provided as a binary: it is large and time-consuming to compile, so pre-built versions are provided so that the user does not have to compile it during every driver installation. For the nvidia.ko kernel module, this component is named "nv-kernel.o_binary". For the nvidia-modeset.ko kernel module, this component is named "nv-modeset-kernel.o_binary". Neither nvidia-drm.ko nor nvidia-uvm.ko have OS-agnostic components.

The kernel interface layer component for each kernel module must be built for the target kernel.

Directory Structure Layout

  • kernel-open/ The kernel interface layer
  • kernel-open/nvidia/ The kernel interface layer for nvidia.ko
  • kernel-open/nvidia-drm/ The kernel interface layer for nvidia-drm.ko
  • kernel-open/nvidia-modeset/ The kernel interface layer for nvidia-modeset.ko
  • kernel-open/nvidia-uvm/ The kernel interface layer for nvidia-uvm.ko

  • src/ The OS-agnostic code

  • src/nvidia/ The OS-agnostic code for nvidia.ko
  • src/nvidia-modeset/ The OS-agnostic code for nvidia-modeset.ko
  • src/common/ Utility code used by one or more of nvidia.ko and nvidia-modeset.ko
  • nouveau/ Tools for integration with the Nouveau device driver

Nouveau device driver integration

The Python script in the 'nouveau' directory is used to extract some of the firmware binary images (and related data) encoded in the source code and store them as distinct files. These files are used by the Nouveau device driver to load and communicate with the GSP firmware.

The layout of the binary files is described in nouveau_firmware_layout.ods, which is an OpenDocument Spreadsheet file, compatible with most spreadsheet software applications.

Compatible GPUs

The NVIDIA open kernel modules can be used on any Turing or later GPU (see the table below).

For details on feature support and limitations, see the NVIDIA GPU driver end user README here:

https://us.download.nvidia.com/XFree86/Linux-x86_64/610.43.02/README/kernel_open.html

For vGPU support, please refer to the README.vgpu packaged in the vGPU Host Package for more details.

In the below table, if three IDs are listed, the first is the PCI Device ID, the second is the PCI Subsystem Vendor ID, and the third is the PCI Subsystem Device ID.

Product Name PCI ID
NVIDIA TITAN RTX 1E02
NVIDIA GeForce RTX 2080 Ti 1E04
NVIDIA GeForce RTX 2080 Ti 1E07
NVIDIA CMP 50HX 1E09
Quadro RTX 6000 1E30
Quadro RTX 8000 1E30 1028 129E
Quadro RTX 8000 1E30 103C 129E
Quadro RTX 8000 1E30 10DE 129E
Quadro RTX 6000 1E36
Quadro RTX 8000 1E78 10DE 13D8
Quadro RTX 6000 1E78 10DE 13D9
NVIDIA GeForce RTX 2080 SUPER 1E81
NVIDIA GeForce RTX 2080 1E82
NVIDIA GeForce RTX 2070 SUPER 1E84
NVIDIA GeForce RTX 2080 1E87
NVIDIA GeForce RTX 2060 1E89
NVIDIA GeForce RTX 2080 1E90
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1025 1375
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1028 08A1
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1028 08A2
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1028 08EA
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1028 08EB
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1028 08EC
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1028 08ED
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1028 08EE
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1028 08EF
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1028 093B
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1028 093C
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 103C 8572
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 103C 8573
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 103C 8602
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 103C 8606
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 103C 86C6
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 103C 86C7
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 103C 87A6
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 103C 87A7
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1043 131F
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1043 137F
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1043 141F
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1043 1751
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1458 1660
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1458 1661
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1458 1662
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1458 75A6
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1458 75A7
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1458 86A6
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1458 86A7
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1462 1274
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1462 1277
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 152D 1220
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1558 95E1
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1558 97E1
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1A58 2002
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1A58 2005
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1A58 2007
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1A58 3000
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1A58 3001
NVIDIA GeForce RTX 2080 with Max-Q Design 1E90 1D05 1069
NVIDIA GeForce RTX 2070 Super 1E91
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 103C 8607
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 103C 8736
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 103C 8738
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 103C 8772
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 103C 878A
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 103C 878B
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1043 1E61
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1458 1511
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1458 75B3
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1458 75B4
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1458 76B2
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1458 76B3
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1458 78A2
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1458 78A3
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1458 86B2
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1458 86B3
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1462 12AE
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1462 12B0
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1462 12C6
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 17AA 22C3
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 17AA 22C5
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1A58 2009
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1A58 200A
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 1A58 3002
NVIDIA GeForce RTX 2070 Super with Max-Q Design 1E91 8086 3012
NVIDIA GeForce RTX 2080 Super 1E93
NVIDIA GeForce RTX 2080 Super with Max-Q Design 1E93 1025 1401
NVIDIA GeForce RTX 2080 Super with Max-Q Design 1E93 1025 149C
NVIDIA GeForce RTX 2080 Super with Max-Q Design 1E93 1028 09D2
NVIDIA GeForce RTX 2080 Super with Max-Q Design 1E93 103C 8607
NVIDIA GeForce RTX 2080 Super with Max-Q Design 1E93 103C 86C7
NVIDIA GeForce RTX 2080 Super with Max-

Core symbols most depended-on inside this repo

portMemSet
called by 1513
src/nvidia/src/libraries/nvport/memory/memory_generic.h
portMemFree
called by 1068
src/nvidia/src/libraries/nvport/memory/memory_tracking.c
portMemAllocNonPaged
called by 767
src/nvidia/src/libraries/nvport/memory/memory_tracking.c
portMemCopy
called by 699
src/nvidia/src/libraries/nvport/memory/memory_generic.h
nv_printf
called by 521
kernel-open/nvidia/os-interface.c
nvswitch_test_flags
called by 448
src/common/nvswitch/kernel/inc/common_nvswitch.h
nvswitch_clear_flags
called by 408
src/common/nvswitch/kernel/inc/common_nvswitch.h
finn_read_buffer
called by 338
src/nvidia/interface/rmapi/src/g_finn_rm_api.c

Shape

Function 39,458
Class 15,884
Method 1,221
Enum 787

Languages

C55%
C++45%
Python1%

Modules by API surface

src/nvidia/generated/g_subdevice_nvoc.h789 symbols
src/nvidia/generated/g_subdevice_nvoc.c700 symbols
src/nvidia/generated/g_gpu_nvoc.h629 symbols
src/nvidia-modeset/interface/nvkms-api.h530 symbols
src/nvidia/generated/g_sdk-structures.h476 symbols
src/nvidia/generated/g_rpc-structures.h437 symbols
src/nvidia/generated/g_disp_objs_nvoc.h407 symbols
src/nvidia/generated/g_mem_mgr_nvoc.h397 symbols
src/nvidia/generated/g_kern_gmmu_nvoc.h379 symbols
src/nvidia/generated/g_kern_bus_nvoc.h379 symbols
src/nvidia/generated/g_disp_objs_nvoc.c346 symbols
src/nvidia/generated/g_kernel_fifo_nvoc.h321 symbols

For agents

$ claude mcp add open-gpu-kernel-modules \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact