Skip to content

Commit b5bf85a

Browse files
committed
545.23.06
1 parent f59818b commit b5bf85a

File tree

917 files changed

+132395
-109930
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

917 files changed

+132395
-109930
lines changed

CHANGELOG.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,17 @@
11
# Changelog
22

3+
## Release 545 Entries
4+
5+
### [545.23.06] 2023-10-17
6+
7+
#### Fixed
8+
9+
- Fix always-false conditional, [#493](https://github.com/NVIDIA/open-gpu-kernel-modules/pull/493) by @meme8383
10+
11+
#### Added
12+
13+
- Added beta-quality support for GeForce and Workstation GPUs. Please see the "Open Linux Kernel Modules" chapter in the NVIDIA GPU driver end user README for details.
14+
315
## Release 535 Entries
416

517
### [535.113.01] 2023-09-21

README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# NVIDIA Linux Open GPU Kernel Module Source
22

33
This is the source release of the NVIDIA Linux open GPU kernel modules,
4-
version 535.113.01.
4+
version 545.23.06.
55

66

77
## How to Build
@@ -17,7 +17,7 @@ as root:
1717

1818
Note that the kernel modules built here must be used with GSP
1919
firmware and user-space NVIDIA GPU driver components from a corresponding
20-
535.113.01 driver release. This can be achieved by installing
20+
545.23.06 driver release. This can be achieved by installing
2121
the NVIDIA GPU driver from the .run file using the `--no-kernel-modules`
2222
option. E.g.,
2323

@@ -179,16 +179,16 @@ software applications.
179179

180180
## Compatible GPUs
181181

182-
The open-gpu-kernel-modules can be used on any Turing or later GPU
183-
(see the table below). However, in the 535.113.01 release,
184-
GeForce and Workstation support is still considered alpha-quality.
182+
The NVIDIA open kernel modules can be used on any Turing or later GPU
183+
(see the table below). However, in the __DRIVER_VERION__ release, GeForce and
184+
Workstation support is considered to be Beta quality. The open kernel modules
185+
are suitable for broad usage, and NVIDIA requests feedback on any issues
186+
encountered specific to them.
185187

186-
To enable use of the open kernel modules on GeForce and Workstation GPUs,
187-
set the "NVreg_OpenRmEnableUnsupportedGpus" nvidia.ko kernel module
188-
parameter to 1. For more details, see the NVIDIA GPU driver end user
189-
README here:
188+
For details on feature support and limitations, see the NVIDIA GPU driver
189+
end user README here:
190190

191-
https://us.download.nvidia.com/XFree86/Linux-x86_64/535.113.01/README/kernel_open.html
191+
https://us.download.nvidia.com/XFree86/Linux-x86_64/545.23.06/README/kernel_open.html
192192

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

kernel-open/Kbuild

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,12 +72,24 @@ EXTRA_CFLAGS += -I$(src)/common/inc
7272
EXTRA_CFLAGS += -I$(src)
7373
EXTRA_CFLAGS += -Wall $(DEFINES) $(INCLUDES) -Wno-cast-qual -Wno-error -Wno-format-extra-args
7474
EXTRA_CFLAGS += -D__KERNEL__ -DMODULE -DNVRM
75-
EXTRA_CFLAGS += -DNV_VERSION_STRING=\"535.113.01\"
75+
EXTRA_CFLAGS += -DNV_VERSION_STRING=\"545.23.06\"
7676

7777
ifneq ($(SYSSRCHOST1X),)
7878
EXTRA_CFLAGS += -I$(SYSSRCHOST1X)
7979
endif
8080

81+
# Some Android kernels prohibit driver use of filesystem functions like
82+
# filp_open() and kernel_read(). Disable the NV_FILESYSTEM_ACCESS_AVAILABLE
83+
# functionality that uses those functions when building for Android.
84+
85+
PLATFORM_IS_ANDROID ?= 0
86+
87+
ifeq ($(PLATFORM_IS_ANDROID),1)
88+
EXTRA_CFLAGS += -DNV_FILESYSTEM_ACCESS_AVAILABLE=0
89+
else
90+
EXTRA_CFLAGS += -DNV_FILESYSTEM_ACCESS_AVAILABLE=1
91+
endif
92+
8193
EXTRA_CFLAGS += -Wno-unused-function
8294

8395
ifneq ($(NV_BUILD_TYPE),debug)
@@ -92,7 +104,6 @@ endif
92104

93105
ifeq ($(NV_BUILD_TYPE),debug)
94106
EXTRA_CFLAGS += -g
95-
EXTRA_CFLAGS += $(call cc-option,-gsplit-dwarf,)
96107
endif
97108

98109
EXTRA_CFLAGS += -ffreestanding
@@ -214,6 +225,7 @@ $(obj)/conftest/patches.h: $(NV_CONFTEST_SCRIPT)
214225
NV_HEADER_PRESENCE_TESTS = \
215226
asm/system.h \
216227
drm/drmP.h \
228+
drm/drm_aperture.h \
217229
drm/drm_auth.h \
218230
drm/drm_gem.h \
219231
drm/drm_crtc.h \
@@ -224,6 +236,7 @@ NV_HEADER_PRESENCE_TESTS = \
224236
drm/drm_encoder.h \
225237
drm/drm_atomic_uapi.h \
226238
drm/drm_drv.h \
239+
drm/drm_fbdev_generic.h \
227240
drm/drm_framebuffer.h \
228241
drm/drm_connector.h \
229242
drm/drm_probe_helper.h \
@@ -257,6 +270,7 @@ NV_HEADER_PRESENCE_TESTS = \
257270
linux/sched/task_stack.h \
258271
xen/ioemu.h \
259272
linux/fence.h \
273+
linux/dma-fence.h \
260274
linux/dma-resv.h \
261275
soc/tegra/chip-id.h \
262276
soc/tegra/fuse.h \
@@ -302,6 +316,7 @@ NV_HEADER_PRESENCE_TESTS = \
302316
linux/mdev.h \
303317
soc/tegra/bpmp-abi.h \
304318
soc/tegra/bpmp.h \
319+
linux/sync_file.h \
305320
linux/cc_platform.h \
306321
asm/cpufeature.h
307322

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
/*
2+
* SPDX-FileCopyrightText: Copyright (c) 2023 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
3+
* SPDX-License-Identifier: MIT
4+
*
5+
* Permission is hereby granted, free of charge, to any person obtaining a
6+
* copy of this software and associated documentation files (the "Software"),
7+
* to deal in the Software without restriction, including without limitation
8+
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
9+
* and/or sell copies of the Software, and to permit persons to whom the
10+
* Software is furnished to do so, subject to the following conditions:
11+
*
12+
* The above copyright notice and this permission notice shall be included in
13+
* all copies or substantial portions of the Software.
14+
*
15+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
18+
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
20+
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
21+
* DEALINGS IN THE SOFTWARE.
22+
*/
23+
24+
25+
#ifndef _NV_CHARDEV_NUMBERS_H_
26+
#define _NV_CHARDEV_NUMBERS_H_
27+
28+
// NVIDIA's reserved major character device number (Linux).
29+
#define NV_MAJOR_DEVICE_NUMBER 195
30+
31+
// Minor numbers 0 to 247 reserved for regular devices
32+
#define NV_MINOR_DEVICE_NUMBER_REGULAR_MAX 247
33+
34+
// Minor numbers 248 to 253 currently unused
35+
36+
// Minor number 254 reserved for the modeset device (provided by NVKMS)
37+
#define NV_MINOR_DEVICE_NUMBER_MODESET_DEVICE 254
38+
39+
// Minor number 255 reserved for the control device
40+
#define NV_MINOR_DEVICE_NUMBER_CONTROL_DEVICE 255
41+
42+
#endif // _NV_CHARDEV_NUMBERS_H_
43+

kernel-open/common/inc/nv-ioctl-numa.h

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,12 @@
2525
#ifndef NV_IOCTL_NUMA_H
2626
#define NV_IOCTL_NUMA_H
2727

28-
#if defined(NV_LINUX)
29-
3028
#include <nv-ioctl-numbers.h>
3129

32-
#if defined(NV_KERNEL_INTERFACE_LAYER)
33-
30+
#if defined(NV_KERNEL_INTERFACE_LAYER) && defined(NV_LINUX)
3431
#include <linux/types.h>
35-
32+
#elif defined (NV_KERNEL_INTERFACE_LAYER) && defined(NV_BSD)
33+
#include <sys/stdint.h>
3634
#else
3735

3836
#include <stdint.h>
@@ -81,5 +79,3 @@ typedef struct nv_ioctl_set_numa_status
8179
#define NV_IOCTL_NUMA_STATUS_OFFLINE_FAILED 6
8280

8381
#endif
84-
85-
#endif
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* SPDX-FileCopyrightText: Copyright (c) 2012-2013 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
2+
* SPDX-FileCopyrightText: Copyright (c) 2016 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
33
* SPDX-License-Identifier: MIT
44
*
55
* Permission is hereby granted, free of charge, to any person obtaining a
@@ -21,27 +21,42 @@
2121
* DEALINGS IN THE SOFTWARE.
2222
*/
2323

24-
#ifndef _NV_FRONTEND_H_
25-
#define _NV_FRONTEND_H_
24+
#ifndef __NV_KTHREAD_QUEUE_OS_H__
25+
#define __NV_KTHREAD_QUEUE_OS_H__
2626

27-
#include "nvtypes.h"
28-
#include "nv-linux.h"
29-
#include "nv-register-module.h"
27+
#include <linux/types.h> // atomic_t
28+
#include <linux/list.h> // list
29+
#include <linux/sched.h> // task_struct
30+
#include <linux/numa.h> // NUMA_NO_NODE
31+
#include <linux/semaphore.h>
3032

31-
#define NV_MAX_MODULE_INSTANCES 8
33+
#include "conftest.h"
3234

33-
#define NV_FRONTEND_MINOR_NUMBER(x) minor((x)->i_rdev)
35+
struct nv_kthread_q
36+
{
37+
struct list_head q_list_head;
38+
spinlock_t q_lock;
3439

35-
#define NV_FRONTEND_CONTROL_DEVICE_MINOR_MAX 255
36-
#define NV_FRONTEND_CONTROL_DEVICE_MINOR_MIN (NV_FRONTEND_CONTROL_DEVICE_MINOR_MAX - \
37-
NV_MAX_MODULE_INSTANCES)
40+
// This is a counting semaphore. It gets incremented and decremented
41+
// exactly once for each item that is added to the queue.
42+
struct semaphore q_sem;
43+
atomic_t main_loop_should_exit;
3844

39-
#define NV_FRONTEND_IS_CONTROL_DEVICE(x) ((x <= NV_FRONTEND_CONTROL_DEVICE_MINOR_MAX) && \
40-
(x > NV_FRONTEND_CONTROL_DEVICE_MINOR_MIN))
45+
struct task_struct *q_kthread;
46+
};
4147

