aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2023-08-11drm/ttm/tests: Require MMU when testingKarolina Stolarek1-1/+1
Satisfy MMU dependency when testing TTM with KUnit. This fixes compilation errors on platforms that don't select this option by default. Signed-off-by: Karolina Stolarek <[email protected]> Reported-by: kernel test robot <[email protected]> Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/ Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/ Reviewed-by: Christian König <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Signed-off-by: Christian König <[email protected]>
2023-08-11accel/ivpu: Document DRM_IVPU_PARAM_CAPABILITIESStanislaw Gruszka1-2/+16
Add comments regarding new DRM_IVPU_PARAM_CAPABILITIES param. Signed-off-by: Stanislaw Gruszka <[email protected]> Reviewed-by: Jeffrey Hugo <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-11nouveau/u_memcpya: use vmemdup_userDave Airlie1-14/+5
I think there are limit checks in place for most things but the new uAPI wants to not have them. Add a limit check and use the vmemdup_user helper instead. Signed-off-by: Dave Airlie <[email protected]> Reviewed-by: Danilo Krummrich <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-10drm/rockchip: dsi: Add rv1126 MIPI DSI supportJagan Teki1-0/+20
RV1126 MIPI DSI supports V1.2 DPHY with 4 lanes and 1Gbps transfer rate for lane. Add support for it. Signed-off-by: Jagan Teki <[email protected]> Signed-off-by: Heiko Stuebner <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-10dt-bindings: display: rockchip-dw-mipi-dsi: Document rv1126 DSIJagan Teki1-0/+2
Document the MIPI DSI for Rockchip RV1126, which is different from other SoCs variants. Signed-off-by: Jagan Teki <[email protected]> Acked-by: Conor Dooley <[email protected]> Signed-off-by: Heiko Stuebner <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-10drm/rockchip: vop: Add rv1126 vop_lite supportJagan Teki1-0/+55
RV1126 VOP_LITE supports the video output processing ofMIPI DSI, RGB display interfaces with max output resolution of 1920x1080. Add support for rv1126 vop. Signed-off-by: Jagan Teki <[email protected]> Signed-off-by: Heiko Stuebner <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-10dt-bindings: display: rockchip-vop: Document rv1126 vopJagan Teki1-0/+1
The VOP on Rockchip's RV1126 SoC is different from other SoC's VOP implementations, so add a separate compatible for it. Signed-off-by: Jagan Teki <[email protected]> Acked-by: Conor Dooley <[email protected]> Signed-off-by: Heiko Stuebner <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-10drm/ttm: Remove two unused function declarationsYue Haibing1-2/+0
Commit cd3a8a596214 ("drm/ttm: remove ttm_bo_(un)lock_delayed_workqueue") removed the implementations but not the declarations. Signed-off-by: Yue Haibing <[email protected]> Reviewed-by: Christian König <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Signed-off-by: Christian König <[email protected]>
2023-08-10drm/test: drm_exec: fix memory leak on object prepareDanilo Krummrich1-2/+5
drm_exec_prepare_obj() and drm_exec_prepare_array() both reserve dma-fence slots and hence a dma_resv_list without ever freeing it. Make sure to call drm_gem_private_object_fini() for each GEM object passed to drm_exec_prepare_obj()/drm_exec_prepare_array() throughout the test to fix this up. While at it, remove some trailing empty lines. Fixes: 9710631cc8f3 ("drm: add drm_exec selftests v4") Signed-off-by: Danilo Krummrich <[email protected]> Reviewed-by: Christian König <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Signed-off-by: Christian König <[email protected]>
2023-08-10drm: atmel-hlcdc: Support inverting the pixel clock polarityMiquel Raynal1-0/+25
On the SoC host controller, the pixel clock can be: * standard: data is launched on the rising edge * inverted: data is launched on the falling edge Some panels may need the inverted option to be used so let's support this DRM flag. Signed-off-by: Miquel Raynal <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Signed-off-by: Boris Brezillon <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-10drm/panfrost: Sync IRQ by job's timeout handlerDmitry Osipenko1-0/+16
Panfrost IRQ handler may stuck for a long time, for example this happens when there is a bad HDMI connection and HDMI handler takes a long time to finish processing, holding Panfrost. Make Panfrost's job timeout handler to sync IRQ before checking fence signal status in order to prevent spurious job timeouts due to a slow IRQ processing. Reviewed-by: Steven Price <[email protected]> Reviewed-by: Boris Brezillon <[email protected]> Reviewed-by: AngeloGioacchino Del Regno <[email protected]> Tested-by: AngeloGioacchino Del Regno <[email protected]> # MediaTek MT8192 and MT8195 Chromebooks Signed-off-by: Dmitry Osipenko <[email protected]> Signed-off-by: Boris Brezillon <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-10drm/exec: add test case for using a drm_exec multiple timesChristian König1-0/+21
Not really a common use case, but let's make sure that we don't accidentially break that somehow. CC: Boris Brezillon <[email protected]> Signed-off-by: Christian König <[email protected]> Reviewed-by: Boris Brezillon <[email protected]> Signed-off-by: Boris Brezillon <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-10drm/exec: use unique instead of local labelChristian König1-7/+7
GCC forbids to jump to labels in loop conditions and a new clang check stumbled over this. So instead using a local label inside the loop condition use an unique label outside of it. Fixes: 09593216bff1 ("drm: execution context for GEM buffers v7") Link: https://gcc.gnu.org/onlinedocs/gcc/Statement-Exprs.html Link: https://github.com/ClangBuiltLinux/linux/issues/1890 Link: https://github.com/llvm/llvm-project/commit/20219106060208f0c2f5d096eb3aed7b712f5067 Reported-by: Nathan Chancellor <[email protected]> Reported-by: Naresh Kamboju <[email protected]> CC: Boris Brezillon <[email protected]> Signed-off-by: Christian König <[email protected]> Tested-by: Nathan Chancellor <[email protected]> Reviewed-by: Boris Brezillon <[email protected]> Reviewed-by: Nick Desaulniers <[email protected]> Signed-off-by: Boris Brezillon <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-09drm/ttm/tests: Add tests for ttm_poolKarolina Stolarek4-0/+459
Add KUnit tests that exercise page allocation using page pools and freeing pages, either by returning them to the pool or freeing them. Add a basic test for ttm_pool cleanup. Introduce helpers to create a dummy ttm_buffer_object. Signed-off-by: Karolina Stolarek <[email protected]> Reviewed-by: Christian König <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/427ea373357d0b6cb376c9d7ebc33c930bf1d28a.1691487006.git.karolina.stolarek@intel.com Signed-off-by: Christian König <[email protected]>
2023-08-09drm/ttm/tests: Add tests for ttm_deviceKarolina Stolarek1-0/+158
Test initialization and cleanup of the ttm_device struct, including some error paths. Verify the creation of page pools if use_dma_alloc param is true. Signed-off-by: Karolina Stolarek <[email protected]> Reviewed-by: Christian König <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/2abb0e53e7d56b0a24d0255f9075e2123b991278.1691487006.git.karolina.stolarek@intel.com Signed-off-by: Christian König <[email protected]>
2023-08-09drm/ttm: Introduce KUnit testKarolina Stolarek7-0/+212
Add the initial version of unit tests for ttm_device struct, together with helper functions. Signed-off-by: Karolina Stolarek <[email protected]> Reviewed-by: Christian König <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/3d1cc45c8a0cf536b92a850e0025f6c555de0169.1691487006.git.karolina.stolarek@intel.com Signed-off-by: Christian König <[email protected]>
2023-08-09accel/ivpu: Add initial support for VPU 4Stanislaw Gruszka7-2/+1462
Add support VPU 4 - new generation of VPU IP with various hardware design improvements. From driver point of view, it differs in register set, initialization process and MMU memory ranges. Co-developed-by: Andrzej Kacprowski <[email protected]> Signed-off-by: Andrzej Kacprowski <[email protected]> Co-developed-by: Krystian Pradzynski <[email protected]> Signed-off-by: Krystian Pradzynski <[email protected]> Co-developed-by: Karol Wachowski <[email protected]> Signed-off-by: Karol Wachowski <[email protected]> Reviewed-by: Jacek Lawrynowicz <[email protected]> Signed-off-by: Stanislaw Gruszka <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-09accel/ivpu: Refactor memory ranges logicKarol Wachowski7-31/+32
Add new dma range and change naming convention for virtual address memory ranges managed by KMD. New available ranges are named as follows: * global range - global context accessible by FW * aliased range - user context accessible by FW * dma range - user context accessible by DMA * shave range - user context accessible by shaves * global shave range - global context accessible by shave nn Signed-off-by: Karol Wachowski <[email protected]> Reviewed-by: Stanislaw Gruszka <[email protected]> Signed-off-by: Stanislaw Gruszka <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-09accel/ivpu: Extend get_param ioctl to identify capabilitiesStanislaw Gruszka2-0/+23
Add DRM_IVPU_PARAM_CAPABILITIES parameters to get_param ioctl to query driver capabilities. For now use it for identify metric streamer and new dma memory range features. Currently upstream version of intel_vpu does not have those, they will be added it the future. Reviewed-by: Jacek Lawrynowicz <[email protected]> Signed-off-by: Stanislaw Gruszka <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-09accel/ivpu: Switch to generation based FW namesJacek Lawrynowicz1-6/+15
Use VPU IP generation for naming FW instead of the platform name. Signed-off-by: Jacek Lawrynowicz <[email protected]> Reviewed-by: Stanislaw Gruszka <[email protected]> Signed-off-by: Stanislaw Gruszka <[email protected]> Reviewed-by: Jeffrey Hugo <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-09accel/ivpu: Use generation based function and registers namesJacek Lawrynowicz6-484/+492
Given that VPU generation can be used by multiple platforms, driver should use VPU IP generation names instead of a platform. Change naming for functions and registries. Use 37XX format, where: 3 - major VPU IP generation version 7 - minor VPU IP generation version XX - postfix indicating this is an architecture and not marketing name Signed-off-by: Jacek Lawrynowicz <[email protected]> Reviewed-by: Stanislaw Gruszka <[email protected]> Signed-off-by: Stanislaw Gruszka <[email protected]> Reviewed-by: Jeffrey Hugo <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-09accel/ivpu: Rename sources to use generation based namesJacek Lawrynowicz4-3/+3
Given that VPU generation can be used by multiple platforms, driver should use VPU IP generation in names instead of a platform. Change naming for sources files. Use 37XX format, where: 3 - major VPU IP generation version 7 - minor VPU IP generation version XX - postfix indicating this is an architecture and not marketing name Signed-off-by: Jacek Lawrynowicz <[email protected]> Reviewed-by: Stanislaw Gruszka <[email protected]> Signed-off-by: Stanislaw Gruszka <[email protected]> Reviewed-by: Jeffrey Hugo <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-08drm/nouveau/sched: Don't pass user flags to drm_syncobj_find_fence()Faith Ekstrand1-1/+1
The flags field in drm_syncobj_find_fence() takes SYNCOBJ_WAIT flags from the syncobj UAPI whereas sync->flags is from the nouveau UAPI. What we actually want is 0 flags which tells it to just try to find the fence and then return without waiting. Fixes: b88baab82871 ("drm/nouveau: implement new VM_BIND uAPI") Cc: Danilo Krummrich <[email protected]> Cc: Dave Airlie <[email protected]> Reviewed-by: Danilo Krummrich <[email protected]> Signed-off-by: Faith Ekstrand <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-08drm/nouveau: uvmm: remove dedicated VM pointer from VMAsDanilo Krummrich2-10/+9
VMAs can find their corresponding VM through their embedded struct drm_gpuva which already carries a pointer to a struct drm_gpuva_manager which the VM is based on. Hence, remove the struct nouveau_uvmm pointer from struct nouveau_uvma to save a couple of bytes per mapping. Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-08drm/nouveau: uvmm: remove incorrect calls to mas_unlock()Danilo Krummrich1-6/+2
Remove incorrect calls to mas_unlock() in the unwind path of __nouveau_uvma_region_insert(). The region maple tree uses an external lock instead, namely the global uvmm lock. Fixes: b88baab82871 ("drm/nouveau: implement new VM_BIND uAPI") Reported-by: kernel test robot <[email protected]> Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-08drm/nouveau: remove incorrect __user annotationsDanilo Krummrich4-9/+9
Fix copy-paste error causing EXEC and VM_BIND syscalls data pointers to carry incorrect __user annotations. Fixes: b88baab82871 ("drm/nouveau: implement new VM_BIND uAPI") Reported-by: kernel test robot <[email protected]> Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-08drm/nouveau: nvkm: vmm: silence warning from castDanilo Krummrich1-2/+3
Cast the integer to a pointer-sized type first to keep the compiler happy. Fixes: 6b252cf42281 ("drm/nouveau: nvkm/vmm: implement raw ops to manage uvmm") Reported-by: kernel test robot <[email protected]> Reported-by: Stephen Rothwell <[email protected]> Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-08nouveau/dmem: fix copy-paste error in nouveau_dmem_migrate_chunk()Danilo Krummrich1-1/+1
Fix call to nouveau_fence_emit() with wrong channel parameter. Fixes: 7f2a0b50b2b2 ("drm/nouveau: fence: separate fence alloc and emit") Reported-by: kernel test robot <[email protected]> Reported-by: Stephen Rothwell <[email protected]> Reviewed-by: Dave Airlie <[email protected]> Reviewed-by: Karol Herbst <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-07drm/mcde: remove redundant of_match_ptrZhu Wang1-1/+1
The driver depends on CONFIG_OF, so it is not necessary to use of_match_ptr here. Even for drivers that do not depend on CONFIG_OF, it's almost always better to leave out the of_match_ptr(), since the only thing it can possibly do is to save a few bytes of .text if a driver can be used both with and without it. Hence we remove of_match_ptr. Signed-off-by: Zhu Wang <[email protected]> Signed-off-by: Linus Walleij <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-07drm/tve200: remove redundant of_match_ptrZhu Wang1-1/+1
The driver depends on CONFIG_OF, so it is not necessary to use of_match_ptr here. Even for drivers that do not depend on CONFIG_OF, it's almost always better to leave out the of_match_ptr(), since the only thing it can possibly do is to save a few bytes of .text if a driver can be used both with and without it. Hence we remove of_match_ptr. Signed-off-by: Zhu Wang <[email protected]> Signed-off-by: Linus Walleij <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm/nouveau: debugfs: implement DRM GPU VA debugfsDanilo Krummrich1-0/+39
Provide the driver indirection iterating over all DRM GPU VA spaces to enable the common 'gpuvas' debugfs file for dumping DRM GPU VA spaces. Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm/nouveau: implement new VM_BIND uAPIDanilo Krummrich19-69/+3321
This commit provides the implementation for the new uapi motivated by the Vulkan API. It allows user mode drivers (UMDs) to: 1) Initialize a GPU virtual address (VA) space via the new DRM_IOCTL_NOUVEAU_VM_INIT ioctl for UMDs to specify the portion of VA space managed by the kernel and userspace, respectively. 2) Allocate and free a VA space region as well as bind and unbind memory to the GPUs VA space via the new DRM_IOCTL_NOUVEAU_VM_BIND ioctl. UMDs can request the named operations to be processed either synchronously or asynchronously. It supports DRM syncobjs (incl. timelines) as synchronization mechanism. The management of the GPU VA mappings is implemented with the DRM GPU VA manager. 3) Execute push buffers with the new DRM_IOCTL_NOUVEAU_EXEC ioctl. The execution happens asynchronously. It supports DRM syncobj (incl. timelines) as synchronization mechanism. DRM GEM object locking is handled with drm_exec. Both, DRM_IOCTL_NOUVEAU_VM_BIND and DRM_IOCTL_NOUVEAU_EXEC, use the DRM GPU scheduler for the asynchronous paths. Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm/nouveau: nvkm/vmm: implement raw ops to manage uvmmDanilo Krummrich12-99/+566
The new VM_BIND UAPI uses the DRM GPU VA manager to manage the VA space. Hence, we a need a way to manipulate the MMUs page tables without going through the internal range allocator implemented by nvkm/vmm. This patch adds a raw interface for nvkm/vmm to pass the resposibility for managing the address space and the corresponding map/unmap/sparse operations to the upper layers. Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm/nouveau: chan: provide nouveau_channel_kill()Danilo Krummrich2-3/+12
The new VM_BIND UAPI implementation introduced in subsequent commits will allow asynchronous jobs processing push buffers and emitting fences. If a job times out, we need a way to recover from this situation. For now, simply kill the channel to unblock all hung up jobs and signal userspace that the device is dead on the next EXEC or VM_BIND ioctl. Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm/nouveau: fence: fail to emit when fence context is killedDanilo Krummrich2-1/+8
The new VM_BIND UAPI implementation introduced in subsequent commits will allow asynchronous jobs processing push buffers and emitting fences. If a fence context is killed, e.g. due to a channel fault, jobs which are already queued for execution might still emit new fences. In such a case a job would hang forever. To fix that, fail to emit a new fence on a killed fence context with -ENODEV to unblock the job. Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm/nouveau: fence: separate fence alloc and emitDanilo Krummrich7-41/+59
The new (VM_BIND) UAPI exports DMA fences through DRM syncobjs. Hence, in order to emit fences within DMA fence signalling critical sections (e.g. as typically done in the DRM GPU schedulers run_job() callback) we need to separate fence allocation and fence emitting. Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm/nouveau: move usercopy helpers to nouveau_drv.hDanilo Krummrich2-26/+26
Move the usercopy helpers to a common driver header file to make it usable for the new API added in subsequent commits. Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm/nouveau: bo: initialize GEM GPU VA interfaceDanilo Krummrich1-0/+6
Initialize the GEM's DRM GPU VA manager interface in preparation for the (u)vmm implementation, provided by subsequent commits, to make use of it. Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm/nouveau: get vmm via nouveau_cli_vmm()Danilo Krummrich4-5/+14
Provide a getter function for the client's current vmm context. Since we'll add a new (u)vmm context for UMD bindings in subsequent commits, this will keep the code clean. Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm/nouveau: new VM_BIND uAPI interfacesDanilo Krummrich2-0/+225
This commit provides the interfaces for the new UAPI motivated by the Vulkan API. It allows user mode drivers (UMDs) to: 1) Initialize a GPU virtual address (VA) space via the new DRM_IOCTL_NOUVEAU_VM_INIT ioctl. UMDs can provide a kernel reserved VA area. 2) Bind and unbind GPU VA space mappings via the new DRM_IOCTL_NOUVEAU_VM_BIND ioctl. 3) Execute push buffers with the new DRM_IOCTL_NOUVEAU_EXEC ioctl. Both, DRM_IOCTL_NOUVEAU_VM_BIND and DRM_IOCTL_NOUVEAU_EXEC support asynchronous processing with DRM syncobjs as synchronization mechanism. The default DRM_IOCTL_NOUVEAU_VM_BIND is synchronous processing, DRM_IOCTL_NOUVEAU_EXEC supports asynchronous processing only. Reviewed-by: Faith Ekstrand <[email protected]> Reviewed-by: Dave Airlie <[email protected]> Co-developed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm/nouveau: fixup the uapi header file.Dave Airlie2-44/+45
nouveau > 10 years ago had a plan for new multiplexer inside a multiplexer API using nvif. It never fully reached fruition, fast forward 10 years, and the new vulkan driver is avoiding libdrm and calling ioctls, and these 3 ioctls, getparam, channel alloc + free don't seem to be things we'd want to use nvif for. Undeprecate and put them into the uapi header so we can just copy it into mesa later. v2: use uapi types. Reviewed-by: Faith Ekstrand <[email protected]> Signed-off-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm/gem: fix lockdep check for dma-resv lockDanilo Krummrich1-6/+9
When no custom lock is set to protect a GEMs GPUVA list, lockdep checks should fall back to the GEM objects dma-resv lock. With the current implementation we're setting the lock_dep_map of the GEM objects 'resv' pointer (in case no custom lock_dep_map is set yet) on drm_gem_private_object_init(). However, the GEM objects 'resv' pointer might still change after drm_gem_private_object_init() is called, e.g. through ttm_bo_init_reserved(). This can result in the wrong lock being tracked. To fix this, call dma_resv_held() directly from drm_gem_gpuva_assert_lock_held() and fall back to the GEMs lock_dep_map pointer only if an actual custom lock is set. Fixes: e6303f323b1a ("drm: manager to keep track of GPUs VA mappings") Reviewed-by: Dave Airlie <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04drm: Drop select FRAMEBUFFER_CONSOLE for DRM_FBDEV_EMULATIONJavier Martinez Canillas1-1/+0
The commit c242f48433e7 ("drm: Make FB_CORE to be selected if DRM fbdev emulation is enabled") changed DRM_FBDEV_EMULATION from 'depends on FB' to an effective 'select FB_CORE', so any config that previously had DRM=y and FB=n now has FB_CORE=y and FRAMEBUFFER_CONSOLE=y. This leads to unmet direct dependencies detected for FRAMEBUFFER_CONSOLE as reported by Arthur Grillo, e.g: WARNING: unmet direct dependencies detected for FRAMEBUFFER_CONSOLE Depends on [n]: VT [=n] && FB_CORE [=y] && !UML [=y] Selected by [y]: - DRM_FBDEV_EMULATION [=y] && HAS_IOMEM [=y] && DRM [=y] && !EXPERT [=n] Arnd Bergmann suggests to drop the select FRAMEBUFFER_CONSOLE for the DRM_FBDEV_EMULATION Kconfig symbol, since a possible use case could be to enable DRM fbdev emulation but without a framebuffer console. Fixes: c242f48433e7 ("drm: Make FB_CORE to be selected if DRM fbdev emulation is enabled") Reported-by: Arthur Grillo <[email protected]> Closes: https://lore.kernel.org/dri-devel/[email protected] Suggested-by: Arnd Bergmann <[email protected]> Signed-off-by: Javier Martinez Canillas <[email protected]> Acked-by: Daniel Vetter <[email protected]> Reviewed-by: Arthur Grillo <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04vfio-dev/mdpy-fb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Acked-by: Helge Deller <[email protected]> Cc: Kirti Wankhede <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04fbdev/xilinxfb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Acked-by: Helge Deller <[email protected]> Cc: Michal Simek <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04fbdev/vesafb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Acked-by: Helge Deller <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04fbdev/valkyriefb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Acked-by: Helge Deller <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04fbdev/uvesafb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Acked-by: Helge Deller <[email protected]> Cc: Michal Januszewski <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04fbdev/sunxvr2500: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Acked-by: Helge Deller <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2023-08-04fbdev/sunxvr1000: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Acked-by: Helge Deller <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]