Re: [Nouveau] [PATCH 3/3] drm/nouveau/pci: SOR crossbar quirk for 10b0:1b81

2018-02-05 Thread Danilo Krummrich
On 2018-02-05 03:47, Ben Skeggs wrote: On Mon, Feb 5, 2018 at 12:19 PM, Danilo Krummrich <danilokrummr...@dk-develop.de> wrote: On 2018-02-05 02:39, Ben Skeggs wrote: On 5 February 2018 at 11:37, Ben Skeggs <skeg...@gmail.com> wrote: On 5 February 2018 at 11:22, Dani

[Nouveau] [PATCH v2 2/3] drm/nouveau/disp: quirk for SOR crossbar routing

2018-02-05 Thread Danilo Krummrich
this issue, supply a quirk for such cards which prevents a dynamic mapping of SOR sublink and macro link and instead relies on identity mapping. Signed-off-by: Danilo Krummrich <danilokrummr...@dk-develop.de> --- v2: checking actual pad macro and link instead of outp index --- drivers/gpu/drm/n

[Nouveau] [PATCH v2 1/3] drm/nouveau/pci: PCI IDs for pascal architecture

2018-02-05 Thread Danilo Krummrich
Taken from NVIDIA binary driver (Linux 64-bit, revision 390.25) from README.txt. Signed-off-by: Danilo Krummrich <danilokrummr...@dk-develop.de> --- drivers/gpu/drm/nouveau/nvkm/engine/device/pci.c | 41 1 file changed, 41 insertions(+) diff --git a/drivers/g

[Nouveau] [PATCH v2 3/3] drm/nouveau/pci: SOR crossbar quirk for 10b0:1b81

2018-02-05 Thread Danilo Krummrich
link and instead use identity mapping. Signed-off-by: Danilo Krummrich <danilokrummr...@dk-develop.de> --- v2: quirk for the actual macro link instead of the outp index --- drivers/gpu/drm/nouveau/nvkm/engine/device/pci.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff

[Nouveau] [PATCH 1/3] drm/nouveau/pci: PCI IDs for pascal architecture

2018-02-04 Thread Danilo Krummrich
Taken from NVIDIA binary driver (Linux 64-bit, revision 390.25) from README.txt. Signed-off-by: Danilo Krummrich <danilokrummr...@dk-develop.de> --- drivers/gpu/drm/nouveau/nvkm/engine/device/pci.c | 41 1 file changed, 41 insertions(+) diff --git a/drivers/g

[Nouveau] [PATCH 3/3] drm/nouveau/pci: SOR crossbar quirk for 10b0:1b81

2018-02-04 Thread Danilo Krummrich
and instead use identity mapping. Signed-off-by: Danilo Krummrich <danilokrummr...@dk-develop.de> --- drivers/gpu/drm/nouveau/nvkm/engine/device/pci.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/device/pci.c b/drivers/g

[Nouveau] [PATCH 1/1] drm/nouveau/disp: prefer identity-mapped route of SOR <-> macro link

2018-02-05 Thread Danilo Krummrich
connected to a particular macro link not matching the identity of each other are causing failures. To fix this, when searching for a suitable SOR to be mapped to a macro link prefer a SOR which maps the identity of the macro link. Signed-off-by: Danilo Krummrich <danilokrummr...@dk-develop

[Nouveau] [PATCH 0/1] drm/nouveau/disp: prefer identity-mapped route of SOR <-> macro link

2018-02-05 Thread Danilo Krummrich
macro link over a random one instead of having my orignally proposed quirk. So here's the patch doing exactly that. Regards, Danilo Danilo Krummrich (1): drm/nouveau/disp: prefer identity-mapped route of SOR <-> macro link drivers/gpu/drm/nouveau/nvkm/engine/disp

Re: [Nouveau] [PATCH drm-misc-next 2/3] drm/gpuva_mgr: generalize dma_resv/extobj handling and GEM validation

2023-08-30 Thread Danilo Krummrich
On Wed, Aug 30, 2023 at 09:48:02AM +0200, Christian König wrote: > > > Am 20.08.23 um 23:53 schrieb Danilo Krummrich: > > So far the DRM GPUVA manager offers common infrastructure to track GPU VA > > allocations and mappings, generically connect GPU VA mappings to thei

Re: [Nouveau] [PATCH drm-misc-next 2/3] drm/gpuva_mgr: generalize dma_resv/extobj handling and GEM validation

2023-08-30 Thread Danilo Krummrich
Hi Thomas, thanks for having a look! On Wed, Aug 30, 2023 at 09:27:45AM +0200, Thomas Hellström (Intel) wrote: > Hi, Danilo. > > Some quick comments since I'm doing some Xe work in this area. Will probably > get back with more. > > On 8/20/23 23:53, Danilo Krummrich wrote:

