mirror of
https://github.com/ublue-os/akmods.git
synced 2026-11-03 14:59:42 -09:00
feat: Add big screen patches for Nvidia-open driver (#593)
This commit is contained in:
parent
9a4db4eb14
commit
56c8acd125
2 changed files with 132 additions and 0 deletions
|
|
@ -0,0 +1,86 @@
|
|||
From bf3bf757f5131d8d90f3adf4cb2e8599840f1700 Mon Sep 17 00:00:00 2001
|
||||
From: triple-groove <triple-groove@users.noreply.github.com>
|
||||
Date: Sun, 22 Feb 2026 16:07:56 -0800
|
||||
Subject: [PATCH 1/4] fix(dsc): correct RC parameter tables to match VESA DSC
|
||||
1.1 standard
|
||||
|
||||
The minqp444_8b, maxqp444_8b, and ofs_und8 tables in nvt_dsc_pps.c
|
||||
contain non-standard values for the 8bpc / 8.0 bpp operating point
|
||||
(column index 4). Ranges 9-14 have more constrained max_qp values
|
||||
than the VESA DSC 1.1 specification (Table E-5), and range 11 has
|
||||
an incorrect bpg_offset.
|
||||
|
||||
These deviations prevent the DSC encoder from quantizing aggressively
|
||||
enough when the RC buffer approaches overflow on complex content,
|
||||
causing visible block/tile "rainbow static" artifacts on sinks that
|
||||
implement strict VESA-compliant DSC decompression.
|
||||
|
||||
Corrected values (all at column index 4 = 8.0 bpp):
|
||||
|
||||
minqp444_8b range 9: 4 -> 3
|
||||
minqp444_8b range 13: 8 -> 7
|
||||
minqp444_8b range 14: 12 -> 13
|
||||
maxqp444_8b range 10: 10 -> 11
|
||||
maxqp444_8b range 11: 11 -> 12
|
||||
maxqp444_8b range 12: 11 -> 13
|
||||
maxqp444_8b range 13: 12 -> 13
|
||||
maxqp444_8b range 14: 13 -> 15
|
||||
ofs_und8 range 11: -10 -> -12
|
||||
|
||||
Tested on RTX 5090 with Bigscreen Beyond VR headset (DSC 1.1, 8bpc,
|
||||
8.0 bpp, RGB 4:4:4, 3840x1920@90Hz). Artifacts completely eliminated.
|
||||
|
||||
Signed-off-by: triple-groove <triple-groove@users.noreply.github.com>
|
||||
---
|
||||
src/common/modeset/timing/nvt_dsc_pps.c | 18 +++++++++---------
|
||||
1 file changed, 9 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/src/common/modeset/timing/nvt_dsc_pps.c b/src/common/modeset/timing/nvt_dsc_pps.c
|
||||
index 0f6ba54..94e33b4 100644
|
||||
--- a/src/common/modeset/timing/nvt_dsc_pps.c
|
||||
+++ b/src/common/modeset/timing/nvt_dsc_pps.c
|
||||
@@ -191,12 +191,12 @@ static const NvU8 minqp444_8b[15][37]={
|
||||
,{ 5, 5, 4, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0}
|
||||
,{ 5, 5, 4, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0}
|
||||
,{ 5, 5, 4, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1, 0, 0, 0}
|
||||
- ,{ 6, 5, 5, 4, 4, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 2, 2, 1, 1, 1, 1, 1, 1, 0, 0, 0}
|
||||
+ ,{ 6, 5, 5, 4, 3, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 2, 2, 1, 1, 1, 1, 1, 1, 0, 0, 0} // [9] col4: 4->3 (VESA DSC 1.1)
|
||||
,{ 6, 6, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 4, 4, 4, 4, 4, 4, 4, 4, 4, 3, 3, 3, 3, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 0}
|
||||
,{ 6, 6, 6, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 4, 4, 4, 4, 4, 4, 4, 4, 4, 3, 3, 2, 2, 2, 2, 1, 1, 1, 1, 0}
|
||||
,{ 6, 6, 6, 6, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 4, 4, 4, 4, 3, 3, 2, 2, 2, 2, 1, 1, 1, 1, 0}
|
||||
- ,{ 9, 9, 9, 9, 8, 8, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 6, 6, 5, 5, 5, 5, 4, 4, 3, 3, 3, 3, 2, 2, 1, 1, 1}
|
||||
- ,{14,14,13,13,12,12,12,12,11,11,10,10,10,10, 9, 9, 9, 8, 8, 8, 7, 7, 7, 7, 6, 6, 5, 5, 5, 5, 4, 4, 4, 3, 3, 3, 3}
|
||||
+ ,{ 9, 9, 9, 9, 7, 8, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 6, 6, 5, 5, 5, 5, 4, 4, 3, 3, 3, 3, 2, 2, 1, 1, 1} // [13] col4: 8->7 (VESA DSC 1.1)
|
||||
+ ,{14,14,13,13,13,12,12,12,11,11,10,10,10,10, 9, 9, 9, 8, 8, 8, 7, 7, 7, 7, 6, 6, 5, 5, 5, 5, 4, 4, 4, 3, 3, 3, 3} // [14] col4: 12->13 (VESA DSC 1.1)
|
||||
};
|
||||
|
||||
static const NvU8 maxqp444_8b[15][37]={
|
||||
@@ -210,11 +210,11 @@ static const NvU8 maxqp444_8b[15][37]={
|
||||
,{10,10, 9, 9, 8, 8, 8, 8, 8, 8, 8, 8, 8, 7, 7, 6, 5, 5, 4, 4, 4, 4, 3, 3, 3, 3, 2, 2, 2, 2, 2, 2, 1, 1, 1, 1, 1}
|
||||
,{11,11,10,10, 9, 9, 9, 9, 9, 9, 8, 8, 8, 7, 7, 6, 6, 5, 5, 5, 5, 5, 4, 4, 4, 4, 3, 3, 2, 2, 2, 2, 2, 2, 1, 1, 1}
|
||||
,{12,11,11,10,10,10, 9, 9, 9, 9, 9, 9, 9, 8, 8, 7, 6, 6, 5, 5, 5, 5, 4, 4, 4, 4, 3, 3, 2, 2, 2, 2, 2, 2, 1, 1, 1}
|
||||
- ,{12,12,11,11,10,10,10,10,10,10, 9, 9, 9, 8, 8, 7, 7, 6, 6, 6, 5, 5, 4, 4, 4, 4, 3, 3, 2, 2, 2, 2, 2, 2, 2, 2, 1}
|
||||
- ,{12,12,12,11,11,11,10,10,10,10, 9, 9, 9, 9, 8, 8, 8, 7, 7, 7, 6, 6, 5, 5, 5, 5, 4, 4, 3, 3, 3, 3, 2, 2, 2, 2, 1}
|
||||
- ,{12,12,12,12,11,11,11,11,11,10,10, 9, 9, 9, 8, 8, 8, 7, 7, 7, 6, 6, 5, 5, 5, 5, 4, 4, 3, 3, 3, 3, 2, 2, 2, 2, 1}
|
||||
- ,{13,13,13,13,12,12,11,11,11,11,10,10,10,10, 9, 9, 8, 8, 8, 8, 7, 7, 6, 6, 6, 6, 5, 5, 4, 4, 4, 4, 3, 3, 2, 2, 2}
|
||||
- ,{15,15,14,14,13,13,13,13,12,12,11,11,11,11,10,10,10, 9, 9, 9, 8, 8, 8, 8, 7, 7, 6, 6, 6, 6, 5, 5, 5, 4, 4, 4, 4}
|
||||
+ ,{12,12,11,11,11,10,10,10,10,10, 9, 9, 9, 8, 8, 7, 7, 6, 6, 6, 5, 5, 4, 4, 4, 4, 3, 3, 2, 2, 2, 2, 2, 2, 2, 2, 1} // [10] col4: 10->11 (VESA DSC 1.1)
|
||||
+ ,{12,12,12,11,12,11,10,10,10,10, 9, 9, 9, 9, 8, 8, 8, 7, 7, 7, 6, 6, 5, 5, 5, 5, 4, 4, 3, 3, 3, 3, 2, 2, 2, 2, 1} // [11] col4: 11->12 (VESA DSC 1.1)
|
||||
+ ,{12,12,12,12,13,11,11,11,11,10,10, 9, 9, 9, 8, 8, 8, 7, 7, 7, 6, 6, 5, 5, 5, 5, 4, 4, 3, 3, 3, 3, 2, 2, 2, 2, 1} // [12] col4: 11->13 (VESA DSC 1.1)
|
||||
+ ,{13,13,13,13,13,12,11,11,11,11,10,10,10,10, 9, 9, 8, 8, 8, 8, 7, 7, 6, 6, 6, 6, 5, 5, 4, 4, 4, 4, 3, 3, 2, 2, 2} // [13] col4: 12->13 (VESA DSC 1.1)
|
||||
+ ,{15,15,14,14,15,13,13,13,12,12,11,11,11,11,10,10,10, 9, 9, 9, 8, 8, 8, 8, 7, 7, 6, 6, 6, 6, 5, 5, 5, 4, 4, 4, 4} // [14] col4: 13->15 (VESA DSC 1.1)
|
||||
};
|
||||
|
||||
static const NvU8 minqp444_10b[15][49]={
|
||||
@@ -938,7 +938,7 @@ DSC_PpsCalcRcParam
|
||||
//else
|
||||
{
|
||||
const NvU32 ofs_und6[] = { 0, -2, -2, -4, -6, -6, -8, -8, -8, -10, -10, -12, -12, -12, -12 };
|
||||
- const NvU32 ofs_und8[] = { 2, 0, 0, -2, -4, -6, -8, -8, -8, -10, -10, -10, -12, -12, -12 };
|
||||
+ const NvU32 ofs_und8[] = { 2, 0, 0, -2, -4, -6, -8, -8, -8, -10, -10, -12, -12, -12, -12 }; // [11]: -10->-12 (VESA DSC 1.1)
|
||||
const NvU32 ofs_und12[] = { 2, 0, 0, -2, -4, -6, -8, -8, -8, -10, -10, -10, -12, -12, -12 };
|
||||
const NvU32 ofs_und15[] = { 10, 8, 6, 4, 2, 0, -2, -4, -6, -8, -10, -10, -12, -12, -12 };
|
||||
|
||||
--
|
||||
2.53.0
|
||||
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
From fe1ed8b517445efed1cb64ec197f7e3a458a8191 Mon Sep 17 00:00:00 2001
|
||||
From: triple-groove <triple-groove@users.noreply.github.com>
|
||||
Date: Sun, 22 Feb 2026 16:08:46 -0800
|
||||
Subject: [PATCH 3/4] fix(dp): add Bigscreen Beyond VR headset to WAR database
|
||||
|
||||
Add the Bigscreen Beyond (ManufacturerID 0x2709, ProductID 0x1234)
|
||||
to the DisplayPort workaround database. Force maximum link
|
||||
configuration (4 lanes HBR2) to ensure sufficient bandwidth through
|
||||
the BSB's DP-to-optical link box converter.
|
||||
|
||||
Without this WAR, the driver may negotiate a lower link config that
|
||||
is borderline for the BSB's 3840x1920@90Hz DSC mode, causing
|
||||
intermittent link training failures.
|
||||
|
||||
Signed-off-by: triple-groove <triple-groove@users.noreply.github.com>
|
||||
---
|
||||
src/common/displayport/src/dp_wardatabase.cpp | 13 +++++++++++++
|
||||
1 file changed, 13 insertions(+)
|
||||
|
||||
diff --git a/src/common/displayport/src/dp_wardatabase.cpp b/src/common/displayport/src/dp_wardatabase.cpp
|
||||
index a205fab..04f1c62 100644
|
||||
--- a/src/common/displayport/src/dp_wardatabase.cpp
|
||||
+++ b/src/common/displayport/src/dp_wardatabase.cpp
|
||||
@@ -542,6 +542,19 @@ void Edid::applyEdidWorkArounds(NvU32 warFlag, const DpMonitorDenylistData *pDen
|
||||
}
|
||||
break;
|
||||
|
||||
+ // Bigscreen Beyond VR headset
|
||||
+ case 0x2709:
|
||||
+ if (ProductID == 0x1234)
|
||||
+ {
|
||||
+ //
|
||||
+ // The Bigscreen Beyond connects via a link box (DP -> optical).
|
||||
+ // Force 4 lanes HBR2 to ensure sufficient bandwidth.
|
||||
+ //
|
||||
+ this->WARFlags.forceMaxLinkConfig = true;
|
||||
+ DP_PRINTF(DP_NOTICE, "DP-WAR> Force maximum link config for Bigscreen Beyond VR headset.");
|
||||
+ }
|
||||
+ break;
|
||||
+
|
||||
// CMN
|
||||
case 0xAE0D:
|
||||
if (ProductID == 0x1747)
|
||||
--
|
||||
2.53.0
|
||||
|
||||
Loading…
Reference in a new issue