Skip to content

Commit e0566f7

Browse files
committed
570.181
1 parent 4d6c416 commit e0566f7

31 files changed

+830
-629
lines changed

README.md

Lines changed: 3 additions & 3 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 570.172.08.
4+
version 570.181.
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-
570.172.08 driver release. This can be achieved by installing
20+
570.181 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

@@ -185,7 +185,7 @@ table below).
185185
For details on feature support and limitations, see the NVIDIA GPU driver
186186
end user README here:
187187

188-
https://us.download.nvidia.com/XFree86/Linux-x86_64/570.172.08/README/kernel_open.html
188+
https://us.download.nvidia.com/XFree86/Linux-x86_64/570.181/README/kernel_open.html
189189

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

kernel-open/Kbuild

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ ccflags-y += -I$(src)/common/inc
7979
ccflags-y += -I$(src)
8080
ccflags-y += -Wall $(DEFINES) $(INCLUDES) -Wno-cast-qual -Wno-format-extra-args
8181
ccflags-y += -D__KERNEL__ -DMODULE -DNVRM
82-
ccflags-y += -DNV_VERSION_STRING=\"570.172.08\"
82+
ccflags-y += -DNV_VERSION_STRING=\"570.181\"
8383

8484
ifneq ($(SYSSRCHOST1X),)
8585
ccflags-y += -I$(SYSSRCHOST1X)

kernel-open/header-presence-tests.mk

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ NV_HEADER_PRESENCE_TESTS = \
3636
generated/autoconf.h \
3737
generated/compile.h \
3838
generated/utsrelease.h \
39+
linux/pfn_t.h \
3940
linux/aperture.h \
4041
linux/dma-direct.h \
4142
linux/efi.h \

