[PATCH libdrm 5/7] expose timeline signal/export/import interfaces v2

2019-05-13 Thread Chunming Zhou
v2: adapt to new one transfer ioctl Signed-off-by: Chunming Zhou Acked-by: Christian König --- amdgpu/amdgpu-symbol-check | 3 ++ amdgpu/amdgpu.h| 51 amdgpu/amdgpu_cs.c | 68 ++ 3 files changed, 122

[PATCH libdrm 2/7] add timeline wait/query ioctl v2

2019-05-13 Thread Chunming Zhou
v2: drop export/import Signed-off-by: Chunming Zhou --- xf86drm.c | 44 xf86drm.h | 6 ++ 2 files changed, 50 insertions(+) diff --git a/xf86drm.c b/xf86drm.c index 2c19376b..17e3d880 100644 --- a/xf86drm.c +++ b/xf86drm.c @@ -4256,3 +4256,47

[PATCH libdrm 7/7] add syncobj timeline tests v3

2019-05-13 Thread Chunming Zhou
v2: drop DRM_SYNCOBJ_CREATE_TYPE_TIMELINE, fix timeout calculation, fix some warnings v3: add export/import and cpu signal testing cases Signed-off-by: Chunming Zhou Acked-by: Christian König --- tests/amdgpu/Makefile.am | 3 +- tests/amdgpu/amdgpu_test.c | 11 ++ tests/amdgpu

[PATCH libdrm 3/7] wrap syncobj timeline query/wait APIs for amdgpu v3

2019-05-13 Thread Chunming Zhou
v2: symbos are stored in lexical order. v3: drop export/import and extra query indirection Signed-off-by: Chunming Zhou Acked-by: Christian König --- amdgpu/amdgpu-symbol-check | 2 ++ amdgpu/amdgpu.h| 39 ++ amdgpu/amdgpu_cs.c | 23

Re: [PATCH 06/10] drm/ttm: fix busy memory to fail other user v10

2019-05-23 Thread Chunming Zhou
在 2019/5/23 19:03, Christian König 写道: > [CAUTION: External Email] > > Am 23.05.19 um 12:24 schrieb zhoucm1: >> >> >> On 2019年05月22日 20:59, Christian König wrote: >>> [CAUTION: External Email] >>> >>> BOs on the LRU might be blocked during command submission >>> and cause OOM situations. >>> >>> A

[PATCH] drm/amdgpu: add DRIVER_SYNCOBJ_TIMELINE to amdgpu

2019-05-27 Thread Chunming Zhou
Change-Id: I2b1af1478fbddbb5084b90b3ff85c2eb964bd217 Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c index

[PATCH 1/2] drm: rename null fence to stub fence in syncobj

2018-08-22 Thread Chunming Zhou
stub fence will be used by timeline syncobj as well. Change-Id: Ia4252f03c07a8105491d2791dc7c8c6976682285 Signed-off-by: Chunming Zhou Cc: Jason Ekstrand --- drivers/gpu/drm/drm_syncobj.c | 28 ++-- include/drm/drm_syncobj.h | 24 2 files

[PATCH 2/2] [RFC]drm: add syncobj timeline support

2018-08-22 Thread Chunming Zhou
n can wait on any point of timeline, so need a RB tree to order them. And wait PT could ahead of signal PT, we need a sumission fence to perform that. TODO: CPU query and wait on timeline semaphore. Change-Id: I9f09aae225e268442c30451badac40406f24262c Signed-off-by: Chunming Zhou Cc: Christian

[PATCH 1/5] drm: fix syncobj null_fence_enable_signaling

2018-08-23 Thread Chunming Zhou
That is certainly totally nonsense. dma_fence_enable_sw_signaling() is the function who is calling this callback. Signed-off-by: Chunming Zhou Cc: Jason Ekstrand --- drivers/gpu/drm/drm_syncobj.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/gpu/drm/drm_syncobj.c b/drivers/gpu/drm

[PATCH 2/5] drm: rename null fence to stub fence in syncobj

2018-08-23 Thread Chunming Zhou
stub fence will be used by timeline syncobj as well. Signed-off-by: Chunming Zhou Cc: Jason Ekstrand --- drivers/gpu/drm/drm_syncobj.c | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/gpu/drm/drm_syncobj.c b/drivers/gpu/drm/drm_syncobj.c index

[PATCH 4/5] drm: expand replace_fence to support timeline point

2018-08-23 Thread Chunming Zhou
we can place a fence to a timeline point after expanded. Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/drm_syncobj.c | 16 +--- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 2 +- drivers/gpu/drm/v3d/v3d_gem.c

[PATCH 3/5] drm: expand drm_syncobj_find_fence to support timeline point

