Skip to content

Commit

Permalink
515.57
Browse files Browse the repository at this point in the history
  • Loading branch information
aritger authored and liam-middlebrook committed Jul 2, 2022
1 parent a301003 commit 5375d56
Show file tree
Hide file tree
Showing 37 changed files with 546 additions and 339 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

## Release 515 Entries

### [515.57] 2022-06-28

#### Fixed

- Backtick is deprecated, [#273](https://github.com/NVIDIA/open-gpu-kernel-modules/pull/273) by @arch-user-france1

### [515.48.07] 2022-05-31

#### Added
Expand Down
23 changes: 13 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
# NVIDIA Linux Open GPU Kernel Module Source

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


## How to Build

To build:

make modules -j`nproc`
make modules -j$(nproc)

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

make modules_install -j`nproc`
make modules_install -j$(nproc)

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

Expand All @@ -39,7 +39,7 @@ If cross-compiling, set these variables on the make command line:
E.g.,

# compile on x86_64 for aarch64
make modules -j`nproc` \
make modules -j$(nproc) \
TARGET_ARCH=aarch64 \
CC=aarch64-linux-gnu-gcc \
LD=aarch64-linux-gnu-ld \
Expand All @@ -59,7 +59,7 @@ DEBUG - Set this to "1" to build the kernel modules as debug. By default, the

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

make modules -j`nproc` NV_VERBOSE=1
make modules -j$(nproc) NV_VERBOSE=1


## Supported Toolchains
Expand Down Expand Up @@ -167,14 +167,18 @@ for the target kernel.
## Compatible GPUs

The open-gpu-kernel-modules can be used on any Turing or later GPU
(see the table below). However, in the 515.49.05 release,
(see the table below). However, in the 515.57 release,
GeForce and Workstation support is still considered alpha-quality.

To enable use of the open kernel modules on GeForce and Workstation GPUs,
set the "NVreg_OpenRmEnableUnsupportedGpus" nvidia.ko kernel module
parameter to 1. For more details see the NVIDIA GPU end user README here:

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

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 |
| ----------------------------------------------- | -------------- |
Expand Down Expand Up @@ -496,6 +500,7 @@ https://us.download.nvidia.com/XFree86/Linux-x86_64/515.49.05/README/kernel_open
| Matrox D-Series D2450 | 1F76 102B 2800 |
| Matrox D-Series D2480 | 1F76 102B 2900 |
| NVIDIA GeForce GTX 1650 | 1F82 |
| NVIDIA GeForce GTX 1630 | 1F83 |
| NVIDIA GeForce GTX 1650 | 1F91 |
| NVIDIA GeForce GTX 1650 with Max-Q Design | 1F91 103C 863E |
| NVIDIA GeForce GTX 1650 with Max-Q Design | 1F91 103C 86E7 |
Expand Down Expand Up @@ -698,8 +703,6 @@ https://us.download.nvidia.com/XFree86/Linux-x86_64/515.49.05/README/kernel_open
| NVIDIA RTX A5500 | 2233 10DE 165A |
| NVIDIA RTX A5500 | 2233 17AA 165A |
| NVIDIA A40 | 2235 10DE 145A |
| NVIDIA A10 | 2236 10DE 1482 |
| NVIDIA A10G | 2237 10DE 152F |
| NVIDIA A10M | 2238 10DE 1677 |
| NVIDIA GeForce RTX 3060 Ti | 2414 |
| NVIDIA GeForce RTX 3080 Ti Laptop GPU | 2420 |
Expand Down
2 changes: 1 addition & 1 deletion kernel-open/Kbuild
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ EXTRA_CFLAGS += -I$(src)/common/inc
EXTRA_CFLAGS += -I$(src)
EXTRA_CFLAGS += -Wall -MD $(DEFINES) $(INCLUDES) -Wno-cast-qual -Wno-error -Wno-format-extra-args
EXTRA_CFLAGS += -D__KERNEL__ -DMODULE -DNVRM
EXTRA_CFLAGS += -DNV_VERSION_STRING=\"515.49.05\"
EXTRA_CFLAGS += -DNV_VERSION_STRING=\"515.57\"

EXTRA_CFLAGS += -Wno-unused-function

Expand Down
41 changes: 14 additions & 27 deletions kernel-open/nvidia-uvm/uvm_gpu_replayable_faults.c
Original file line number Diff line number Diff line change
Expand Up @@ -1942,45 +1942,32 @@ static NV_STATUS cancel_faults_precise_va(uvm_gpu_t *gpu,

// Function called when the system has found a global error and needs to
// trigger RC in RM.
// We cancel one entry per uTLB
static void cancel_fault_batch_tlb(uvm_gpu_t *gpu,
uvm_fault_service_batch_context_t *batch_context,
UvmEventFatalReason reason)
{
NvU32 i;

// Fault filtering is not allowed in the TLB-based fault cancel path
UVM_ASSERT(batch_context->num_cached_faults == batch_context->num_coalesced_faults);

for (i = 0; i < batch_context->num_cached_faults; ++i) {
NV_STATUS status;
for (i = 0; i < batch_context->num_coalesced_faults; ++i) {
NV_STATUS status = NV_OK;
uvm_fault_buffer_entry_t *current_entry;
uvm_fault_utlb_info_t *utlb;
uvm_fault_buffer_entry_t *coalesced_entry;

current_entry = &batch_context->fault_cache[i];
utlb = &batch_context->utlbs[current_entry->fault_source.utlb_id];
current_entry = batch_context->ordered_fault_cache[i];

// If this uTLB has been already cancelled, skip it
if (utlb->cancelled)
continue;
// The list iteration below skips the entry used as 'head'.
// Report the 'head' entry explicitly.
uvm_va_space_down_read(current_entry->va_space);
uvm_tools_record_gpu_fatal_fault(gpu->parent->id, current_entry->va_space, current_entry, reason);

record_fatal_fault_helper(gpu, current_entry, reason);

// Although the global cancellation method can be used here instead of
// targeted, we still use the targeted method since this function is
// only invoked in GPUs without support for VA fault cancellation, for
// which the targeted version is already required in
// cancel_faults_precise_tlb(). To maintain consistency, we use the
// targeted variant in both cases.
status = push_cancel_on_gpu_targeted(gpu,
current_entry->instance_ptr,
current_entry->fault_source.gpc_id,
current_entry->fault_source.client_id,
&batch_context->tracker);
list_for_each_entry(coalesced_entry, &current_entry->merged_instances_list, merged_instances_list)
uvm_tools_record_gpu_fatal_fault(gpu->parent->id, current_entry->va_space, coalesced_entry, reason);
uvm_va_space_up_read(current_entry->va_space);

// We need to cancel each instance pointer to correctly handle faults from multiple contexts.
status = push_cancel_on_gpu_global(gpu, current_entry->instance_ptr, &batch_context->tracker);
if (status != NV_OK)
break;

utlb->cancelled = true;
}
}

Expand Down
9 changes: 7 additions & 2 deletions kernel-open/nvidia-uvm/uvm_migrate_pageable.c
Original file line number Diff line number Diff line change
Expand Up @@ -899,9 +899,14 @@ static NV_STATUS migrate_pageable(migrate_vma_state_t *state)

// VMAs are validated and migrated one at a time, since migrate_vma works
// on one vma at a time
for (; vma->vm_start <= prev_outer; vma = vma->vm_next) {
for (; vma->vm_start <= prev_outer; vma = find_vma_intersection(mm, prev_outer, outer)) {
unsigned long next_addr = 0;
NV_STATUS status = migrate_pageable_vma(vma, start, outer, state, &next_addr);
NV_STATUS status;

// Callers have already validated the range so the vma should be valid.
UVM_ASSERT(vma);

status = migrate_pageable_vma(vma, start, outer, state, &next_addr);
if (status == NV_WARN_NOTHING_TO_DO) {
NV_STATUS populate_status = NV_OK;
bool touch = uvm_migrate_args->touch;
Expand Down
2 changes: 1 addition & 1 deletion kernel-open/nvidia-uvm/uvm_policy.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ bool uvm_is_valid_vma_range(struct mm_struct *mm, NvU64 start, NvU64 length)
if (vma->vm_end >= end)
return true;
start = vma->vm_end;
vma = vma->vm_next;
vma = find_vma_intersection(mm, start, end);
}

return false;
Expand Down
2 changes: 1 addition & 1 deletion kernel-open/nvidia-uvm/uvm_populate_pageable.c
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ NV_STATUS uvm_populate_pageable(struct mm_struct *mm,
// VMAs are validated and populated one at a time, since they may have
// different protection flags
// Validation of VM_SPECIAL flags is delegated to get_user_pages
for (; vma->vm_start <= prev_end; vma = vma->vm_next) {
for (; vma && vma->vm_start <= prev_end; vma = find_vma_intersection(mm, prev_end, end)) {
NV_STATUS status = uvm_populate_pageable_vma(vma, start, end - start, min_prot, touch, populate_permissions);

if (status != NV_OK)
Expand Down
5 changes: 4 additions & 1 deletion src/common/displayport/inc/dp_messages.h
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,9 @@ namespace DisplayPort
bool isBeingDestroyed;
bool isPaused;

// Properties from regkey
bool bNoReplyTimerForBusyWaiting;
bool bDpcdProbingForBusyWaiting;

List messageReceivers;
List notYetSentDownRequest; // Down Messages yet to be processed
Expand Down Expand Up @@ -159,7 +161,8 @@ namespace DisplayPort
{
DP_ASSERT(dpRegkeyDatabase.bInitialized &&
"All regkeys are invalid because dpRegkeyDatabase is not initialized!");
bNoReplyTimerForBusyWaiting = dpRegkeyDatabase.bNoReplyTimerForBusyWaiting;
bNoReplyTimerForBusyWaiting = dpRegkeyDatabase.bNoReplyTimerForBusyWaiting;
bDpcdProbingForBusyWaiting = dpRegkeyDatabase.bDpcdProbingForBusyWaiting;
}

MessageManager(DPCDHAL * hal, Timer * timer)
Expand Down
4 changes: 4 additions & 0 deletions src/common/displayport/inc/dp_regkeydatabase.h
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,9 @@
#define NV_DP_DSC_OPTIMIZE_LT_BUG_3534707 "DP_DSC_OPTIMIZE_LT_BUG_3534707"

#define NV_DP_REGKEY_NO_REPLY_TIMER_FOR_BUSY_WAITING "NO_REPLY_TIMER_FOR_BUSY_WAITING"

#define NV_DP_REGKEY_DPCD_PROBING_FOR_BUSY_WAITING "DP_DPCD_PROBING_FOR_BUSY_WAITING"

//
// Data Base used to store all the regkey values.
// The actual data base is declared statically in dp_evoadapter.cpp.
Expand Down Expand Up @@ -106,6 +109,7 @@ struct DP_REGKEY_DATABASE
bool bDscMstEnablePassThrough;
bool bDscOptimizeLTBug3534707;
bool bNoReplyTimerForBusyWaiting;
bool bDpcdProbingForBusyWaiting;
};

#endif //INCLUDED_DP_REGKEYDATABASE_H
Expand Down
3 changes: 2 additions & 1 deletion src/common/displayport/src/dp_evoadapter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,8 @@ const struct
{NV_DP_DSC_MST_CAP_BUG_3143315, &dpRegkeyDatabase.bDscMstCapBug3143315, DP_REG_VAL_BOOL},
{NV_DP_DSC_MST_ENABLE_PASS_THROUGH, &dpRegkeyDatabase.bDscMstEnablePassThrough, DP_REG_VAL_BOOL},
{NV_DP_DSC_OPTIMIZE_LT_BUG_3534707, &dpRegkeyDatabase.bDscOptimizeLTBug3534707, DP_REG_VAL_BOOL},
{NV_DP_REGKEY_NO_REPLY_TIMER_FOR_BUSY_WAITING, &dpRegkeyDatabase.bNoReplyTimerForBusyWaiting, DP_REG_VAL_BOOL}
{NV_DP_REGKEY_NO_REPLY_TIMER_FOR_BUSY_WAITING, &dpRegkeyDatabase.bNoReplyTimerForBusyWaiting, DP_REG_VAL_BOOL},
{NV_DP_REGKEY_DPCD_PROBING_FOR_BUSY_WAITING, &dpRegkeyDatabase.bDpcdProbingForBusyWaiting, DP_REG_VAL_BOOL}
};

EvoMainLink::EvoMainLink(EvoInterface * provider, Timer * timer) :
Expand Down
15 changes: 15 additions & 0 deletions src/common/displayport/src/dp_messages.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,20 @@ bool MessageManager::send(MessageManager::Message * message, NakData & nakData)
startTime = timer->getTimeUs();
do
{
if (bDpcdProbingForBusyWaiting)
{
hal->updateDPCDOffline();
if (hal->isDpcdOffline())
{
DP_LOG(("DP-MM> Device went offline while waiting for reply and so ignoring message %p (ID = %02X, target = %s)",
(Message*)this, ((Message*)this)->requestIdentifier, (((Message*)this)->state.target).toString(sb)));

nakData = completion.nakData;
completion.failed = true;
break;
}
}

hal->notifyIRQ();
if (hal->interruptDownReplyReady())
IRQDownReply();
Expand All @@ -81,6 +95,7 @@ bool MessageManager::send(MessageManager::Message * message, NakData & nakData)
nakData = completion.nakData;
break;
}

elapsedTime = timer->getTimeUs() - startTime;

if (elapsedTime > (DPCD_MESSAGE_REPLY_TIMEOUT * 1000))
Expand Down
34 changes: 22 additions & 12 deletions src/common/displayport/src/dp_wardatabase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -568,18 +568,28 @@ void Edid::applyEdidWorkArounds(NvU32 warFlag, const DpMonitorDenylistData *pDen
}
break;

//
// This panel advertise DSC capabilities, but panel doesn't support DSC
// So ignoring DSC capability on this panel
//
case 0x6F0E:
if (ProductID == 0x1609)
{
this->WARFlags.bIgnoreDscCap = true;
DP_LOG(("DP-WAR> Ignoring DSC capability on Lenovo CSOT 1609 Panel."));
DP_LOG(("DP-WAR> Bug 3444252"));
}
break;
//
// This panel advertise DSC capabilities, but panel doesn't support DSC
// So ignoring DSC capability on this panel
//
case 0x6F0E:
if (ProductID == 0x1609)
{
this->WARFlags.bIgnoreDscCap = true;
DP_LOG(("DP-WAR> Ignoring DSC capability on Lenovo CSOT 1609 Panel."));
DP_LOG(("DP-WAR> Bug 3444252"));
}
break;

// Asus
case 0x6D1E:
if(ProductID == 0x7707)
{
this->WARFlags.bIgnoreDscCap = true;
DP_LOG(("DP-WAR> Panel incorrectly exposing DSC capability. Ignoring it."));
DP_LOG(("DP-WAR> Bug 3543158"));
}
break;

default:
break;
Expand Down
20 changes: 10 additions & 10 deletions src/common/inc/nvBldVer.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,25 +36,25 @@
// and then checked back in. You cannot make changes to these sections without
// corresponding changes to the buildmeister script
#ifndef NV_BUILD_BRANCH
#define NV_BUILD_BRANCH VK516_10
#define NV_BUILD_BRANCH r515_00
#endif
#ifndef NV_PUBLIC_BRANCH
#define NV_PUBLIC_BRANCH VK516_10
#define NV_PUBLIC_BRANCH r515_00
#endif

#if defined(NV_LINUX) || defined(NV_BSD) || defined(NV_SUNOS)
#define NV_BUILD_BRANCH_VERSION "rel/gpu_drv/r515/VK516_10-204"
#define NV_BUILD_CHANGELIST_NUM (31466683)
#define NV_BUILD_BRANCH_VERSION "rel/gpu_drv/r515/r515_00-269"
#define NV_BUILD_CHANGELIST_NUM (31485447)
#define NV_BUILD_TYPE "Official"
#define NV_BUILD_NAME "rel/gpu_drv/r515/VK516_10-204"
#define NV_LAST_OFFICIAL_CHANGELIST_NUM (31466683)
#define NV_BUILD_NAME "rel/gpu_drv/r515/r515_00-269"
#define NV_LAST_OFFICIAL_CHANGELIST_NUM (31485447)

#else /* Windows builds */
#define NV_BUILD_BRANCH_VERSION "VK516_10-5"
#define NV_BUILD_CHANGELIST_NUM (31466683)
#define NV_BUILD_BRANCH_VERSION "r515_00-210"
#define NV_BUILD_CHANGELIST_NUM (31485447)
#define NV_BUILD_TYPE "Official"
#define NV_BUILD_NAME "516.48"
#define NV_LAST_OFFICIAL_CHANGELIST_NUM (31466683)
#define NV_BUILD_NAME "516.56"
#define NV_LAST_OFFICIAL_CHANGELIST_NUM (31485447)
#define NV_BUILD_BRANCH_BASE_VERSION R515
#endif
// End buildmeister python edited section
Expand Down
2 changes: 1 addition & 1 deletion src/common/inc/nvUnixVersion.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#if defined(NV_LINUX) || defined(NV_BSD) || defined(NV_SUNOS) || defined(NV_VMWARE) || defined(NV_QNX) || defined(NV_INTEGRITY) || \
(defined(RMCFG_FEATURE_PLATFORM_GSP) && RMCFG_FEATURE_PLATFORM_GSP == 1)

#define NV_VERSION_STRING "515.49.05"
#define NV_VERSION_STRING "515.57"

#else

Expand Down
15 changes: 15 additions & 0 deletions src/common/sdk/nvidia/inc/ctrl/ctrl2080/ctrl2080internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -2223,4 +2223,19 @@ typedef struct NV2080_CTRL_INTERNAL_BIF_SET_PCIE_RO_PARAMS {
NvBool enableRo;
} NV2080_CTRL_INTERNAL_BIF_SET_PCIE_RO_PARAMS;

/*!
* NV2080_CTRL_CMD_INTERNAL_GET_COHERENT_FB_APERTURE_SIZE
*
* Query Coherent FB Aperture Size.
*
*/
#define NV2080_CTRL_CMD_INTERNAL_GET_COHERENT_FB_APERTURE_SIZE (0x20800aba) /* finn: Evaluated from "(FINN_NV20_SUBDEVICE_0_INTERNAL_INTERFACE_ID << 8) | NV2080_CTRL_INTERNAL_GET_COHERENT_FB_APERTURE_SIZE_PARAMS_MESSAGE_ID" */

#define NV2080_CTRL_INTERNAL_GET_COHERENT_FB_APERTURE_SIZE_PARAMS_MESSAGE_ID (0xbaU)

typedef struct NV2080_CTRL_INTERNAL_GET_COHERENT_FB_APERTURE_SIZE_PARAMS {
// Get Coherent Fb Aperture Size
NV_DECLARE_ALIGNED(NvU64 coherentFbApertureSize, 8);
} NV2080_CTRL_INTERNAL_GET_COHERENT_FB_APERTURE_SIZE_PARAMS;

/* ctrl2080internal_h */
1 change: 1 addition & 0 deletions src/nvidia/arch/nvalloc/common/inc/nvcst.h
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,7 @@ CSINFO chipsetInfo[] =
{PCI_VENDOR_ID_INTEL, 0x4385, CS_INTEL_4381, "Intel-RocketLake", Intel_4381_setupFunc},
{PCI_VENDOR_ID_INTEL, 0x7A82, CS_INTEL_7A82, "Intel-AlderLake", Intel_7A82_setupFunc},
{PCI_VENDOR_ID_INTEL, 0x7A84, CS_INTEL_7A82, "Intel-AlderLake", Intel_7A82_setupFunc},
{PCI_VENDOR_ID_INTEL, 0x1B81, CS_INTEL_1B81, "Intel-SapphireRapids", NULL},

{PCI_VENDOR_ID_NVIDIA, 0x0FAE, CS_NVIDIA_T210, "T210", Nvidia_T210_setupFunc},
{PCI_VENDOR_ID_NVIDIA, 0x0FAF, CS_NVIDIA_T210, "T210", Nvidia_T210_setupFunc},
Expand Down
1 change: 1 addition & 0 deletions src/nvidia/arch/nvalloc/common/inc/nvdevid.h
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,7 @@ enum {
, CS_HYGON_C86
, CS_PHYTIUM_S2500
, CS_MELLANOX_BLUEFIELD2
, CS_INTEL_1B81
, CS_MAX_PCIE
};

Expand Down
Loading

0 comments on commit 5375d56

Please sign in to comment.