kernel-open/nvidia-drm/nvidia-drm-gem-user-memory.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,13 @@ static vm_fault_t __nv_drm_gem_user_memory_handle_vma_fault(
157157
#if !defined(NV_LINUX)
158158
return vmf_insert_pfn(vma, address, pfn);
159159
#elif defined(NV_VMF_INSERT_MIXED_PRESENT)
160+
161+
#if defined(NV_LINUX_PFN_T_H_PRESENT)
160162
return vmf_insert_mixed(vma, address, pfn_to_pfn_t(pfn));
163+
#else
164+
return vmf_insert_mixed(vma, address, pfn);
165+
#endif
166+
161167
#else
162168
return __nv_vm_insert_mixed_helper(vma, address, pfn);
163169
#endif

kernel-open/nvidia/nv.c

Lines changed: 26 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1417,50 +1417,35 @@ static int nv_start_device(nv_state_t *nv, nvidia_stack_t *sp)
14171417
{
14181418
rc = os_alloc_mutex(&nvl->isr_bh_unlocked_mutex);
14191419
if (rc != 0)
1420-
goto failed;
1420+
goto failed_release_irq;
14211421
nv_kthread_q_item_init(&nvl->bottom_half_q_item, nvidia_isr_bh_unlocked, (void *)nv);
14221422
rc = nv_kthread_q_init(&nvl->bottom_half_q, nv_device_name);
14231423
if (rc != 0)
1424-
goto failed;
1424+
goto failed_release_irq;
14251425
kthread_init = NV_TRUE;
14261426

14271427
rc = nv_kthread_q_init(&nvl->queue.nvk, "nv_queue");
14281428
if (rc)
1429-
goto failed;
1429+
goto failed_release_irq;
14301430
nv->queue = &nvl->queue;
14311431

14321432
if (nv_platform_use_auto_online(nvl))
14331433
{
14341434
rc = nv_kthread_q_init(&nvl->remove_numa_memory_q,
14351435
"nv_remove_numa_memory");
14361436
if (rc)
1437-
goto failed;
1437+
goto failed_release_irq;
14381438
remove_numa_memory_kthread_init = NV_TRUE;
14391439
}
14401440
}
14411441

14421442
if (!rm_init_adapter(sp, nv))
14431443
{
1444-
if (!(nv->flags & NV_FLAG_USES_MSIX) &&
1445-
!(nv->flags & NV_FLAG_SOC_DISPLAY) &&
1446-
!(nv->flags & NV_FLAG_SOC_IGPU))
1447-
{
1448-
free_irq(nv->interrupt_line, (void *) nvl);
1449-
}
1450-
else if (nv->flags & NV_FLAG_SOC_DISPLAY)
1451-
{
1452-
}
1453-
#if defined(NV_LINUX_PCIE_MSI_SUPPORTED)
1454-
else
1455-
{
1456-
nv_free_msix_irq(nvl);
1457-
}
1458-
#endif
14591444
NV_DEV_PRINTF(NV_DBG_ERRORS, nv,
14601445
"rm_init_adapter failed, device minor number %d\n",
14611446
nvl->minor_num);
14621447
rc = -EIO;
1463-
goto failed;
1448+
goto failed_release_irq;
14641449
}
14651450

14661451
{
@@ -1494,6 +1479,26 @@ static int nv_start_device(nv_state_t *nv, nvidia_stack_t *sp)
14941479

14951480
return 0;
14961481

1482+
failed_release_irq:
1483+
if (!(nv->flags & NV_FLAG_PERSISTENT_SW_STATE))
1484+
{
1485+
if (!(nv->flags & NV_FLAG_USES_MSIX) &&
1486+
!(nv->flags & NV_FLAG_SOC_DISPLAY) &&
1487+
!(nv->flags & NV_FLAG_SOC_IGPU))
1488+
{
1489+
free_irq(nv->interrupt_line, (void *) nvl);
1490+
}
1491+
else if (nv->flags & NV_FLAG_SOC_DISPLAY)
1492+
{
1493+
}
1494+
#if defined(NV_LINUX_PCIE_MSI_SUPPORTED)
1495+
else
1496+
{
1497+
nv_free_msix_irq(nvl);
1498+
}
1499+
#endif
1500+
}
1501+
14971502
failed:
14981503
#if defined(NV_LINUX_PCIE_MSI_SUPPORTED)
14991504
if (nv->flags & NV_FLAG_USES_MSI)
@@ -2417,6 +2422,7 @@ nvidia_ioctl(
24172422
if (arg_cmd == NV_ESC_WAIT_OPEN_COMPLETE)
24182423
{
24192424
nv_ioctl_wait_open_complete_t *params = arg_copy;
2425+
24202426
params->rc = nvlfp->open_rc;
24212427
params->adapterStatus = nvlfp->adapter_status;
24222428
goto done_early;

src/common/displayport/inc/dp_connectorimpl.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -388,6 +388,9 @@ namespace DisplayPort
388388
NvU64 allocatedDpTunnelBwShadow;
389389
bool bForceDisableTunnelBwAllocation;
390390

391+
// Use regkey DP_DSC_DEVID_WAR to toggle this flag.
392+
bool bEnableDevId;
393+
391394
Group *perHeadAttachedGroup[NV_MAX_HEADS];
392395
NvU32 inTransitionHeadMask;
393396

src/common/displayport/inc/dp_regkeydatabase.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,9 @@
9999
#define NV_DP_REGKEY_DISABLE_FIX_FOR_5019537 "DP_DISABLE_5019537_FIX"
100100
#define NV_DP_REGKEY_ENABLE_FIX_FOR_5147205 "DP_ENABLE_5147205_FIX"
101101

102+
// This regkey forces devID to be exposed to vendors via DPCD 0x309 for DSC-enabled SKUs.
103+
#define NV_DP_REGKEY_EXPOSE_DSC_DEVID_WAR "DP_DSC_DEVID_WAR"
104+
102105
// Bug 5088957 : Force head shutdown in DpLib
103106
#define NV_DP_REGKEY_FORCE_HEAD_SHUTDOWN "DP_WAR_5088957"
104107

@@ -150,6 +153,7 @@ struct DP_REGKEY_DATABASE
150153
bool bForceHeadShutdown;
151154
bool bEnableLowerBppCheckForDsc;
152155
bool bSkipSettingLinkStateDuringUnplug;
156+
bool bEnableDevId;
153157
};
154158

155159
extern struct DP_REGKEY_DATABASE dpRegkeyDatabase;

src/common/displayport/src/dp_connectorimpl.cpp

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,17 @@
5151
#include "ctrl/ctrl0073/ctrl0073dp.h"
5252
#include "dp_tracing.h"
5353

54+
/*
55+
* This is needed by Synaptics to disable DisplayExpand feature
56+
* in some of their docking station based on if GPU supports DSC.
57+
* Feature is not needed if DSC is supported.
58+
* Customers reported problems with the feature enabled on GB20x devices
59+
* and requested GPU DSC detection to disable DisplayExpand feature.
60+
* DSC is supported in Turing and later SKUs hence
61+
* exposing Turing DevId to customers to address their requirement.
62+
*/
63+
#define TURING_DEV_ID 0x1E
64+
5465
using namespace DisplayPort;
5566

5667
ConnectorImpl::ConnectorImpl(MainLink * main, AuxBus * auxBus, Timer * timer, Connector::EventSink * sink)
@@ -187,6 +198,7 @@ void ConnectorImpl::applyRegkeyOverrides(const DP_REGKEY_DATABASE& dpRegkeyDatab
187198
this->bForceHeadShutdownFromRegkey = dpRegkeyDatabase.bForceHeadShutdown;
188199
this->bEnableLowerBppCheckForDsc = dpRegkeyDatabase.bEnableLowerBppCheckForDsc;
189200
this->bSkipSettingLinkStateDuringUnplug = dpRegkeyDatabase.bSkipSettingLinkStateDuringUnplug;
201+
this->bEnableDevId = dpRegkeyDatabase.bEnableDevId;
190202
}
191203

192204
void ConnectorImpl::setPolicyModesetOrderMitigation(bool enabled)
@@ -3894,14 +3906,20 @@ bool ConnectorImpl::getIgnoreSourceOuiHandshake()
38943906
bool ConnectorImpl::performIeeeOuiHandshake()
38953907
{
38963908
const char *ieeeOuiDevId = "NVIDIA";
3909+
NvU8 chipRevision = 0x0;
3910+
bool bGpuDscSupported = NV_FALSE;
3911+
3912+
main->getDscCaps(&bGpuDscSupported);
3913+
if ((this->bEnableDevId) && (bGpuDscSupported))
3914+
{
3915+
chipRevision = TURING_DEV_ID;
3916+
}
38973917

38983918
if (!hal->getOuiSupported() || getIgnoreSourceOuiHandshake())
38993919
return false;
39003920

3901-
if (hal->setOuiSource(DPCD_OUI_NVIDIA, ieeeOuiDevId, 6 /* string length of ieeeOuiDevId */, 0) == AuxRetry::ack)
3921+
if (hal->setOuiSource(DPCD_OUI_NVIDIA, ieeeOuiDevId, 6 /* string length of ieeeOuiDevId */, chipRevision) == AuxRetry::ack)
39023922
{
3903-
NvU8 chipRevision = 0;
3904-
39053923
// parse client OUI.
39063924
if (hal->getOuiSink(ouiId, &modelName[0], sizeof(modelName), chipRevision))
39073925
{

src/common/displayport/src/dp_evoadapter.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,8 @@ const struct
107107
{NV_DP_REGKEY_ENABLE_FIX_FOR_5147205, &dpRegkeyDatabase.bEnable5147205Fix, DP_REG_VAL_BOOL},
108108
{NV_DP_REGKEY_FORCE_HEAD_SHUTDOWN, &dpRegkeyDatabase.bForceHeadShutdown, DP_REG_VAL_BOOL},
109109
{NV_DP_REGKEY_ENABLE_LOWER_BPP_CHECK_FOR_DSC, &dpRegkeyDatabase.bEnableLowerBppCheckForDsc, DP_REG_VAL_BOOL},
110-
{NV_DP_REGKEY_SKIP_SETTING_LINK_STATE_DURING_UNPLUG, &dpRegkeyDatabase.bSkipSettingLinkStateDuringUnplug, DP_REG_VAL_BOOL}
110+
{NV_DP_REGKEY_SKIP_SETTING_LINK_STATE_DURING_UNPLUG, &dpRegkeyDatabase.bSkipSettingLinkStateDuringUnplug, DP_REG_VAL_BOOL},
111+
{NV_DP_REGKEY_EXPOSE_DSC_DEVID_WAR, &dpRegkeyDatabase.bEnableDevId, DP_REG_VAL_BOOL}
111112
};
112113

113114
EvoMainLink::EvoMainLink(EvoInterface * provider, Timer * timer) :

src/common/displayport/src/dp_wardatabase.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,9 +117,9 @@ void ConnectorImpl2x::applyOuiWARs()
117117
(modelName[1] == 'C') &&
118118
(modelName[2] == '2') &&
119119
(modelName[3] == '9') &&
120-
(modelName[4] == '0') &&
121-
(modelName[5] == 0x04U))
120+
(modelName[4] == '0'))
122121
{
122+
bForceHeadShutdownPerMonitor = true;
123123
bApplyStuffDummySymbolsWAR = true;
124124
bStuffDummySymbolsFor128b132b = false;
125125
bStuffDummySymbolsFor8b10b = true;

0 commit comments

Comments
 (0)