]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
drm/nouveau/kms/tu102-: disable input lut when input is already FP16
authorBen Skeggs <bskeggs@redhat.com>
Wed, 29 May 2019 05:44:57 +0000 (15:44 +1000)
committerKhalid Elmously <khalid.elmously@canonical.com>
Fri, 18 Oct 2019 08:26:18 +0000 (04:26 -0400)
BugLink: https://bugs.launchpad.net/bugs/1848047
[ Upstream commit 1e339ab2ac3c769c1b06b9fb7d532f8495ebc56d ]

On Turing, an input LUT is required to transform inputs in fixed-point
formats to FP16 for the internal display pipe.  We provide an identity
mapping whenever a window is enabled for this reason.

HW has error checks to ensure when the input is already FP16, that the
input LUT is also disabled.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
drivers/gpu/drm/nouveau/dispnv50/wndw.c

index 283ff690350ea76ee20fe7db1beda003631f4be2..50303ec194bbca2973da05458a03ee3e118b8aed 100644 (file)
@@ -320,7 +320,9 @@ nv50_wndw_atomic_check_lut(struct nv50_wndw *wndw,
                asyh->wndw.olut &= ~BIT(wndw->id);
        }
 
-       if (!ilut && wndw->func->ilut_identity) {
+       if (!ilut && wndw->func->ilut_identity &&
+           asyw->state.fb->format->format != DRM_FORMAT_XBGR16161616F &&
+           asyw->state.fb->format->format != DRM_FORMAT_ABGR16161616F) {
                static struct drm_property_blob dummy = {};
                ilut = &dummy;
        }