Ben Skeggs
db2a20693e
drm/nouveau/kms/nv50-: convert core head_ovly() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:55 +10:00
Ben Skeggs
93f7f05457
drm/nouveau/kms/nv50-: convert core head_base() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:55 +10:00
Ben Skeggs
bc5af56a8f
drm/nouveau/kms/nv50-: convert core head_curs_clr() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:55 +10:00
Ben Skeggs
9549c14b32
drm/nouveau/kms/nv50-: convert core head_curs_set() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:55 +10:00
Ben Skeggs
aabe253e38
drm/nouveau/kms/nv50-: convert core head_core_clr() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:55 +10:00
Ben Skeggs
a38870a21c
drm/nouveau/kms/nv50-: convert core head_core_set() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:54 +10:00
Ben Skeggs
4fbf03a32f
drm/nouveau/kms/nv50-: convert core head_olut_clr() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:54 +10:00
Ben Skeggs
a5df76301c
drm/nouveau/kms/nv50-: convert core head_olut_set() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:54 +10:00
Ben Skeggs
caa966a7a6
drm/nouveau/kms/nv50-: convert core head_mode() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:54 +10:00
Ben Skeggs
1f772f5a08
drm/nouveau/kms/nv50-: convert core head_view() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:54 +10:00
Ben Skeggs
9ec5e82040
drm/nouveau/kms/nv50-: convert core or_ctrl() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:54 +10:00
Ben Skeggs
b505935e56
drm/nouveau/kms/nv50-: convert core wndw_owner() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:54 +10:00
Ben Skeggs
203f6eaf41
drm/nouveau/kms/nv50-: convert core update() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:54 +10:00
Ben Skeggs
3c43c362b3
drm/nouveau/kms/nv50-: convert core caps_init() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:53 +10:00
Ben Skeggs
5e691222ea
drm/nouveau/kms/nv50-: convert core init() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:53 +10:00
Ben Skeggs
3afb4db782
drm/nouveau/kms/nv50-: convert wndw update() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:53 +10:00
Ben Skeggs
85bdfcd435
drm/nouveau/kms/nv50-: convert wndw blend_set() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:53 +10:00
Ben Skeggs
0a4693e80d
drm/nouveau/kms/nv50-: convert wndw scale_set() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:53 +10:00
Ben Skeggs
8944d8b37a
drm/nouveau/kms/nv50-: convert wndw image_clr() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:53 +10:00
Ben Skeggs
6d6e11e284
drm/nouveau/kms/nv50-: convert wndw image_set() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:53 +10:00
Ben Skeggs
34838908f6
drm/nouveau/kms/nv50-: convert wndw xlut_clr() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:53 +10:00
Ben Skeggs
222439ebe6
drm/nouveau/kms/nv50-: convert wndw xlut_set() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:53 +10:00
Ben Skeggs
cfb4120dae
drm/nouveau/kms/nv50-: convert wndw csc_clr() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:52 +10:00
Ben Skeggs
72587dca96
drm/nouveau/kms/nv50-: convert wndw csc_set() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:52 +10:00
Ben Skeggs
bcae99c282
drm/nouveau/kms/nv50-: convert wndw ntfy_clr() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:52 +10:00
Ben Skeggs
fe8a2eec7d
drm/nouveau/kms/nv50-: convert wndw ntfy_set() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:52 +10:00
Ben Skeggs
c686051a5a
drm/nouveau/kms/nv50-: convert wndw sema_clr() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:52 +10:00
Ben Skeggs
34cf8cae28
drm/nouveau/kms/nv50-: convert wndw sema_set() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:52 +10:00
Ben Skeggs
9659be21e8
drm/nouveau/kms/nv50-: convert wimm update() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:52 +10:00
Ben Skeggs
bea8395ccf
drm/nouveau/kms/nv50-: convert wimm point() to new push macros
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:51 +10:00
Ben Skeggs
2853ccf092
drm/nouveau/kms/nv50-: wrap existing command submission in nvif_push interface
...
This commit pulls in a bunch of new push buffer macros which are able to
support NVIDIA's class headers, and provide more useful debug output and
error checking (compile-time, where possible) than we had previously.
Will incrementally transition each function over to the unified interfaces.
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:51 +10:00
Ben Skeggs
3e176fd060
drm/nouveau/nvif: add support for object-level debug output
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:51 +10:00
Ben Skeggs
f7a7d22ad6
drm/nouveau/nvif: give every notify object a human-readable name
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:51 +10:00
Ben Skeggs
54d44bfc56
drm/nouveau/nvif: give every disp object a human-readable identifier
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:51 +10:00
Ben Skeggs
64a0f59ab1
drm/nouveau/nvif: give every usermode object a human-readable identifier
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:51 +10:00
Ben Skeggs
45faf3d7b6
drm/nouveau/nvif: give every vmm object a human-readable identifier
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:51 +10:00
Ben Skeggs
e79c9a0ba5
drm/nouveau/nvif: give every mem object a human-readable identifier
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:51 +10:00
Ben Skeggs
b495396cc9
drm/nouveau/nvif: give every mmu object a human-readable identifier
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:50 +10:00
Ben Skeggs
bd21080eb6
drm/nouveau/nvif: give every device object a human-readable identifier
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:50 +10:00
Ben Skeggs
9ac596a4e8
drm/nouveau/nvif: give every object a human-readable identifier
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:50 +10:00
Ben Skeggs
6db25fb13a
drm/nouveau/nvif: rename client ctor/dtor
...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
2020-07-24 18:50:50 +10:00
Ben Skeggs
188e905ce4
drm/nouveau/kms/tu102: set NVC57D_HEAD_SET_HEAD_USAGE_BOUNDS_UPSCALING_ALLOWED to TRUE
...
Fixes issues when switching between scaling modes.
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2020-07-24 18:50:50 +10:00
Gustavo A. R. Silva
f6e7393ede
drm/nouveau: Use fallthrough pseudo-keyword
...
Replace the existing /* fall through */ comments and its variants with
the new pseudo-keyword macro fallthrough[1]. Also, remove unnecessary
fall-through markings when it is the case.
[1] https://www.kernel.org/doc/html/latest/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through
Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2020-07-24 18:50:50 +10:00
Ralph Campbell
7763d24f3b
drm/nouveau/vmm/gp100-: fix mapping 2MB sysmem pages
...
The nvif_object_ioctl() method NVIF_VMM_V0_PFNMAP wasn't correctly
setting the hardware specific GPU page table entries for 2MB sized
pages. Fix this by adding functions to set and clear PD0 GPU page
table entries.
Signed-off-by: Ralph Campbell <rcampbell@nvidia.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2020-07-24 18:50:50 +10:00
Ralph Campbell
e5c7864f62
drm/nouveau/mmu: make nvkm_vmm_ctor() static
...
The function nvkm_vmm_ctor() is not called outside of the file defining
it, so make it static.
Signed-off-by: Ralph Campbell <rcampbell@nvidia.com>
Reviewed-by: John Hubbard <jhubbard@nvidia.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2020-07-24 18:50:50 +10:00
Aditya Pakki
8f29432417
drm/nouveau: fix reference count leak in nouveau_debugfs_strap_peek
...
nouveau_debugfs_strap_peek() calls pm_runtime_get_sync() that
increments the reference count. In case of failure, decrement the
ref count before returning the error.
Signed-off-by: Aditya Pakki <pakki001@umn.edu>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2020-07-24 18:50:49 +10:00
Aditya Pakki
990a116298
drm/nouveau: Fix reference count leak in nouveau_connector_detect
...
nouveau_connector_detect() calls pm_runtime_get_sync and in turn
increments the reference count. In case of failure, decrement the
ref count before returning the error.
Signed-off-by: Aditya Pakki <pakki001@umn.edu>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2020-07-24 18:50:49 +10:00
Aditya Pakki
a2cdf39536
drm/nouveau: fix reference count leak in nv50_disp_atomic_commit
...
nv50_disp_atomic_commit() calls calls pm_runtime_get_sync and in turn
increments the reference count. In case of failure, decrement the
ref count before returning the error.
Signed-off-by: Aditya Pakki <pakki001@umn.edu>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2020-07-24 18:50:49 +10:00
Aditya Pakki
659fb5f154
drm/nouveau: fix multiple instances of reference count leaks
...
On calling pm_runtime_get_sync() the reference count of the device
is incremented. In case of failure, decrement the
ref count before returning the error.
Signed-off-by: Aditya Pakki <pakki001@umn.edu>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2020-07-24 18:50:49 +10:00
Aditya Pakki
bfad51c763
drm/nouveau/drm/noveau: fix reference count leak in nouveau_fbcon_open
...
nouveau_fbcon_open() calls calls pm_runtime_get_sync() that
increments the reference count. In case of failure, decrement the
ref count before returning the error.
Signed-off-by: Aditya Pakki <pakki001@umn.edu>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2020-07-24 18:50:49 +10:00