2018-08-23 Thread Chunming Zhou
we can fetch timeline point fence after expanded. Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/drm_syncobj.c | 6 -- drivers/gpu/drm/v3d/v3d_gem.c | 4 ++-- drivers/gpu/drm/vc4/vc4_gem.c | 2 +- include/drm

[PATCH 5/5] drm: add syncobj timeline support v2

2018-08-23 Thread Chunming Zhou
etter) TODO: 1. CPU query and wait on timeline semaphore. 2. test application (Daniel Vetter) Signed-off-by: Chunming Zhou Cc: Christian Konig Cc: Dave Airlie Cc: Daniel Rakos Cc: Daniel Vetter --- drivers/gpu/drm/drm_syncobj.c | 383 +++--- includ

[PATCH 1/8] drm: fix syncobj null_fence_enable_signaling

2018-08-24 Thread Chunming Zhou
That is certainly totally nonsense. dma_fence_enable_sw_signaling() is the function who is calling this callback. Signed-off-by: Chunming Zhou Cc: Jason Ekstrand Reviewed-by: Christian König Acked-by: Daniel Vetter --- drivers/gpu/drm/drm_syncobj.c | 1 - 1 file changed, 1 deletion(-) diff

[PATCH 2/8] drm: rename null fence to stub fence in syncobj

2018-08-24 Thread Chunming Zhou
stub fence will be used by timeline syncobj as well. Signed-off-by: Chunming Zhou Cc: Jason Ekstrand --- drivers/gpu/drm/drm_syncobj.c | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/gpu/drm/drm_syncobj.c b/drivers/gpu/drm/drm_syncobj.c index

[PATCH 4/8] drm: expand replace_fence to support timeline point v2

2018-08-24 Thread Chunming Zhou
we can place a fence to a timeline point after expanded. v2: change func parameter order Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/drm_syncobj.c | 14 -- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 2

[PATCH 3/8] drm: expand drm_syncobj_find_fence to support timeline point v2

2018-08-24 Thread Chunming Zhou
we can fetch timeline point fence after expanded. v2: The parameter fence is the result of the function and should come last. Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/drm_syncobj.c | 5 +++-- drivers/gpu/drm/v3d/v3d_gem.c

[PATCH 5/8] [RFC]drm: add syncobj timeline support v2

2018-08-24 Thread Chunming Zhou
etter) TODO: 1. CPU query and wait on timeline semaphore. 2. test application (Daniel Vetter) Signed-off-by: Chunming Zhou Cc: Christian Konig Cc: Dave Airlie Cc: Daniel Rakos Cc: Daniel Vetter --- drivers/gpu/drm/drm_syncobj.c | 384 -- include/drm/drm_sync

[PATCH 6/8] drm: merge normal syncobj to timeline syncobj

2018-08-24 Thread Chunming Zhou
normal syncobj can be unified to timeline syncobj. The thingking is: a. singal op always append to sinal list tail. b. wait op always wait on last sinal point. the driver indeed be simplified more. Signed-off-by: Chunming Zhou --- drivers/gpu/drm/drm_syncobj.c | 113

[PATCH 7/8] drm: export syncobj search fence to replace fence_get

2018-08-24 Thread Chunming Zhou
Signed-off-by: Chunming Zhou --- drivers/gpu/drm/drm_syncobj.c | 5 +++-- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 4 +++- include/drm/drm_syncobj.h | 2 ++ 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/drm_syncobj.c b/drivers

[PATCH 8/8] drm: clean up syncobj->fence and cb

2018-08-24 Thread Chunming Zhou
syncobj fence and cb aren't need any more. wait pt already contains sumission wait. Signed-off-by: Chunming Zhou --- drivers/gpu/drm/drm_syncobj.c | 69 --- include/drm/drm_syncobj.h | 56 +--- 2 files changed, 1 insertion(+)

Re: [PATCH 1/2] drm/amdgpu: amdgpu_ctx_add_fence can't fail

2018-08-24 Thread Chunming Zhou
在 2018/8/24 20:50, Christian König 写道: No more waiting for a fence done here. Signed-off-by: Christian König Reviewed-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 10 +- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 8 +++- drivers/gpu/drm/amd/amdgpu

Re: [PATCH 2/2] drm/amdgpu: fix holding mn_lock while allocating memory

2018-08-24 Thread Chunming Zhou
在 2018/8/24 20:50, Christian König 写道: We can't hold the mn_lock while allocating memory. if you could add some comments from what you discussed with Michal to explain why, it would be better. With that fixed, Acked-by: Chunming Zhou David Signed-off-by: Christian König --- dr

[PATCH 2/5] drm: rename null fence to stub fence in syncobj

2018-08-29 Thread Chunming Zhou
stub fence will be used by timeline syncobj as well. Signed-off-by: Chunming Zhou Cc: Jason Ekstrand Reviewed-by: Christian König --- drivers/gpu/drm/drm_syncobj.c | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/gpu/drm/drm_syncobj.c b