42-
int nvidia_frontend_add_device(nvidia_module_t *, nv_linux_state_t *);
43-
int nvidia_frontend_remove_device(nvidia_module_t *, nv_linux_state_t *);
48+
struct nv_kthread_q_item
49+
{
50+
struct list_head q_list_node;
51+
nv_q_func_t function_to_run;
52+
void *function_args;
53+
};
4454

45-
extern nvidia_module_t *nv_minor_num_table[];
55+
56+
#ifndef NUMA_NO_NODE
57+
#define NUMA_NO_NODE (-1)
58+
#endif
59+
60+
#define NV_KTHREAD_NO_NODE NUMA_NO_NODE
4661

4762
#endif

kernel-open/common/inc/nv-kthread-q.h

Lines changed: 8 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,14 @@
2424
#ifndef __NV_KTHREAD_QUEUE_H__
2525
#define __NV_KTHREAD_QUEUE_H__
2626

27-
#include <linux/types.h> // atomic_t
28-
#include <linux/list.h> // list
29-
#include <linux/sched.h> // task_struct
30-
#include <linux/numa.h> // NUMA_NO_NODE
31-
#include <linux/semaphore.h>
27+
struct nv_kthread_q;
28+
struct nv_kthread_q_item;
29+
typedef struct nv_kthread_q nv_kthread_q_t;
30+
typedef struct nv_kthread_q_item nv_kthread_q_item_t;
31+
32+
typedef void (*nv_q_func_t)(void *args);
3233