Re: [Nouveau] [PATCH drm-misc-next v2 5/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-09-07 Thread Danilo Krummrich
On 9/7/23 10:42, Boris Brezillon wrote: On Wed, 6 Sep 2023 23:47:13 +0200 Danilo Krummrich wrote: +void drm_gpuvm_bo_destroy(struct kref *kref); I usually keep kref's release functions private so people are not tempted to use them. I think I did that because drm_gpuvm_bo_put() needs

Re: [Nouveau] [PATCH drm-misc-next v2 2/7] drm/gpuvm: rename struct drm_gpuva_manager to struct drm_gpuvm

2023-09-07 Thread Danilo Krummrich
On 9/7/23 09:56, Boris Brezillon wrote: On Wed, 6 Sep 2023 23:47:10 +0200 Danilo Krummrich wrote: Rename struct drm_gpuva_manager to struct drm_gpuvm including corresponding functions. This way the GPUVA manager's structures align very well with the documentation of VM_BIND [1] and VM_BIND

Re: [Nouveau] [PATCH drm-misc-next v2 5/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-09-07 Thread Danilo Krummrich
On 9/7/23 10:16, Boris Brezillon wrote: On Wed, 6 Sep 2023 23:47:13 +0200 Danilo Krummrich wrote: @@ -812,15 +967,20 @@ EXPORT_SYMBOL_GPL(drm_gpuva_remove); /** * drm_gpuva_link() - link a _gpuva * @va: the _gpuva to link + * @vm_bo: the _gpuvm_bo to add the _gpuva

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-11 Thread Danilo Krummrich
On Mon, Sep 11, 2023 at 04:45:26PM +0200, Boris Brezillon wrote: > On Sat, 9 Sep 2023 17:31:13 +0200 > Danilo Krummrich wrote: > > > @@ -807,6 +1262,14 @@ drm_gpuvm_bo_destroy(struct kref *kref) > > > > drm_gem_gpuva_assert_lock_held(vm_bo->obj); > &

Re: [Nouveau] [PATCH drm-misc-next v3 4/7] drm/gpuvm: common dma-resv per struct drm_gpuvm

2023-09-11 Thread Danilo Krummrich
On Mon, Sep 11, 2023 at 02:00:35PM +0200, Boris Brezillon wrote: > On Sat, 9 Sep 2023 17:31:11 +0200 > Danilo Krummrich wrote: > > > @@ -240,9 +240,22 @@ struct drm_gpuvm { > > * @ops: _gpuvm_ops providing the split/merge steps to drivers > > */ > >

Re: [Nouveau] [PATCH drm-misc-next v3 5/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-09-11 Thread Danilo Krummrich
Hi Thomas, On 9/11/23 19:19, Thomas Hellström wrote: Hi, Danilo On 9/9/23 17:31, Danilo Krummrich wrote: This patch adds an abstraction layer between the drm_gpuva mappings of a particular drm_gem_object and this GEM object itself. The abstraction represents a combination of a drm_gem_object

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-11 Thread Danilo Krummrich
On Mon, Sep 11, 2023 at 12:35:26PM +0200, Boris Brezillon wrote: > Hello Danilo, > > On Sat, 9 Sep 2023 17:31:13 +0200 > Danilo Krummrich wrote: > > > > @@ -632,6 +661,131 @@ > > * } > > */ > > > > +/** > > + * get_next_vm_bo_fro

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-14 Thread Danilo Krummrich
On 9/13/23 14:16, Danilo Krummrich wrote: And validate() can remove it while still holding all dma-resv locks, neat! However, what if two tasks are trying to lock the VA space concurrently? What do we do when the drm_gpuvm_bo's refcount drops to zero in drm_gpuva_unlink()? Are we guaranteed

[Nouveau] [PATCH] drm/nouveau: fence: fix type cast warning in nouveau_fence_emit()

2023-09-15 Thread Danilo Krummrich
Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nouveau_fence.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/nouveau/nouveau_fence.c b/drivers/gpu/drm/nouveau/nouveau_fence.c index 61d9e70da9fd..ca762ea55413 100644 --- a/drivers/gpu/drm/nouveau/nouve

Re: [Nouveau] [PATCH] nouveau/u_memcpya: fix NULL vs error pointer bug

2023-09-15 Thread Danilo Krummrich
Hi Dan, On 9/15/23 14:59, Dan Carpenter wrote: The u_memcpya() function is supposed to return error pointers on error. Returning NULL will lead to an Oops. Fixes: 68132cc6d1bc ("nouveau/u_memcpya: use vmemdup_user") Signed-off-by: Dan Carpenter --- drivers/gpu/drm/nouveau/nouveau_drv.h | 2

Re: [Nouveau] [PATCH 34/44] drm/nouveau/disp: add support for post-LT adjust

2023-09-15 Thread Danilo Krummrich
On 9/14/23 10:46, Ben Skeggs wrote: From: Ben Skeggs - fixes regression from previous commit From "drm/nouveau/disp: move link training out of supervisor"? I'd probably prefer to either re-order or combine them rather than having a regression in the series. Signed-off-by: Ben Skeggs ---

Re: [Nouveau] [PATCH 04/44] drm/nouveau/mmu/gp100-: always invalidate TLBs at CACHE_LEVEL_ALL

2023-09-15 Thread Danilo Krummrich
On 9/14/23 10:45, Ben Skeggs wrote: From: Ben Skeggs Fixes some issues when running on top of RM. Which issues have you seen in particular? Also, would it make sense to only invalidate TLBs at CACHE_LEVEL_ALL when actually running on top of RM? Signed-off-by: Ben Skeggs ---

Re: [Nouveau] [PATCH] nouveau/u_memcpya: fix NULL vs error pointer bug

2023-09-16 Thread Danilo Krummrich
On 9/16/23 16:26, Dan Carpenter wrote: On Sat, Sep 16, 2023 at 05:24:04PM +0300, Dan Carpenter wrote: On Sat, Sep 16, 2023 at 01:41:43AM +0200, Danilo Krummrich wrote: Hi Dan, On 9/15/23 14:59, Dan Carpenter wrote: The u_memcpya() function is supposed to return error pointers on error

[Nouveau] [PATCH] drm/nouveau: sched: fix leaking memory of timedout job

2023-09-16 Thread Danilo Krummrich
uAPI") Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nouveau_exec.c | 2 +- drivers/gpu/drm/nouveau/nouveau_sched.c | 12 +--- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/nouveau/nouveau_exec.c b/drivers/gpu/drm/nouveau/nouveau_ex

Re: [Nouveau] [PATCH drm-misc-next 2/3] drm/gpuva_mgr: generalize dma_resv/extobj handling and GEM validation

2023-08-31 Thread Danilo Krummrich
On Thu, Aug 31, 2023 at 06:53:01PM +0200, Thomas Hellström (Intel) wrote: > Hi, > > On 8/31/23 13:18, Danilo Krummrich wrote: > > On Thu, Aug 31, 2023 at 11:04:06AM +0200, Thomas Hellström (Intel) wrote: > > > Hi! > > > > > > On 8/30/23 17:00, Danilo Kru

Re: [Nouveau] [PATCH drm-misc-next 2/3] drm/gpuva_mgr: generalize dma_resv/extobj handling and GEM validation

2023-09-01 Thread Danilo Krummrich
On Fri, Sep 01, 2023 at 07:59:21AM +0200, Thomas Hellström (Intel) wrote: > > On 8/31/23 21:07, Danilo Krummrich wrote: > > On Thu, Aug 31, 2023 at 06:53:01PM +0200, Thomas Hellström (Intel) wrote: > > > Hi, > > > > > > On 8/31/23 13:18, Danilo Krummrich wr

Re: [Nouveau] [PATCH drm-misc-next 2/3] drm/gpuva_mgr: generalize dma_resv/extobj handling and GEM validation

2023-08-30 Thread Danilo Krummrich
On Wed, Aug 30, 2023 at 03:42:08PM +0200, Thomas Hellström (Intel) wrote: > > On 8/30/23 14:49, Danilo Krummrich wrote: > > Hi Thomas, > > > > thanks for having a look! > > > > On Wed, Aug 30, 2023 at 09:27:45AM +0200, Thomas Hellström (Intel) wrote: >

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-12 Thread Danilo Krummrich
On Tue, Sep 12, 2023 at 06:20:32PM +0200, Thomas Hellström wrote: > Hi, Danilo, > > On 9/9/23 17:31, Danilo Krummrich wrote: > > So far the DRM GPUVA manager offers common infrastructure to track GPU VA > > allocations and mappings, generically connect GPU VA mappings to thei

Re: [Nouveau] [PATCH drm-misc-next v3 5/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-09-12 Thread Danilo Krummrich
On Tue, Sep 12, 2023 at 09:42:44AM +0200, Thomas Hellström wrote: > Hi, Danilo > > On 9/11/23 19:49, Danilo Krummrich wrote: > > Hi Thomas, > > > > On 9/11/23 19:19, Thomas Hellström wrote: > > > Hi, Danilo > > > > > > On 9/9/23

Re: [Nouveau] [PATCH drm-misc-next v3 5/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-09-12 Thread Danilo Krummrich
On Tue, Sep 12, 2023 at 12:33:14PM +0200, Thomas Hellström wrote: > > On 9/12/23 12:06, Danilo Krummrich wrote: > > On Tue, Sep 12, 2023 at 09:42:44AM +0200, Thomas Hellström wrote: > > > Hi, Danilo > > > > > > On 9/11/23 19:49, Danilo Krummrich wrote: >

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-12 Thread Danilo Krummrich
On Tue, Sep 12, 2023 at 09:23:08PM +0200, Thomas Hellström wrote: > > On 9/12/23 18:50, Danilo Krummrich wrote: > > On Tue, Sep 12, 2023 at 06:20:32PM +0200, Thomas Hellström wrote: > > > Hi, Danilo, > > > > > > On 9/9/23 17:31, Danilo Krummrich wrote: >

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-13 Thread Danilo Krummrich
After some more discussion with Boris on IRC, he seems to be willing to drop GPUVM updates from the async path. If everyone agrees I'm fine to go ahead and drop this use case for GPUVM. @Thomas: I will reply to your last mail only considering GPUVM updates from within the IOCTL. - Danilo On

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-13 Thread Danilo Krummrich
As mentioned in a different mail thread, the reply is based on the assumption that we don't support anything else than GPUVM updates from the IOCTL. On Wed, Sep 13, 2023 at 11:14:46AM +0200, Thomas Hellström wrote: > Hi! > > On Wed, 2023-09-13 at 01:36 +0200, Danilo Krummrich wrote: &

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-13 Thread Danilo Krummrich
On 9/13/23 16:26, Christian König wrote: Am 13.09.23 um 14:16 schrieb Danilo Krummrich: As mentioned in a different mail thread, the reply is based on the assumption that we don't support anything else than GPUVM updates from the IOCTL. I think that this assumption is incorrect. Well, more

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-13 Thread Danilo Krummrich
On 9/13/23 17:33, Christian König wrote: Am 13.09.23 um 17:15 schrieb Danilo Krummrich: On 9/13/23 16:26, Christian König wrote: Am 13.09.23 um 14:16 schrieb Danilo Krummrich: As mentioned in a different mail thread, the reply is based on the assumption that we don't support anything else

[Nouveau] [PATCH drm-misc-next v3 1/7] drm/gpuvm: rename struct drm_gpuva_manager to struct drm_gpuvm

2023-09-09 Thread Danilo Krummrich
introduced for implementing a common dma-resv per GPU-VM including tracking of external and evicted objects in subsequent patches. [1] Documentation/gpu/drm-vm-bind-async.rst [2] Documentation/gpu/drm-vm-bind-locking.rst Cc: Thomas Hellström Cc: Matthew Brost Signed-off-by: Danilo Krummrich

[Nouveau] [PATCH drm-misc-next v3 3/7] drm/nouveau: uvmm: rename 'umgr' to 'base'

2023-09-09 Thread Danilo Krummrich
Rename struct drm_gpuvm within struct nouveau_uvmm from 'umgr' to base. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nouveau_debugfs.c | 2 +- drivers/gpu/drm/nouveau/nouveau_exec.c| 4 +-- drivers/gpu/drm/nouveau/nouveau_uvmm.c| 32 +++ drivers/gpu

[Nouveau] [PATCH drm-misc-next v3 5/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-09-09 Thread Danilo Krummrich
, hence the credit for this idea goes to the developers of amdgpu. Cc: Christian König Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuvm.c| 304 ++--- drivers/gpu/drm/nouveau/nouveau_uvmm.c | 68 -- include/drm/drm_gem.h | 32

[Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-09 Thread Danilo Krummrich
ctionality and opt-in for other features without setting any feature flags, just by making use of the corresponding functions. Big kudos to Boris Brezillon for his help to figure out locking for drivers updating the GPU VA space within the fence signalling path. Suggested-by: Matthew Brost Signed-off-

[Nouveau] [PATCH drm-misc-next v3 0/7] [RFC] DRM GPUVA Manager GPU-VM features

2023-09-09 Thread Danilo Krummrich
s list in drm_gpuvm_bo_destroy() - add more documentation and fix some kernel doc issues Danilo Krummrich (7): drm/gpuvm: rename struct drm_gpuva_manager to struct drm_gpuvm drm/gpuvm: allow building as module drm/nouveau: uvmm: rename 'umgr' to 'base' drm/gpuvm: common dma-resv per struct drm_gpuvm

[Nouveau] [PATCH drm-misc-next v3 2/7] drm/gpuvm: allow building as module

2023-09-09 Thread Danilo Krummrich
Currently, the DRM GPUVM does not have any core dependencies preventing a module build. Also, new features from subsequent patches require helpers (namely drm_exec) which can be built as module. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/Kconfig | 7 +++ drivers/gpu/drm

[Nouveau] [PATCH drm-misc-next v3 4/7] drm/gpuvm: common dma-resv per struct drm_gpuvm

2023-09-09 Thread Danilo Krummrich
Provide a common dma-resv for GEM objects not being used outside of this GPU-VM. This is used in a subsequent patch to generalize dma-resv, external and evicted object handling and GEM validation. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuvm.c| 10

[Nouveau] [PATCH drm-misc-next v3 7/7] drm/nouveau: GPUVM dma-resv/extobj handling, GEM validation

2023-09-09 Thread Danilo Krummrich
Make use of the DRM GPUVA managers GPU-VM common dma-resv, external GEM object tracking, dma-resv locking, evicted GEM object tracking and validation features. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nouveau_bo.c| 4 +- drivers/gpu/drm/nouveau/nouveau_exec.c | 52

[Nouveau] [PATCH drm-misc-next] drm/nouveau: fence: fix undefined fence state after emit

2023-08-29 Thread Danilo Krummrich
actually need to pre-allocate. Fixes: 7f2a0b50b2b2 ("drm/nouveau: fence: separate fence alloc and emit") Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/dispnv04/crtc.c | 9 +-- drivers/gpu/drm/nouveau/nouveau_bo.c| 8 +-- drivers/gpu/drm/nouveau/nouveau_ch

Re: [Nouveau] [PATCH drm-misc-next 2/3] drm/gpuva_mgr: generalize dma_resv/extobj handling and GEM validation

2023-08-31 Thread Danilo Krummrich
On Thu, Aug 31, 2023 at 11:04:06AM +0200, Thomas Hellström (Intel) wrote: > Hi! > > On 8/30/23 17:00, Danilo Krummrich wrote: > > On Wed, Aug 30, 2023 at 03:42:08PM +0200, Thomas Hellström (Intel) wrote: > > > On 8/30/23 14:49, Danilo Krummrich wrote: > > > >

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-14 Thread Danilo Krummrich
On 9/14/23 15:48, Thomas Hellström wrote: Hi, Danilo Some additional minor comments as xe conversion progresses. On 9/9/23 17:31, Danilo Krummrich wrote: So far the DRM GPUVA manager offers common infrastructure to track GPU VA allocations and mappings, generically connect GPU VA mappings

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-14 Thread Danilo Krummrich
On 9/14/23 13:32, Thomas Hellström wrote: On 9/14/23 12:57, Danilo Krummrich wrote: On 9/13/23 14:16, Danilo Krummrich wrote: And validate() can remove it while still holding all dma-resv locks, neat! However, what if two tasks are trying to lock the VA space concurrently? What do we do

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-14 Thread Danilo Krummrich
On 9/14/23 19:13, Thomas Hellström wrote: On Thu, 2023-09-14 at 17:27 +0200, Danilo Krummrich wrote: On 9/14/23 13:32, Thomas Hellström wrote: On 9/14/23 12:57, Danilo Krummrich wrote: On 9/13/23 14:16, Danilo Krummrich wrote: And validate() can remove it while still holding all dma

Re: [Nouveau] [PATCH drm-misc-next v3 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-14 Thread Danilo Krummrich
On 9/14/23 19:21, Thomas Hellström wrote: On Thu, 2023-09-14 at 18:36 +0200, Danilo Krummrich wrote: On 9/14/23 15:48, Thomas Hellström wrote: Hi, Danilo Some additional minor comments as xe conversion progresses. On 9/9/23 17:31, Danilo Krummrich wrote: So far the DRM GPUVA manager offers

Re: [Nouveau] [PATCH drm-misc-next 2/3] drm/gpuva_mgr: generalize dma_resv/extobj handling and GEM validation

2023-09-06 Thread Danilo Krummrich
On 9/1/23 14:10, Danilo Krummrich wrote: On Fri, Sep 01, 2023 at 07:59:21AM +0200, Thomas Hellström (Intel) wrote: On 8/31/23 21:07, Danilo Krummrich wrote: On Thu, Aug 31, 2023 at 06:53:01PM +0200, Thomas Hellström (Intel) wrote: Hi, On 8/31/23 13:18, Danilo Krummrich wrote: On Thu, Aug

[Nouveau] [PATCH drm-misc-next v2 2/7] drm/gpuvm: rename struct drm_gpuva_manager to struct drm_gpuvm

2023-09-06 Thread Danilo Krummrich
introduced for implementing a common dma-resv per GPU-VM including tracking of external and evicted objects in subsequent patches. [1] Documentation/gpu/drm-vm-bind-async.rst [2] Documentation/gpu/drm-vm-bind-locking.rst Cc: Thomas Hellström Cc: Matthew Brost Signed-off-by: Danilo Krummrich

[Nouveau] [PATCH drm-misc-next v2 3/7] drm/nouveau: uvmm: rename 'umgr' to 'base'

2023-09-06 Thread Danilo Krummrich
Rename struct drm_gpuvm within struct nouveau_uvmm from 'umgr' to base. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nouveau_debugfs.c | 2 +- drivers/gpu/drm/nouveau/nouveau_exec.c| 4 +-- drivers/gpu/drm/nouveau/nouveau_uvmm.c| 32 +++ drivers/gpu

[Nouveau] [PATCH drm-misc-next v2 0/7] [RFC] DRM GPUVA Manager GPU-VM features

2023-09-06 Thread Danilo Krummrich
odule, rather than drm_exec builtin (Christian) Danilo Krummrich (7): drm: gpuva_mgr: allow building as module drm/gpuvm: rename struct drm_gpuva_manager to struct drm_gpuvm drm/nouveau: uvmm: rename 'umgr' to 'base' drm/gpuvm: common dma-resv per struct drm_gpuvm drm/gpuvm: add a

[Nouveau] [PATCH drm-misc-next v2 1/7] drm: gpuva_mgr: allow building as module

2023-09-06 Thread Danilo Krummrich
Currently, the DRM GPUVA manager does not have any core dependencies preventing a module build. Also, new features from subsequent patches require helpers (namely drm_exec) which can be built as module. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/Kconfig | 7 +++ drivers

[Nouveau] [PATCH drm-misc-next v2 5/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-09-06 Thread Danilo Krummrich
, hence the credit for this idea goes to the developers of amdgpu. Cc: Christian König Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuva_mgr.c| 210 +++-- drivers/gpu/drm/nouveau/nouveau_uvmm.c | 77 ++--- include/drm/drm_gem.h | 48

[Nouveau] [PATCH drm-misc-next v2 6/7] drm/gpuvm: generalize dma_resv/extobj handling and GEM validation

2023-09-06 Thread Danilo Krummrich
ctionality and opt-in for other features without setting any feature flags, just by making use of the corresponding functions. Suggested-by: Matthew Brost Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuva_mgr.c | 335 +++- include/drm/drm_gpuva_mgr.h

[Nouveau] [PATCH drm-misc-next v2 4/7] drm/gpuvm: common dma-resv per struct drm_gpuvm

2023-09-06 Thread Danilo Krummrich
Provide a common dma-resv for GEM objects not being used outside of this GPU-VM. This is used in a subsequent patch to generalize dma-resv, external and evicted object handling and GEM validation. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuva_mgr.c| 10

[Nouveau] [PATCH drm-misc-next v2 7/7] drm/nouveau: GPUVM dma-resv/extobj handling, GEM validation

2023-09-06 Thread Danilo Krummrich
Make use of the DRM GPUVA managers GPU-VM common dma-resv, external GEM object tracking, dma-resv locking, evicted GEM object tracking and validation features. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nouveau_bo.c| 4 +- drivers/gpu/drm/nouveau/nouveau_exec.c | 52

Re: [Nouveau] [PATCH drm-misc-next v6 1/6] drm/gpuvm: add common dma-resv per struct drm_gpuvm

2023-10-13 Thread Danilo Krummrich
On 10/13/23 13:38, Thomas Hellström wrote: On Mon, 2023-10-09 at 01:32 +0200, Danilo Krummrich wrote: Provide a common dma-resv for GEM objects not being used outside of this GPU-VM. This is used in a subsequent patch to generalize dma-resv, external and evicted object handling and GEM

Re: [Nouveau] [PATCH drm-misc-next v6 4/6] drm/gpuvm: track/lock/validate external/evicted objects

2023-10-13 Thread Danilo Krummrich
On 10/10/23 08:26, Thomas Hellström wrote: On 10/9/23 16:45, Danilo Krummrich wrote: On 10/9/23 15:36, Thomas Hellström wrote: On 10/9/23 01:32, Danilo Krummrich wrote: Currently the DRM GPUVM offers common infrastructure to track GPU VA allocations and mappings, generically connect GPU VA

Re: [Nouveau] [PATCH drm-misc-next v6 4/6] drm/gpuvm: track/lock/validate external/evicted objects

2023-10-13 Thread Danilo Krummrich
On 10/10/23 08:40, Thomas Hellström wrote: On 10/9/23 01:32, Danilo Krummrich wrote: Currently the DRM GPUVM offers common infrastructure to track GPU VA allocations and mappings, generically connect GPU VA mappings to their backing buffers and perform more complex mapping operations

Re: [Nouveau] [PATCH drm-misc-next v6 3/6] drm/gpuvm: add an abstraction for a VM / BO combination

2023-10-17 Thread Danilo Krummrich
On Fri, Oct 13, 2023 at 02:30:29PM +0200, Thomas Hellström wrote: > On Mon, 2023-10-09 at 01:32 +0200, Danilo Krummrich wrote: > > Add an abstraction layer between the drm_gpuva mappings of a > > particular > > drm_gem_object and this GEM object itself. The a

Re: [Nouveau] [PATCH drm-misc-next v6 1/6] drm/gpuvm: add common dma-resv per struct drm_gpuvm

2023-10-17 Thread Danilo Krummrich
On 10/13/23 15:00, Thomas Hellström wrote: On Fri, 2023-10-13 at 13:51 +0200, Danilo Krummrich wrote: On 10/13/23 13:38, Thomas Hellström wrote: On Mon, 2023-10-09 at 01:32 +0200, Danilo Krummrich wrote: Provide a common dma-resv for GEM objects not being used outside of this GPU-VM

Re: [Nouveau] [PATCH drm-misc-next v7 4/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-11-01 Thread Danilo Krummrich
On 11/1/23 17:38, Thomas Hellström wrote: On Tue, 2023-10-31 at 18:38 +0100, Danilo Krummrich wrote: On 10/31/23 11:32, Thomas Hellström wrote: On Mon, 2023-10-23 at 22:16 +0200, Danilo Krummrich wrote: Add an abstraction layer between the drm_gpuva mappings of a particular drm_gem_object

Re: [Nouveau] [PATCH drm-misc-next v7 4/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-11-01 Thread Danilo Krummrich
On 11/1/23 10:56, Thomas Hellström wrote: On Wed, 2023-11-01 at 10:41 +0100, Thomas Hellström wrote: Hi, Danilo, On Tue, 2023-10-31 at 18:52 +0100, Danilo Krummrich wrote: On 10/31/23 17:45, Thomas Hellström wrote: On Tue, 2023-10-31 at 17:39 +0100, Danilo Krummrich wrote: On 10/31/23 12:25

[Nouveau] [PATCH drm-misc-next v8 11/12] drm/gpuvm: track/lock/validate external/evicted objects

2023-11-01 Thread Danilo Krummrich
Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuvm.c | 633 include/drm/drm_gpuvm.h | 250 ++ 2 files changed, 883 insertions(+) diff --git a/drivers/gpu/drm/drm_gpuvm.c b/drivers/gpu/drm/drm_gpuvm.c index 2c8fdefb19f0..d289282693ec

[Nouveau] [PATCH drm-misc-next v8 12/12] drm/nouveau: use GPUVM common infrastructure

2023-11-01 Thread Danilo Krummrich
the GPUVM's GEM objects. Hence, make us of it. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nouveau_bo.c| 4 +- drivers/gpu/drm/nouveau/nouveau_exec.c | 57 -- drivers/gpu/drm/nouveau/nouveau_exec.h | 4 - drivers/gpu/drm/nouveau/nouveau_sched.c | 9 ++- drivers

[Nouveau] [PATCH drm-misc-next v8 10/12] drm/gpuvm: add an abstraction for a VM / BO combination

2023-11-01 Thread Danilo Krummrich
for this idea goes to the developers of amdgpu. Cc: Christian König Reviewed-by: Boris Brezillon Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuvm.c| 336 + drivers/gpu/drm/nouveau/nouveau_uvmm.c | 63 +++-- include/drm/drm_gem.h

[Nouveau] [PATCH drm-misc-next v8 05/12] drm/gpuvm: add common dma-resv per struct drm_gpuvm

2023-11-01 Thread Danilo Krummrich
Provide a common dma-resv for GEM objects not being used outside of this GPU-VM. This is used in a subsequent patch to generalize dma-resv, external and evicted object handling and GEM validation. Reviewed-by: Boris Brezillon Reviewed-by: Thomas Hellström Signed-off-by: Danilo Krummrich

[Nouveau] [PATCH drm-misc-next v8 06/12] drm/nouveau: make use of the GPUVM's shared dma-resv

2023-11-01 Thread Danilo Krummrich
er to make sure the object proving the shared dma-resv can't be freed up before the objects making use of it, let every such GEM object take a reference on it. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nouveau_bo.c | 11 +-- drivers/gpu/drm/nouveau/nouveau_bo.h | 5

[Nouveau] [PATCH drm-misc-next v8 07/12] drm/gpuvm: add drm_gpuvm_flags to drm_gpuvm

2023-11-01 Thread Danilo Krummrich
Introduce flags for struct drm_gpuvm, this required by subsequent commits. Reviewed-by: Boris Brezillon Reviewed-by: Thomas Hellström Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuvm.c| 3 +++ drivers/gpu/drm/nouveau/nouveau_uvmm.c | 2 +- include/drm/drm_gpuvm.h

[Nouveau] [PATCH drm-misc-next v8 08/12] drm/nouveau: separately allocate struct nouveau_uvmm

2023-11-01 Thread Danilo Krummrich
Allocate struct nouveau_uvmm separately in preparation for subsequent commits introducing reference counting for struct drm_gpuvm. While at it, get rid of nouveau_uvmm_init() as indirection of nouveau_uvmm_ioctl_vm_init() and perform some minor cleanups. Signed-off-by: Danilo Krummrich

[Nouveau] [PATCH drm-misc-next v8 02/12] drm/gpuvm: don't always WARN in drm_gpuvm_check_overflow()

2023-11-01 Thread Danilo Krummrich
Don't always WARN in drm_gpuvm_check_overflow() and separate it into a drm_gpuvm_check_overflow() and a dedicated drm_gpuvm_warn_check_overflow() variant. This avoids printing warnings due to invalid userspace requests. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuvm.c | 20

[Nouveau] [PATCH drm-misc-next v8 03/12] drm/gpuvm: export drm_gpuvm_range_valid()

2023-11-01 Thread Danilo Krummrich
Drivers may use this function to validate userspace requests in advance, hence export it. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuvm.c | 14 +- include/drm/drm_gpuvm.h | 1 + 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm

[Nouveau] [PATCH drm-misc-next v8 04/12] drm/nouveau: make use of drm_gpuvm_range_valid()

2023-11-01 Thread Danilo Krummrich
Use drm_gpuvm_range_valid() in order to validate userspace requests. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nouveau_uvmm.c | 17 + drivers/gpu/drm/nouveau/nouveau_uvmm.h | 3 --- 2 files changed, 1 insertion(+), 19 deletions(-) diff --git a/drivers/gpu/drm

Re: [Nouveau] [PATCH drm-misc-next v7 4/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-11-01 Thread Danilo Krummrich
On 11/1/23 20:45, Thomas Hellström wrote: On Wed, 2023-11-01 at 18:21 +0100, Danilo Krummrich wrote: On 11/1/23 17:38, Thomas Hellström wrote: On Tue, 2023-10-31 at 18:38 +0100, Danilo Krummrich wrote: On 10/31/23 11:32, Thomas Hellström wrote: On Mon, 2023-10-23 at 22:16 +0200, Danilo

[Nouveau] [PATCH drm-misc-next v8 00/12] [RFC] DRM GPUVM features

2023-11-01 Thread Danilo Krummrich
missing doc comment regarding a drm_gpuvm_bo's gpuva list (Thomas) - reference count struct drm_gpuvm, this avoids having (odd) rules when dealing with a drm_gpuvm_bo's gpuvm pointer Danilo Krummrich (12): drm/gpuvm: convert WARN() to drm_WARN() variants drm/gpuvm: don't always WA

[Nouveau] [PATCH drm-misc-next v8 01/12] drm/gpuvm: convert WARN() to drm_WARN() variants

2023-11-01 Thread Danilo Krummrich
Use drm_WARN() and drm_WARN_ON() variants to indicate drivers the context the failing VM resides in. Reviewed-by: Boris Brezillon Reviewed-by: Thomas Hellström Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuvm.c| 32 ++ drivers/gpu/drm/nouveau

Re: [Nouveau] [PATCH drm-misc-next v7 4/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-10-31 Thread Danilo Krummrich
On 10/31/23 11:32, Thomas Hellström wrote: On Mon, 2023-10-23 at 22:16 +0200, Danilo Krummrich wrote: Add an abstraction layer between the drm_gpuva mappings of a particular drm_gem_object and this GEM object itself. The abstraction represents a combination of a drm_gem_object and drm_gpuvm

Re: [Nouveau] [PATCH drm-misc-next v7 4/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-10-31 Thread Danilo Krummrich
On 10/31/23 17:45, Thomas Hellström wrote: On Tue, 2023-10-31 at 17:39 +0100, Danilo Krummrich wrote: On 10/31/23 12:25, Thomas Hellström wrote: On Mon, 2023-10-23 at 22:16 +0200, Danilo Krummrich wrote: Add an abstraction layer between the drm_gpuva mappings of a particular drm_gem_object

Re: [Nouveau] [PATCH drm-misc-next v7 4/7] drm/gpuvm: add an abstraction for a VM / BO combination

2023-10-31 Thread Danilo Krummrich
On 10/31/23 17:50, Thomas Hellström wrote: On Tue, 2023-10-31 at 17:30 +0100, Danilo Krummrich wrote: On 10/31/23 12:45, Jani Nikula wrote: On Tue, 31 Oct 2023, Thomas Hellström wrote: On Mon, 2023-10-23 at 22:16 +0200, Danilo Krummrich wrote: + * Returns: a pointer to the _gpuvm_bo

Re: [Nouveau] [PATCH drm-misc-next v8 09/12] drm/gpuvm: reference count drm_gpuvm structures

2023-11-02 Thread Danilo Krummrich
Hi Thomas, thanks for your timely response on that! On 11/2/23 18:09, Thomas Hellström wrote: On Thu, 2023-11-02 at 00:31 +0100, Danilo Krummrich wrote: Implement reference counting for struct drm_gpuvm. Signed-off-by: Danilo Krummrich ---  drivers/gpu/drm/drm_gpuvm.c    | 44

Re: [Nouveau] nouveau/gsp: move to latest fw and small fixes

2023-11-02 Thread Danilo Krummrich
For the series: Reviewed-by: Danilo Krummrich On 10/31/23 06:18, Dave Airlie wrote: This moves Ben's work to the latest GSP stable firmware 535.113.01. We will be stuck on this for a while. There is also a fix for a message signature, and additions of two registry entries, which seem to help

[Nouveau] [PATCH] drm/nouveau/gr/gf100-: unlock mutex failing to create golden context

2023-11-02 Thread Danilo Krummrich
Do not return from gf100_gr_chan_new() with fecs mutex held when failing to create the golden context image. Cc: # v6.2+ Fixes: ca081fff6ecc ("drm/nouveau/gr/gf100-: generate golden context during first object alloc") Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nvkm

Re: [Nouveau] [PATCH drm-misc-next v8 09/12] drm/gpuvm: reference count drm_gpuvm structures

2023-11-03 Thread Danilo Krummrich
On 11/3/23 15:04, Christian König wrote: Am 03.11.23 um 14:14 schrieb Danilo Krummrich: On Fri, Nov 03, 2023 at 08:18:35AM +0100, Christian König wrote: Am 02.11.23 um 00:31 schrieb Danilo Krummrich: Implement reference counting for struct drm_gpuvm. From the design point of view what

Re: [Nouveau] [PATCH drm-misc-next v8 09/12] drm/gpuvm: reference count drm_gpuvm structures

2023-11-03 Thread Danilo Krummrich
On Fri, Nov 03, 2023 at 08:18:35AM +0100, Christian König wrote: > Am 02.11.23 um 00:31 schrieb Danilo Krummrich: > > Implement reference counting for struct drm_gpuvm. > > From the design point of view what is that good for? It was discussed in this thread [1]. Essentially, the

Re: [Nouveau] [PATCH] nouveau/gsp/r535: uninitialized variable in r535_gsp_acpi_mux_id()

2023-11-07 Thread Danilo Krummrich
) Signed-off-by: Dan Carpenter Good catch! Reviewed-by: Danilo Krummrich @Dave: Can't pick this patch up myself, since this should probably go into drm/topic/nvidia-gsp. --- drivers/gpu/drm/nouveau/nvkm/subdev/gsp/r535.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drive

Re: [Nouveau] [bug report] drm/nouveau/mmu/r535: initial support

2023-11-07 Thread Danilo Krummrich
On 11/7/23 16:17, Dan Carpenter wrote: On Tue, Nov 07, 2023 at 03:06:27PM +, Timur Tabi wrote: On Tue, 2023-11-07 at 17:32 +0300, Dan Carpenter wrote:     170 ret = gf100_bar_new_(rm, device, type, inst, ); --> 171 *pbar = bar;     172 if (ret) {     173  

Re: [Nouveau] [bug report] drm/nouveau/gsp/r535: add support for booting GSP-RM

2023-11-07 Thread Danilo Krummrich
On 11/7/23 15:34, Dan Carpenter wrote: Hello Ben Skeggs, The patch 176fdcbddfd2: "drm/nouveau/gsp/r535: add support for booting GSP-RM" from Sep 19, 2023 (linux-next), leads to the following Smatch static checker warning: drivers/gpu/drm/nouveau/nvkm/subdev/gsp/r535.c:1016

Re: [Nouveau] [bug report] drm/nouveau/gsp/r535: add support for booting GSP-RM

2023-11-07 Thread Danilo Krummrich
On 11/7/23 20:00, Danilo Krummrich wrote: On 11/7/23 15:34, Dan Carpenter wrote: Hello Ben Skeggs, The patch 176fdcbddfd2: "drm/nouveau/gsp/r535: add support for booting GSP-RM" from Sep 19, 2023 (linux-next), leads to the following Smatch static checker warning: drivers/gpu/d

Re: [Nouveau] [bug report] drm/nouveau/mmu/r535: initial support

2023-11-07 Thread Danilo Krummrich
On 11/7/23 19:17, Timur Tabi wrote: On Tue, 2023-11-07 at 19:11 +0100, Danilo Krummrich wrote: I think the problem already starts with gf100_bar_new_() not setting its pbar argument to NULL on failure, but this code assuming that. Isn't it standard procedure for functions not to write

Re: [Nouveau] [PATCH] nouveau: use an rwlock for the event lock.

2023-11-07 Thread Danilo Krummrich
9 dg1test kernel: RBP: 7ffdd3c48490 R08: 55bb75873b10 R09: 0001 Aug 10 07:01:29 dg1test kernel: R10: 0004 R11: 55bb7587f000 R12: 55bb75887490 Aug 10 07:01:29 dg1test kernel: R13: 55bb757f6280 R14: 55bb758875c0 R15: 55bb757f6280 Aug 10 07:01:29 dg1test ke

Re: [Nouveau] [PATCH] nouveau/gsp: fix UBSAN array bounds warning in PACKED_REGISTRY_TABLE

2023-11-07 Thread Danilo Krummrich
On 11/8/23 00:47, Timur Tabi wrote: Change PACKED_REGISTRY_TABLE so that its last member is a variable-length array instead of a zero-length array. UBSAN treats zero-length arrays literally and warns if they are dereferenced. Changing the "[0]" to "[]" tells the compiler that the array is

[Nouveau] [PATCH drm-misc-next v9 10/12] drm/gpuvm: add an abstraction for a VM / BO combination

2023-11-07 Thread Danilo Krummrich
for this idea goes to the developers of amdgpu. Cc: Christian König Reviewed-by: Thomas Hellström Reviewed-by: Boris Brezillon Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuvm.c| 340 + drivers/gpu/drm/nouveau/nouveau_uvmm.c | 63

[Nouveau] [PATCH drm-misc-next v9 11/12] drm/gpuvm: track/lock/validate external/evicted objects

2023-11-07 Thread Danilo Krummrich
Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuvm.c | 633 include/drm/drm_gpuvm.h | 250 ++ 2 files changed, 883 insertions(+) diff --git a/drivers/gpu/drm/drm_gpuvm.c b/drivers/gpu/drm/drm_gpuvm.c index 7e193bca8bab..54f5e8851de5

[Nouveau] [PATCH drm-misc-next v9 12/12] drm/nouveau: use GPUVM common infrastructure

2023-11-07 Thread Danilo Krummrich
the GPUVM's GEM objects. Hence, make us of it. Reviewed-by: Dave Airlie Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nouveau_bo.c| 4 +- drivers/gpu/drm/nouveau/nouveau_exec.c | 57 -- drivers/gpu/drm/nouveau/nouveau_exec.h | 4 - drivers/gpu/drm/nouveau

[Nouveau] [PATCH drm-misc-next v9 08/12] drm/nouveau: separately allocate struct nouveau_uvmm

2023-11-07 Thread Danilo Krummrich
-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nouveau_drm.c | 5 +- drivers/gpu/drm/nouveau/nouveau_drv.h | 10 ++-- drivers/gpu/drm/nouveau/nouveau_uvmm.c | 63 +- drivers/gpu/drm/nouveau/nouveau_uvmm.h | 4 -- 4 files changed, 40 insertions(+), 42 deletions(-) diff

[Nouveau] [PATCH drm-misc-next v9 09/12] drm/gpuvm: reference count drm_gpuvm structures

2023-11-07 Thread Danilo Krummrich
Implement reference counting for struct drm_gpuvm. Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/drm_gpuvm.c| 56 +- drivers/gpu/drm/nouveau/nouveau_uvmm.c | 20 ++--- include/drm/drm_gpuvm.h| 31 +- 3 files changed, 90

[Nouveau] [PATCH drm-misc-next v9 00/12] [RFC] DRM GPUVM features

2023-11-07 Thread Danilo Krummrich
m->ops->vm_free - fix doc comment of drm_gpuvm_put() - fix reference leak in drm_gpuva_insert() - document drm_gpuvm_put() may be called from atomic context - document drm_gpuvm_bo_put() may only be called from non-atomic context + add a might_sleep() Danilo Krummrich (12): drm/gpuvm

[Nouveau] [PATCH drm-misc-next v9 04/12] drm/nouveau: make use of drm_gpuvm_range_valid()

2023-11-07 Thread Danilo Krummrich
Use drm_gpuvm_range_valid() in order to validate userspace requests. Reviewed-by: Dave Airlie Signed-off-by: Danilo Krummrich --- drivers/gpu/drm/nouveau/nouveau_uvmm.c | 17 + drivers/gpu/drm/nouveau/nouveau_uvmm.h | 3 --- 2 files changed, 1 insertion(+), 19 deletions

  1   2   3   4   5   6   >