[PATCH 1/5] drm: fix syncobj null_fence_enable_signaling

2018-08-29 Thread Chunming Zhou
That is certainly totally nonsense. dma_fence_enable_sw_signaling() is the function who is calling this callback. Signed-off-by: Chunming Zhou Cc: Jason Ekstrand Reviewed-by: Christian König Acked-by: Daniel Vetter --- drivers/gpu/drm/drm_syncobj.c | 1 - 1 file changed, 1 deletion(-) diff

[PATCH 3/5] drm: expand drm_syncobj_find_fence to support timeline point v2

2018-08-29 Thread Chunming Zhou
we can fetch timeline point fence after expanded. v2: The parameter fence is the result of the function and should come last. Signed-off-by: Chunming Zhou Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/drm_syncobj.c | 5 +++-- drivers

[PATCH 4/5] drm: expand replace_fence to support timeline point v2

2018-08-29 Thread Chunming Zhou
we can place a fence to a timeline point after expanded. v2: change func parameter order Signed-off-by: Chunming Zhou Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/drm_syncobj.c | 14 -- drivers/gpu/drm/i915

[PATCH 5/5] [RFC]drm: add syncobj timeline support v3

2018-08-29 Thread Chunming Zhou
point PT. 2. some bug fix and clean up 3. tested by ./deqp-vk -n dEQP-VK*semaphore* for normal syncobj TODO: 1. CPU query and wait on timeline semaphore. Signed-off-by: Chunming Zhou Cc: Christian Konig Cc: Dave Airlie Cc: Daniel Rakos Cc: Daniel Vetter --- drivers/gpu/drm/drm_sync

[PATCH 1/5] drm: fix syncobj null_fence_enable_signaling

2018-08-29 Thread Chunming Zhou
That is certainly totally nonsense. dma_fence_enable_sw_signaling() is the function who is calling this callback. Signed-off-by: Chunming Zhou Cc: Jason Ekstrand Reviewed-by: Christian König Acked-by: Daniel Vetter --- drivers/gpu/drm/drm_syncobj.c | 1 - 1 file changed, 1 deletion(-) diff

[PATCH 3/5] drm: expand drm_syncobj_find_fence to support timeline point v2

2018-08-29 Thread Chunming Zhou
we can fetch timeline point fence after expanded. v2: The parameter fence is the result of the function and should come last. Signed-off-by: Chunming Zhou Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/drm_syncobj.c | 5 +++-- drivers

[PATCH 2/5] drm: rename null fence to stub fence in syncobj v2

2018-08-29 Thread Chunming Zhou
moved to front of file. stub fence will be used by timeline syncobj as well. Signed-off-by: Chunming Zhou Cc: Jason Ekstrand Reviewed-by: Christian König --- drivers/gpu/drm/drm_syncobj.c | 53 +++ 1 file changed, 29 insertions(+), 24 deletions(-) diff --git a

[PATCH 5/5] [RFC]drm: add syncobj timeline support v3

2018-08-29 Thread Chunming Zhou
point PT. 2. many bug fix and clean up 3. stub fence moving is moved to other patch. 4. tested by ./deqp-vk -n dEQP-VK*semaphore* for normal syncobj TODO: 1. CPU query and wait on timeline semaphore. Signed-off-by: Chunming Zhou Cc: Christian Konig Cc: Dave Airlie Cc: Daniel Rakos Cc: Daniel V

[PATCH 4/5] drm: expand replace_fence to support timeline point v2

2018-08-29 Thread Chunming Zhou
we can place a fence to a timeline point after expanded. v2: change func parameter order Signed-off-by: Chunming Zhou Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/drm_syncobj.c | 14 -- drivers/gpu/drm/i915

Re: [PATCH 5/5] [RFC]drm: add syncobj timeline support v3