33-
#include "conftest.h"
34+
#include "nv-kthread-q-os.h"
3435

3536
////////////////////////////////////////////////////////////////////////////////
3637
// nv_kthread_q:
@@ -85,38 +86,6 @@
8586
//
8687
////////////////////////////////////////////////////////////////////////////////
8788

88-
typedef struct nv_kthread_q nv_kthread_q_t;
89-
typedef struct nv_kthread_q_item nv_kthread_q_item_t;
90-
91-
typedef void (*nv_q_func_t)(void *args);
92-
93-
struct nv_kthread_q
94-
{
95-
struct list_head q_list_head;
96-
spinlock_t q_lock;
97-
98-
// This is a counting semaphore. It gets incremented and decremented
99-
// exactly once for each item that is added to the queue.
100-
struct semaphore q_sem;
101-
atomic_t main_loop_should_exit;
102-
103-
struct task_struct *q_kthread;
104-
};
105-
106-
struct nv_kthread_q_item
107-
{
108-
struct list_head q_list_node;
109-
nv_q_func_t function_to_run;
110-
void *function_args;
111-
};
112-
113-
114-
#ifndef NUMA_NO_NODE
115-
#define NUMA_NO_NODE (-1)
116-
#endif
117-
118-
#define NV_KTHREAD_NO_NODE NUMA_NO_NODE
119-
12089
//
12190
// The queue must not be used before calling this routine.
12291
//
@@ -155,10 +124,7 @@ int nv_kthread_q_init_on_node(nv_kthread_q_t *q,
155124
// This routine is the same as nv_kthread_q_init_on_node() with the exception
156125
// that the queue stack will be allocated on the NUMA node of the caller.
157126
//
158-
static inline int nv_kthread_q_init(nv_kthread_q_t *q, const char *qname)
159-
{
160-
return nv_kthread_q_init_on_node(q, qname, NV_KTHREAD_NO_NODE);
161-
}
127+
int nv_kthread_q_init(nv_kthread_q_t *q, const char *qname);
162128

163129
//
164130
// The caller is responsible for stopping all queues, by calling this routine

0 commit comments

Comments
 (0)