2018-09-02 Thread Chunming Zhou
在 2018/8/30 19:32, Christian König 写道: [SNIP] + +struct drm_syncobj_wait_pt { +    struct drm_syncobj_stub_fence base; +    u64    value; +    struct rb_node   node; +}; +struct drm_syncobj_signal_pt { +    struct drm_syncobj_stub_fence base; +    struct dma_fence *signal_fence; +    struct

Re: [PATCH 5/5] [RFC]drm: add syncobj timeline support v3

2018-09-03 Thread Chunming Zhou
在 2018/9/3 16:50, Christian König 写道: Am 03.09.2018 um 06:13 schrieb Chunming Zhou: 在 2018/8/30 19:32, Christian König 写道: [SNIP] + +struct drm_syncobj_wait_pt { +    struct drm_syncobj_stub_fence base; +    u64    value; +    struct rb_node   node; +}; +struct drm_syncobj_signal_pt

[PATCH 2/3] drm: add support of syncobj timeline point wait

2018-09-05 Thread Chunming Zhou
points array is one-to-one match with syncobjs array. Signed-off-by: Chunming Zhou --- drivers/gpu/drm/drm_syncobj.c | 23 --- include/uapi/drm/drm.h| 2 ++ 2 files changed, 22 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/drm_syncobj.c b/drivers/gpu

[PATCH 1/3] [RFC]drm: add syncobj timeline support v4

2018-09-05 Thread Chunming Zhou
ormal syncobj Signed-off-by: Chunming Zhou Cc: Christian Konig Cc: Dave Airlie Cc: Daniel Rakos Cc: Daniel Vetter --- drivers/gpu/drm/drm_syncobj.c | 516 + drivers/gpu/drm/i915/i915_gem_execbuffer.c | 4 +- include/drm/drm_syncobj.h

[PATCH 3/3] drm: add timeline syncobj payload query ioctl

2018-09-05 Thread Chunming Zhou
user mode can query timeline payload. Signed-off-by: Chunming Zhou --- drivers/gpu/drm/drm_internal.h | 2 ++ drivers/gpu/drm/drm_ioctl.c| 2 ++ drivers/gpu/drm/drm_syncobj.c | 53 ++ include/uapi/drm/drm.h | 3 ++ 4 files changed, 60 insertions

[PATCH 2/3] drm: add support of syncobj timeline point wait v2

2018-09-06 Thread Chunming Zhou
points array is one-to-one match with syncobjs array. v2: add seperate ioctl for timeline point wait, otherwise break uapi. Signed-off-by: Chunming Zhou --- drivers/gpu/drm/drm_internal.h | 2 + drivers/gpu/drm/drm_ioctl.c| 2 + drivers/gpu/drm/drm_syncobj.c | 79

[PATCH 1/3] [RFC]drm: add syncobj timeline support v4

2018-09-06 Thread Chunming Zhou
ormal syncobj Signed-off-by: Chunming Zhou Cc: Christian Konig Cc: Dave Airlie Cc: Daniel Rakos Cc: Daniel Vetter --- drivers/gpu/drm/drm_syncobj.c | 516 + drivers/gpu/drm/i915/i915_gem_execbuffer.c | 4 +- include/drm/drm_syncobj.h

[PATCH 3/3] drm: add timeline syncobj payload query ioctl

2018-09-06 Thread Chunming Zhou
user mode can query timeline payload. Signed-off-by: Chunming Zhou --- drivers/gpu/drm/drm_internal.h | 2 ++ drivers/gpu/drm/drm_ioctl.c| 2 ++ drivers/gpu/drm/drm_syncobj.c | 53 ++ include/uapi/drm/drm.h | 11 +++ 4 files changed, 68

[PATCH] drm/amdgpu: move cs dependencies front a bit

2018-09-11 Thread Chunming Zhou
cs dependencies handling doesn't need in vm resv Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c

[PATCH 1/9] drm: fix syncobj null_fence_enable_signaling

2018-09-12 Thread Chunming Zhou
That is certainly totally nonsense. dma_fence_enable_sw_signaling() is the function who is calling this callback. Signed-off-by: Chunming Zhou Cc: Jason Ekstrand Reviewed-by: Christian König Acked-by: Daniel Vetter --- drivers/gpu/drm/drm_syncobj.c | 1 - 1 file changed, 1 deletion(-) diff

[PATCH 2/9] drm: rename null fence to stub fence in syncobj v2

2018-09-12 Thread Chunming Zhou
moved to front of file. stub fence will be used by timeline syncobj as well. Signed-off-by: Chunming Zhou Cc: Jason Ekstrand Reviewed-by: Christian König --- drivers/gpu/drm/drm_syncobj.c | 53 +++ 1 file changed, 29 insertions(+), 24 deletions(-) diff --git a

[PATCH 7/9] drm: add timeline syncobj payload query ioctl

2018-09-12 Thread Chunming Zhou
user mode can query timeline payload. Signed-off-by: Chunming Zhou --- drivers/gpu/drm/drm_internal.h | 2 ++ drivers/gpu/drm/drm_ioctl.c| 2 ++ drivers/gpu/drm/drm_syncobj.c | 53 ++ include/uapi/drm/drm.h | 11 +++ 4 files changed, 68

[PATCH 4/9] drm: expand replace_fence to support timeline point v2

2018-09-12 Thread Chunming Zhou
we can place a fence to a timeline point after expanded. v2: change func parameter order Signed-off-by: Chunming Zhou Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/drm_syncobj.c | 14 -- drivers/gpu/drm/i915

[PATCH 8/9] drm/amdgpu: add timeline support in amdgpu CS

2018-09-12 Thread Chunming Zhou
Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu.h| 8 +- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 111 +++-- include/uapi/drm/amdgpu_drm.h | 9 ++ 3 files changed, 100 insertions(+), 28 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu

[PATCH 9/9] drm/amdgpu: move cs dependencies front a bit

2018-09-12 Thread Chunming Zhou
cs dependencies handling doesn't need in vm resv Signed-off-by: Chunming Zhou Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/dr

[PATCH 6/9] drm: add support of syncobj timeline point wait v2

2018-09-12 Thread Chunming Zhou
points array is one-to-one match with syncobjs array. v2: add seperate ioctl for timeline point wait, otherwise break uapi. Signed-off-by: Chunming Zhou --- drivers/gpu/drm/drm_internal.h | 2 + drivers/gpu/drm/drm_ioctl.c| 2 + drivers/gpu/drm/drm_syncobj.c | 87

[PATCH 5/9] [RFC]drm: add syncobj timeline support v4

2018-09-12 Thread Chunming Zhou
test in libdrm normal syncobj is tested by ./deqp-vk -n dEQP-VK*semaphore* timeline syncobj is tested by ./amdgpu_test -s 9 Signed-off-by: Chunming Zhou Cc: Christian Konig Cc: Dave Airlie Cc: Daniel Rakos Cc: Daniel Vetter --- drivers/gpu/drm/drm_syncobj.c

[PATCH 3/9] drm: expand drm_syncobj_find_fence to support timeline point v2

2018-09-12 Thread Chunming Zhou
we can fetch timeline point fence after expanded. v2: The parameter fence is the result of the function and should come last. Signed-off-by: Chunming Zhou Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/drm_syncobj.c | 5 +++-- drivers

[PATCH libdrm 1/5] [libdrm] sync drm.h for syncobj part

2018-09-12 Thread Chunming Zhou
Signed-off-by: Chunming Zhou --- include/drm/drm.h | 24 1 file changed, 24 insertions(+) diff --git a/include/drm/drm.h b/include/drm/drm.h index f0bd91de..d1688269 100644 --- a/include/drm/drm.h +++ b/include/drm/drm.h @@ -695,6 +695,7 @@ struct drm_prime_handle

[PATCH libdrm 3/5] [libdrm]: add timeline wait/query ioctl

2018-09-12 Thread Chunming Zhou
Signed-off-by: Chunming Zhou --- xf86drm.c | 44 xf86drm.h | 6 ++ 2 files changed, 50 insertions(+) diff --git a/xf86drm.c b/xf86drm.c index b2388194..0cd1cb75 100644 --- a/xf86drm.c +++ b/xf86drm.c @@ -4249,3 +4249,47 @@ int drmSyncobjSignal

[PATCH libdrm 2/5] [libdrm] addr cs chunk for syncobj timeline

2018-09-12 Thread Chunming Zhou
Signed-off-by: Chunming Zhou --- include/drm/amdgpu_drm.h | 9 + 1 file changed, 9 insertions(+) diff --git a/include/drm/amdgpu_drm.h b/include/drm/amdgpu_drm.h index c363b67f..04663a13 100644 --- a/include/drm/amdgpu_drm.h +++ b/include/drm/amdgpu_drm.h @@ -482,6 +482,8 @@ struct

[PATCH libdrm 4/5] [libdrm]: wrap syncobj timeline query and wait for amdgpu

2018-09-12 Thread Chunming Zhou
Signed-off-by: Chunming Zhou --- amdgpu/amdgpu-symbol-check | 2 ++ amdgpu/amdgpu.h| 39 ++ amdgpu/amdgpu_cs.c | 24 +++ 3 files changed, 65 insertions(+) diff --git a/amdgpu/amdgpu-symbol-check b/amdgpu/amdgpu-symbol

[PATCH libdrm 5/5] [libdrm] add syncobj timeline tests

2018-09-12 Thread Chunming Zhou
Signed-off-by: Chunming Zhou --- tests/amdgpu/Makefile.am | 3 +- tests/amdgpu/amdgpu_test.c | 12 ++ tests/amdgpu/amdgpu_test.h | 21 +++ tests/amdgpu/meson.build | 2 +- tests/amdgpu/syncobj_tests.c | 258 +++ 5 files changed, 294 insertions

[PATCH] [RFC]drm: add syncobj timeline support v5

2018-09-14 Thread Chunming Zhou
ne syncobj is tested by ./amdgpu_test -s 9 Signed-off-by: Chunming Zhou Cc: Christian Konig Cc: Dave Airlie Cc: Daniel Rakos Cc: Daniel Vetter --- drivers/gpu/drm/drm_syncobj.c | 294 ++--- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 4 +- inclu

Re: [PATCH] drm/amdgpu: fix dma_fence_wait without reference

2019-08-16 Thread Chunming Zhou
Reviewed-by: Chunming Zhou 在 2019/8/16 21:21, Christian König 写道: > We need to grab a reference to the fence we wait for. > > Signed-off-by: Christian König > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 27 ++--- > 1 file changed, 15 insertion

Re: [PATCH 3/3] drm/amdgpu: remove amdgpu_cs_try_evict

2019-09-03 Thread Chunming Zhou
Reviewed-by: Chunming Zhou for series. -David 在 2019/9/3 17:09, Christian König 写道: > Trying to evict things from the current working set doesn't work that > well anymore because of per VM BOs. > > Rely on reserving VRAM for page tables to avoid contention. > > Signed-

Re: [PATCH] drm/amdgpu: grab the id mgr lock while accessing passid_mapping

2019-09-10 Thread Chunming Zhou
Reviewed-by: Chunming Zhou 在 2019/9/10 16:56, Christian König 写道: > Ping! > > Am 09.09.19 um 13:59 schrieb Christian König: >> Need to make sure that we actually dropping the right fence. >> Could be done with RCU as well, but to complicated for a fix. >> >&g

Re: [PATCH] drm/amdgpu: resvert "disable bulk moves for now"

2019-09-12 Thread Chunming Zhou
RB on it to go ahead. -David 在 2019/9/12 18:15, Christian König 写道: > This reverts commit a213c2c7e235cfc0e0a161a558f7fdf2fb3a624a. > > The changes to fix this should have landed in 5.1. > > Signed-off-by: Christian König > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 2 -- > 1 file changed

Re: [PATCH 1/2] drm/amdgpu: fix transform feedback GDS hang on gfx10

2019-06-20 Thread Chunming Zhou
please take care of .emit_ib_size member, otherwise it looks ok to me. -David 在 2019/6/20 8:02, Marek Olšák 写道: > From: Marek Olšák > > Signed-off-by: Marek Olšák > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_gds.h | 3 ++- > drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 12 ++-- > 2 files

Re: [PATCH 1/5] drm/amdgpu: allow direct submission in the VM backends

2019-06-28 Thread Chunming Zhou
在 2019/6/28 20:18, Christian König 写道: > This allows us to update page tables directly while in a page fault. > > Signed-off-by: Christian König > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_vm.h | 5 > drivers/gpu/drm/amd/amdgpu/amdgpu_vm_cpu.c | 4 +++ > drivers/gpu/drm/amd/amdgpu/

Re: Intermittent errors when using amdgpu_job_submit_direct

2019-07-09 Thread Chunming Zhou
I've raised it up when Christian make page fault, at that patch, amdgpu_job_submit_direct uses exclusive page fault ring for that. But if you use amdgpu_job_submit_direct for gerneral rings ocuppied by scheduler, I guess varias bugs will happen. -David 在 2019/7/9 12:53, Kuehling, Felix 写道: > I

Re: [PATCH] drm/ttm: Fix the memory delay free issue

2019-07-10 Thread Chunming Zhou
It doesn't make sense that freeing BO still uses per-vm resv. I remember when BO is in release list, its resv will be from per-vm resv copy. Could you check it? -David 在 2019/7/10 17:29, Emily Deng 写道: > For vulkan cts allocation test cases, they will create a series of bos, and > then free >

Re: Intermittent errors when using amdgpu_job_submit_direct

2019-07-10 Thread Chunming Zhou
在 2019/7/10 3:26, Kuehling, Felix 写道: > On 2019-07-09 8:58 a.m., Zhou, David(ChunMing) wrote: >> I've raised it up when Christian make page fault, at that patch, >> amdgpu_job_submit_direct uses exclusive page fault ring for that. >> >> But if you use amdgpu_job_submit_direct for gerneral rings oc

Re: [PATCH] drm/amdgpu: fix a potential information leaking bug

2019-07-27 Thread Chunming Zhou
he multiplication > 1024*sizeof(*data) as the size parameter for memset() though there is > no risk of integer overflow. > > Signed-off-by: Wang Xiayang Reviewed-by: Chunming Zhou -David > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c | 2 +- > 1 file changed, 1

[PATCH 0/2] *** add scheduling policy ***

2017-03-16 Thread Chunming Zhou
Andres added high priority queue for userspace, which got me to think more about scheduling policy, if high priority queue is always full and busy, low priority queue could starve. Chunming Zhou (2): drm/amd/sched: revise priority number drm/amd/sched: add schuduling policy drivers/gpu

[PATCH 2/2] drm/amd/sched: add schuduling policy

2017-03-16 Thread Chunming Zhou
if high priority rq is full, then process with low priority could be starve. Add policy for this problem, the high proiority can ahead of next priority queue, the ratio is 2 : 1. Change-Id: I58f4a6b9cdce8689b18dd8e83dd6e2cf5f99d5fb Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/scheduler

[PATCH 1/2] drm/amd/sched: revise priority number

2017-03-16 Thread Chunming Zhou
big number is to high priority. Change-Id: I1e94b3403d0cfd41a418d2bd741736cf7edc5d77 Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/scheduler/gpu_scheduler.c | 4 ++-- drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 9 + 2 files changed, 7 insertions(+), 6 deletions(-) diff --git

[PATCH] drm/amdgpu: fix duplicated code

2017-03-20 Thread Chunming Zhou
it could come from branch merge. Change-Id: I16959aad6ca6d64cb8330f23ee6472eec4cf2a3e Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 4 1 file changed, 4 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c

[PATCH 01/18] drm/amdgpu: rename page_directory_fence to last_dir_update

2017-03-23 Thread Chunming Zhou
From: Christian König Decribes better what this is used for. Change-Id: I1bd496522fbdd6531d2c1d17434822b53bec06d0 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 8 drivers/gpu/drm/am

[PATCH 02/18] drm/amdgpu: add the VM pointer to the amdgpu_pte_update_params as well

2017-03-23 Thread Chunming Zhou
From: Christian König This way we save passing it through the different functions. Change-Id: Id94564a70d106b0ef36c7f45de2b25ca176db2d2 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 21 +++-- 1 file changed, 11 insertions

[PATCH 03/18] drm/amdgpu: add num_level to the VM manager

2017-03-23 Thread Chunming Zhou
From: Christian König Needs to be filled with handling. Change-Id: I04881a2b304a020c259ce85e94b12900a77f1c02 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.h | 1 + drivers/gpu/drm/amd/amdgpu/gmc_v6_0.c | 1 + drivers/gpu/drm/amd/amdgpu/gmc_

[PATCH 08/18] drm/amdgpu: handle multi level PD updates

2017-03-23 Thread Chunming Zhou
From: Christian König Update all levels of the page directory. Change-Id: I0ce3fc1fd88397aedf693b0b6e2efb2db704e615 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c | 2 +- drivers/gpu/drm/am

[PATCH 06/18] drm/amdgpu: handle multi level PD during validation

2017-03-23 Thread Chunming Zhou
From: Christian König All page directory levels should be in place after this. Change-Id: Ied101d6e14676acc07fe2d46ecba4563007b5045 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 57 +- 1 file changed, 42 i

[PATCH 09/18] drm/amdgpu: handle multi level PD during PT updates

2017-03-23 Thread Chunming Zhou
From: Christian König Not the best solution, but good enough for now. Change-Id: I45ac1a9d8513ebe51bce9a276da39ddf3524b058 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 39 +- 1 file changed, 34 insertions

[PATCH 10/18] drm/amdgpu: add alloc/free for multi level PDs

2017-03-23 Thread Chunming Zhou
From: Christian König Allocate and free page directories on demand. Change-Id: I341b72b911377033257af888dd1a96ca54f586e9 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 178 - 1 file changed, 107 insertions(

[PATCH 11/18] drm/amdgpu: set page table depth by num_level

2017-03-23 Thread Chunming Zhou
Change-Id: I6180bedb8948398429fb32b36faa35960b3b85e6 Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/gfxhub_v1_0.c | 3 ++- drivers/gpu/drm/amd/amdgpu/mmhub_v1_0.c | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gfxhub_v1_0.c b

[PATCH 13/18] drm/amdgpu: fix update sub levels

2017-03-23 Thread Chunming Zhou
sub level pdes always are written to incorrect place. Change-Id: Ic40bbf2affa9cdd0490f8d7dde883cab36bd60fc Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b

[PATCH 14/18] drm/amdgpu: sub levels need to update regardless of parent updates

2017-03-23 Thread Chunming Zhou
Change-Id: I4373d50e243c20a9f7d00134406496de5f482c44 Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 34 -- 1 file changed, 16 insertions(+), 18 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd

[PATCH 16/18] drm/amdgpu: fix entries index calculation

2017-03-23 Thread Chunming Zhou
Change-Id: I3e7eabc3576af4265f8cf58187ebe6cc62503ac6 Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c index 9721552

[PATCH 15/18] drm/amdgpu: clear entries allocation

2017-03-23 Thread Chunming Zhou
Change-Id: If37d906b7ada95087f02e2dffdd81c78a0146c83 Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c index 3d2159e..9721552 100644 --- a

[PATCH 12/18] drm/amdgpu: block size of multiple level vmpt prefers one page

2017-03-23 Thread Chunming Zhou
multiple level vmpt will cover bigger va space, if vmpt is 4 levels, one highest pde will cover 1TB, so increase vm size to 1TB. Change-Id: Ieaf844a8b364892a5a3f3e43e1690b9579b40b85 Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 4 ++-- 1 file changed, 2 insertions

[PATCH 17/18] drm/amdgpu: need alloc sub level even parent bo was allocated

2017-03-23 Thread Chunming Zhou
Change-Id: Ia7b256c298f9d4fb522d0add585961ac789ab80f Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 38 +- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd

[PATCH 18/18] drm/amdgpu: enable four level vmpt

2017-03-23 Thread Chunming Zhou
Change-Id: Ibd9ce30183f77b977e90ce40243d054037b7668b Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c b/drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c index 6625a2f..4178250

[PATCH 00/18] *** multiple level VMPT enablement ***

2017-03-23 Thread Chunming Zhou
/amdgpu: handle multi level PD during PT updates drm/amdgpu: add alloc/free for multi level PDs Chunming Zhou (8): drm/amdgpu: set page table depth by num_level drm/amdgpu: block size of multiple level vmpt prefers one page drm/amdgpu: fix update sub levels drm/amdgpu: sub levels need to

[PATCH 04/18] drm/amdgpu: generalize page table level

2017-03-23 Thread Chunming Zhou
From: Christian König No functional change, but the base for multi level page tables. Change-Id: If5729be07e15cc8618ae7bce15c6b27aa4f24393 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 87 +

[PATCH 07/18] drm/amdgpu: handle multi level PD in the LRU

2017-03-23 Thread Chunming Zhou
From: Christian König Move all levels to the end after command submission. Change-Id: I6d41aac90be29476780b897cf5943a2261580a78 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 36 +- 1 file changed, 27 inser

[PATCH 05/18] drm/amdgpu: handle multi level PD size calculation

2017-03-23 Thread Chunming Zhou
From: Christian König Allows us to get the size for all levels as well. Change-Id: Iaf2f9b2bf19c3623018a2215f8cf01a61bdbe8ea Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 34 ++ 1 file changed, 22 insertio

[PATCH 00/15] *** Multiple level VMPT enablement ***

2017-03-26 Thread Chunming Zhou
in the LRU drm/amdgpu: handle multi level PD updates V2 drm/amdgpu: handle multi level PD during PT updates drm/amdgpu: add alloc/free for multi level PDs V2 Chunming Zhou (5): drm/amdgpu: abstract block size to one function drm/amdgpu: limit block size to one page drm/amdgpu: adapt vm

[PATCH 01/15] drm/amdgpu: rename page_directory_fence to last_dir_update

2017-03-26 Thread Chunming Zhou
From: Christian König Decribes better what this is used for. Change-Id: I1bd496522fbdd6531d2c1d17434822b53bec06d0 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 8 drivers/gpu/drm/am

[PATCH 02/15] drm/amdgpu: add the VM pointer to the amdgpu_pte_update_params as well

2017-03-26 Thread Chunming Zhou
From: Christian König This way we save passing it through the different functions. Change-Id: Id94564a70d106b0ef36c7f45de2b25ca176db2d2 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 21 +++-- 1 file changed, 11 insertions

[PATCH 04/15] drm/amdgpu: generalize page table level

2017-03-26 Thread Chunming Zhou
From: Christian König No functional change, but the base for multi level page tables. Change-Id: If5729be07e15cc8618ae7bce15c6b27aa4f24393 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 87 +

[PATCH 05/15] drm/amdgpu: handle multi level PD size calculation

2017-03-26 Thread Chunming Zhou
From: Christian König Allows us to get the size for all levels as well. Change-Id: Iaf2f9b2bf19c3623018a2215f8cf01a61bdbe8ea Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 34 ++ 1 file changed, 22 insertio

[PATCH 08/15] drm/amdgpu: handle multi level PD updates V2

2017-03-26 Thread Chunming Zhou
Deucher (V1) Signed-off-by: Chunming Zhou (V2) --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 97 ++--- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.h | 4 +- 4 files changed, 68

[PATCH 07/15] drm/amdgpu: handle multi level PD in the LRU

2017-03-26 Thread Chunming Zhou
From: Christian König Move all levels to the end after command submission. Change-Id: I6d41aac90be29476780b897cf5943a2261580a78 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 36 +- 1 file changed, 27 inser

[PATCH 09/15] drm/amdgpu: handle multi level PD during PT updates

2017-03-26 Thread Chunming Zhou
From: Christian König Not the best solution, but good enough for now. Change-Id: I45ac1a9d8513ebe51bce9a276da39ddf3524b058 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 39 +- 1 file changed, 34 insertions

[PATCH 06/15] drm/amdgpu: handle multi level PD during validation

2017-03-26 Thread Chunming Zhou
From: Christian König All page directory levels should be in place after this. Change-Id: Ied101d6e14676acc07fe2d46ecba4563007b5045 Signed-off-by: Christian König Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 57 +- 1 file changed, 42 i

[PATCH 12/15] drm/amdgpu: limit block size to one page

2017-03-26 Thread Chunming Zhou
Change-Id: I00ff5d2c7ff29563394cb8af4c57780b91876743 Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 8 1 file changed, 8 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c index 7bad6b6

<    1   2   3   4   5   6   7   8   >