Re: [PATCH] drm/amdgpu: fix the null pointer to get timeline by scheduler fence

2018-08-13 Thread Andres Rodriguez
Any updates on this issue? Regards, Andres On 2018-08-08 03:10 AM, Christian König wrote: Yeah that is a known issue, but this solution is not correct either. See the scheduler where the job is execute on is simply not determined yet when we want to trace it. So using the scheduler name

Re: [PATCH] drm/amdgpu: fix job priority handling

2018-07-18 Thread Andres Rodriguez
On 2018-07-18 02:14 PM, Christian König wrote: The job might already be released at this point. Signed-off-by: Christian König Reviewed-by: Andres Rodriguez --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 4 +++- drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 4 +++- 2 files changed, 6

Re: [PATCH] drm/amdgpu: cleanup firmware requests v2

2018-04-20 Thread Andres Rodriguez
Ping. On 2018-04-17 06:12 PM, Andres Rodriguez wrote: Add a new function amdgpu_ucode_request_firmware() that encapsulates a lot of the common behaviour we have around firmware requests. This is the first step in my quest to get rid of the following annoying messages when my polaris10 boots up

[PATCH] drm/amdgpu: cleanup firmware requests v2

2018-04-17 Thread Andres Rodriguez
() Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- Sorry for the quick V2, noticed some docs might help and that _validate() could be reduced in scope. Pasting my old message again just in case. Hey Christian, Wanted to go through a cleanup of the ucode loading in amdgpu to facilitat

[PATCH] drm/amdgpu: cleanup firmware requests

2018-04-17 Thread Andres Rodriguez
:01:00.0: Direct firmware load for amdgpu/polaris10_mec_2.bin failed with error -2 [0.558619] amdgpu :01:00.0: Direct firmware load for amdgpu/polaris10_mec2_2.bin failed with error -2 Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- Hey Christian, Wanted to go through a c

Re: [PATCH] drm/amdgpu: use queue 0 for kiq ring

2018-01-22 Thread Andres Rodriguez
On 2018-01-22 08:45 AM, Huang Rui wrote: It must use queue id 0, because CGPG_IDLE/SAVE/LOAD/RUN only can be issued on queue 0. Signed-off-by: Huang Rui Acked-by: Hawking Zhang Reviewed-by: Alex Deucher ---

[PATCH] drm/amdgpu: bump version for gfx9 high priority compute

2018-01-04 Thread Andres Rodriguez
Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- 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 50afcf65181a..d96f9ac9e5fd

Re: [PATCH] drm/amdgpu: add high priority compute support for gfx9

2018-01-03 Thread Andres Rodriguez
On 2018-01-03 06:29 PM, Alex Deucher wrote: On Tue, Jan 2, 2018 at 3:49 PM, Andres Rodriguez <andre...@gmail.com> wrote: We follow the same approach as gfx8. The only changes are register access macros. Tested on vega10. The execution latency results fall within the expected range

Re: [PATCH] drm/amdgpu: fix amdgpu_sync_resv v2

2017-11-29 Thread Andres Rodriguez
in the shared fences list. v2: fix typo Signed-off-by: Christian König <christian.koe...@amd.com> Hi Christian, Sorry, last few weeks have been a little hectic. This patch looks good to me. You can add: Reviewed-by: Andres Rodriguez <andre...@gmail.com> The steamvr explicit sync use cases a

Re: [PATCH 1/2] drm/amdgpu: use multipipe compute policy on non PL11 asics

2017-11-06 Thread Andres Rodriguez
e to multipipe > hw setting issue. > > > Regards, > > David Zhou > ------ > *From:* Andres Rodriguez <andre...@gmail.com> > *Sent:* Tuesday, November 7, 2017 2:00:57 AM > *To:* Zhou, David(ChunMing); amd-gfx list > *Cc:* Deucher, Alexan

Re: [PATCH 1/2] drm/amdgpu: use multipipe compute policy on non PL11 asics

2017-11-06 Thread Andres Rodriguez
is patch amdgpu_queue_mgr_map has been using an LRU policy for a long time now. Regards, Andres On Mon, Nov 6, 2017 at 12:44 PM, Andres Rodriguez <andre...@gmail.com> wrote: > > > On 2017-11-06 01:49 AM, Chunming Zhou wrote: >> >> Hi Andres, >> > > Hi David,

Re: [PATCH 7/7] drm/amdgpu: retry init if it fails due to exclusive mode timeout

2017-10-23 Thread Andres Rodriguez
On 2017-10-23 06:03 AM, Pixel Ding wrote: From: pding The exclusive mode has real-time limitation in reality, such like being done in 300ms. It's easy observed if running many VF/VMs in single host with heavy CPU workload. If we find the init fails due to exclusive mode

Re: [PATCH 1/3] drm/amdgpu: Avoid accessing job->entity after the job is scheduled.

2017-10-20 Thread Andres Rodriguez
On 2017-10-20 02:24 PM, Christian König wrote: Am 20.10.2017 um 18:51 schrieb Andrey Grodzovsky: On 2017-10-20 12:26 PM, Andres Rodriguez wrote: On 2017-10-20 12:19 PM, Andrey Grodzovsky wrote: On 2017-10-20 11:59 AM, Andres Rodriguez wrote: On 2017-10-20 09:32 AM, Andrey

Re: [PATCH 1/3] drm/amdgpu: Avoid accessing job->entity after the job is scheduled.

2017-10-20 Thread Andres Rodriguez
On 2017-10-20 12:19 PM, Andrey Grodzovsky wrote: On 2017-10-20 11:59 AM, Andres Rodriguez wrote: On 2017-10-20 09:32 AM, Andrey Grodzovsky wrote: Bug: amdgpu_job_free_cb was accessing s_job->s_entity when the allocated amdgpu_ctx (and the entity inside it) were already deallocated f

Re: [PATCH 1/3] drm/amdgpu: Avoid accessing job->entity after the job is scheduled.

2017-10-20 Thread Andres Rodriguez
On 2017-10-20 09:32 AM, Andrey Grodzovsky wrote: Bug: amdgpu_job_free_cb was accessing s_job->s_entity when the allocated amdgpu_ctx (and the entity inside it) were already deallocated from amdgpu_cs_parser_fini. Fix: Save job's priority on it's creation instead of accessing it from s_entity

[PATCH libdrm 1/2] headers: Sync amdgpu_drm.h with drm-next

2017-10-20 Thread Andres Rodriguez
Generated using make headers_install from: airlied/drm-next 282dc83 Merge tag 'drm-intel-next-2017-10-12' ... Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- include/drm/amdgpu_drm.h | 31 ++- 1 file changed, 30 insertions(+), 1 deletion(-) diff

[PATCH libdrm 2/2] amdgpu: implement context priority for amdgpu_cs_ctx_create2 v3

2017-10-20 Thread Andres Rodriguez
AMDGPU_CTX_PRIORITY_NORMAL. v2: corresponding changes for kernel patch v2 v3: Fixed 'make check' symbol error Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- amdgpu/amdgpu-symbol-check | 1 + amdgpu/amdgpu.h| 17 +++-- amdgpu/amdgpu_cs.c | 17 + 3

Re: Upstream repo for libhsakmt

2017-10-17 Thread Andres Rodriguez
If I remember correctly, it should be John B. Regards, Andres On 2017-10-17 11:42 AM, Felix Kuehling wrote: I didn't even know about the freedesktop repository. Do you know who has commit access to that? Regards,   Felix On 2017-10-16 10:44 PM, Tom Stellard wrote: Hi Felix, What do you

[PATCH] drm/amdgpu: rename context priority levels

2017-10-13 Thread Andres Rodriguez
Don't leak implementation details about how each priority behaves to usermode. This allows greater flexibility in the future. Squash into c2636dc53abd8269a0930bccd564f2f195dba729 Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- Hey Alex, From some of the IRC discussions, I t

Re: [PATCH 4/5] drm/amd/sched: NULL out the s_fence field after run_job

2017-09-28 Thread Andres Rodriguez
ld this be moved somewhere closer to where the fence reference is actually dropped? Alternatively, could a comment be added to specify which function call results in the reference ownership transfer? Whether a change is made or not, this series is Reviewed-by: Andres Rodriguez <andre...@

[PATCH] drm/amdgpu: map compute rings by least recently used pipe

2017-09-26 Thread Andres Rodriguez
-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_queue_mgr.c | 8 +--- drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 25 - drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h | 5 +++-- 3 files changed, 28 insertions(+), 10 del

[PATCH 1/2] drm/amdgpu: use multipipe compute policy on non PL11 asics

2017-09-26 Thread Andres Rodriguez
A performance regression for OpenCL tests on Polaris11 had this feature disabled for all asics. Instead, disable it selectively on the affected asics. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 14 -- 1 file chang

[PATCH 2/2] drm/amdgpu: add option for force enable multipipe policy for compute

2017-09-26 Thread Andres Rodriguez
Useful for testing the effects of multipipe compute without recompiling. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 4 drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 6 ++ 3 files c

[PATCH 0/2] Selectively spread compute rings across pipes

2017-09-26 Thread Andres Rodriguez
/disabled. Andres Rodriguez (2): drm/amdgpu: use multipipe compute policy on non PL11 asics drm/amdgpu: add option for force enable multipipe policy for compute drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 4 drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c

[PATCH 8/8] drm/amdgpu: add interface for editing a foreign process's priority v3

2017-09-21 Thread Andres Rodriguez
: removed unused output structure v3: change refcounted interface for a regular set operation Signed-off-by: Andres Rodriguez <andre...@gmail.com> Acked-by: Christian König <christian.koe...@amd.com> --- drivers/gpu/drm/amd/amdgpu/Makefile | 2 +- drivers/gpu/drm/amd/amdgpu/

[PATCH 5/8] drm/amd/sched: allow clients to edit an entity's rq v2

2017-09-21 Thread Andres Rodriguez
This is useful for changing an entity's priority at runtime. v2: don't modify the order of amd_sched_entity members Signed-off-by: Andres Rodriguez <andre...@gmail.com> Acked-by: Christian König <christian.koe...@amd.com> --- drivers/gpu/drm/amd/scheduler/gpu_sche

[PATCH 4/8] drm/amdgpu: make amdgpu_to_sched_priority detect invalid parameters

2017-09-21 Thread Andres Rodriguez
Returning invalid priorities as _NORMAL is a backwards compatibility quirk of amdgpu_ctx_ioctl(). Move this detail one layer up where it belongs. Signed-off-by: Andres Rodriguez <andre...@gmail.com> Acked-by: Christian König <christian.koe...@amd.com> --- drivers/gpu/drm/amd/amdgpu/

[PATCH 6/8] drm/amdgpu: introduce AMDGPU_CTX_PRIORITY_UNSET

2017-09-21 Thread Andres Rodriguez
Use _INVALID to identify bad parameters and _UNSET to represent the lack of interest in a specific value. Signed-off-by: Andres Rodriguez <andre...@gmail.com> Acked-by: Christian König <christian.koe...@amd.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 2 ++ drivers

[PATCH 1/8] drm/amdgpu: add parameter to allocate high priority contexts v11

2017-09-21 Thread Andres Rodriguez
ian König <christian.koe...@amd.com> Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 61 +-- drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 5 ++- include/uapi/drm/amdgpu_drm.h | 10 - 3 files c

[PATCH 3/8] drm/amdgpu: implement ring set_priority for gfx_v8 compute v9

2017-09-21 Thread Andres Rodriguez
servation to PIPE_PERCENT allocation v7: use kiq instead of MMIO v8: back to MMIO, and make the implementation sleep safe. v9: corresponding changes for splitting HIGH into _HW/_SW Acked-by: Christian König <christian.koe...@amd.com> Signed-off-by: Andres Rodriguez <andre...@gmail.com> ---

[PATCH 0/8] allow DRM_MASTER to change client's priorities v3

2017-09-21 Thread Andres Rodriguez
/mesa.git libdrm: g...@github.com:lostgoat/libdrm.git vk-demos: g...@github.com:lostgoat/Vulkan.git Run the following two vk-demos simultaneously: ./ssao ./computeparticles -high-priority Andres Rodriguez (8): drm/amdgpu: add parameter to allocate high priority contexts v11 drm/amdgpu: add

[PATCH 0/2] [reference] Disable implicit sync for non-wsi bos

2017-09-19 Thread Andres Rodriguez
This is a reference patch series for the kernel series: "drm/amdgpu: introduce AMDGPU_GEM_CREATE_EXPLICIT_SYNC v2" Andres Rodriguez (2): radv: factor out radv_alloc_memory radv: disable implicit sync for radv allocated bos v2 src/amd/vulkan/radv_device.c

[PATCH 2/2] radv: disable implicit sync for radv allocated bos v2

2017-09-19 Thread Andres Rodriguez
for all radv allocations except for wsi bos. The only systems that require implicit synchronization are DRI2/3 and PRIME. v2: mark wsi bos as RADV_MEM_IMPLICIT_SYNC Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- src/amd/vulkan/radv_device.c | 3 +++ src/amd/

[PATCH 1/2] radv: factor out radv_alloc_memory

2017-09-19 Thread Andres Rodriguez
This allows us to pass extra parameters to the memory allocation operation that are not defined in the vulkan spec. This is useful for internal usage. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- src/amd/vulkan/radv_device.c | 19 ++- src/amd/vulkan/radv_pri

Re: [PATCH] drm/amdgpu: introduce AMDGPU_GEM_CREATE_EXPLICIT_SYNC v2

2017-09-19 Thread Andres Rodriguez
, right? We still have to rely on implicit sync to guarantee the. Correct order of rendering and present. Could you confirm? Thanks. Sent from my iPhone On 19 Sep 2017, at 9:57 PM, Andres Rodriguez <andre...@gmail.com <mailto:andre...@gmail.com>> wrote: On 2017-09-19 09:24 AM, Chr

[PATCH] drm/amdgpu: introduce AMDGPU_GEM_CREATE_EXPLICIT_SYNC v2

2017-09-19 Thread Andres Rodriguez
(DRI2/3). This patch introduces the AMDGPU_GEM_CREATE_EXPLICIT_SYNC, so that users can specify when it is safe to disable implicit sync. v2: only disable explicit sync in amdgpu_cs_ioctl Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- Hey Christian, I kept the amdgpu_bo_explici

Re: [PATCH] drm/amdgpu: add helper to convert a ttm bo to amdgpu_bo

2017-09-18 Thread Andres Rodriguez
This is a small cleanup patch from my initial naive attempt at extracting a TTM bo in amdgpu_sync_resv(). It didn't end up being useful in that specific case, but I thought I'd send it out anyways in case you find it useful. Regards, Andres On 2017-09-18 11:17 PM, Andres Rodriguez wrote

[PATCH] drm/amdgpu: add helper to convert a ttm bo to amdgpu_bo

2017-09-18 Thread Andres Rodriguez
Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 8 +++- drivers/gpu/drm/amd/amdgpu/amdgpu_object.h | 5 + drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c| 9 + 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/d

Re: [PATCH] drm/amdgpu: introduce AMDGPU_GEM_CREATE_EXPLICIT_SYNC

2017-09-18 Thread Andres Rodriguez
On 2017-09-18 10:47 PM, zhoucm1 wrote: On 2017年09月19日 07:16, Andres Rodriguez wrote: Introduce a flag to signal that access to a BO will be synchronized through an external mechanism. Currently all buffers shared between contexts are subject to implicit synchronization. However

Re: [PATCH] radv: disable implicit sync for radv allocated bos

2017-09-18 Thread Andres Rodriguez
Got some feedback from Dave, and this patch doesn't handle dri3 use cases correctly. Regards, Andres On 2017-09-18 07:16 PM, Andres Rodriguez wrote: Implicit sync kicks in when a buffer is used by two different amdgpu contexts simultaneously. Jobs that use explicit synchronization mechanisms

[PATCH] drm/amdgpu: introduce AMDGPU_GEM_CREATE_EXPLICIT_SYNC

2017-09-18 Thread Andres Rodriguez
(DRI2/3). This patch introduces the AMDGPU_GEM_CREATE_EXPLICIT_SYNC, so that users can specify when it is safe to disable implicit sync. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 4 +++- drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c

[PATCH] Add flag to disable implicit synchronization

2017-09-18 Thread Andres Rodriguez
for these two scenarios can be found here: https://drive.google.com/open?id=0B2ygSoZuj3IMRklfM1llbTJqTnc The libdrm and radv patches are included for reference. Andres Rodriguez (1): drm/amdgpu: introduce AMDGPU_GEM_CREATE_EXPLICIT_SYNC drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 4 +++- drivers/gpu

[PATCH libdrm] amdgpu: update headers

2017-09-18 Thread Andres Rodriguez
For testing the kernel commit --- include/drm/amdgpu_drm.h | 4 1 file changed, 4 insertions(+) diff --git a/include/drm/amdgpu_drm.h b/include/drm/amdgpu_drm.h index da2ade6..c01abaa 100644 --- a/include/drm/amdgpu_drm.h +++ b/include/drm/amdgpu_drm.h @@ -89,6 +89,10 @@ extern "C" {

[PATCH] radv: disable implicit sync for radv allocated bos

2017-09-18 Thread Andres Rodriguez
for all radv allocations. The only systems that require implicit synchronization are DRI2/3 and PRIME. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- src/amd/vulkan/winsys/amdgpu/radv_amdgpu_bo.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/amd/vulkan/winsys/

Re: [PATCH resend] allow DRM_MASTER to change client's priorities v2

2017-07-24 Thread Andres Rodriguez
pushed? Regards, David Zhou On 2017年07月08日 03:26, Andres Rodriguez wrote: > Little ping on this series for review. > > Also added recent reviews/acks and rebased. > > Andres Rodriguez (8): >drm/amdgpu: add parameter to allocate high priority contexts v11 >drm/

Re: [PATCH v2] drm/amdgpu: Fix KFD oversubscription by tracking queues correctly

2017-07-13 Thread Andres Rodriguez
Reviewed-by: Andres Rodriguez <andre...@gmail.com> On 2017-07-13 04:23 PM, Jay Cornwall wrote: The number of compute queues available to the KFD was erroneously calculated as 64. Only the first MEC can execute compute queues and it has 32 queue slots. This caused the oversubscription

Re: [PATCH] drm/amdgpu: Fix KFD oversubscription by tracking queues correctly

2017-07-13 Thread Andres Rodriguez
On 2017-07-13 03:35 PM, Felix Kuehling wrote: On 17-07-13 03:15 PM, Jay Cornwall wrote: On Thu, Jul 13, 2017, at 13:36, Andres Rodriguez wrote: On 2017-07-12 02:26 PM, Jay Cornwall wrote: The number of compute queues available to the KFD was erroneously calculated as 64. Only the first MEC

Re: [PATCH] drm/amdgpu: Fix KFD oversubscription by tracking queues correctly

2017-07-13 Thread Andres Rodriguez
On 2017-07-13 02:36 PM, Andres Rodriguez wrote: On 2017-07-12 02:26 PM, Jay Cornwall wrote: The number of compute queues available to the KFD was erroneously calculated as 64. Only the first MEC can execute compute queues and it has 32 queue slots. This caused the oversubscription limit

Re: [PATCH] drm/amdgpu: Fix KFD oversubscription by tracking queues correctly

2017-07-13 Thread Andres Rodriguez
On 2017-07-12 02:26 PM, Jay Cornwall wrote: The number of compute queues available to the KFD was erroneously calculated as 64. Only the first MEC can execute compute queues and it has 32 queue slots. This caused the oversubscription limit to be calculated incorrectly, leading to a missing

Re: [PATCH] drm/amdgpu/gfx: keep all compute queues on the same pipe

2017-07-11 Thread Andres Rodriguez
Hey Alex, Which apps are having perf problems? Also, is the issue present when the queue gets mapped to pipe0? (i.e. it the perf regression only happens on pipe1+) Regards, Andres On 2017-07-11 11:13 AM, Alex Deucher wrote: Spreading them causes performance regressions using compute

Re: [PATCH 0/2] Add support for context priorities

2017-07-07 Thread Andres Rodriguez
On 2017-07-07 04:31 PM, Alex Deucher wrote: On Fri, Jul 7, 2017 at 3:28 PM, Andres Rodriguez <andre...@gmail.com> wrote: As requested, for validation of the kernel series. Andres Rodriguez (2): headers: sync amdgpu_drm.h with the kernel amdgpu: implement context pr

[PATCH 1/2] headers: sync amdgpu_drm.h with the kernel

2017-07-07 Thread Andres Rodriguez
Generated using make headers_install from: [TODO: Pending kernel patches] Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- include/drm/amdgpu_drm.h | 31 ++- 1 file changed, 30 insertions(+), 1 deletion(-) diff --git a/include/drm/amdgpu_drm.h b/inclu

[PATCH 0/2] Add support for context priorities

2017-07-07 Thread Andres Rodriguez
As requested, for validation of the kernel series. Andres Rodriguez (2): headers: sync amdgpu_drm.h with the kernel amdgpu: implement context priority for amdgpu_cs_ctx_create2 v3 amdgpu/amdgpu-symbol-check | 1 + amdgpu/amdgpu.h| 17 +++-- amdgpu/amdgpu_cs.c

[PATCH 6/8] drm/amdgpu: introduce AMDGPU_CTX_PRIORITY_UNSET

2017-07-07 Thread Andres Rodriguez
Use _INVALID to identify bad parameters and _UNSET to represent the lack of interest in a specific value. Signed-off-by: Andres Rodriguez <andre...@gmail.com> Acked-by: Christian König <christian.koe...@amd.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 2 ++ drivers

[PATCH 5/8] drm/amd/sched: allow clients to edit an entity's rq v2

2017-07-07 Thread Andres Rodriguez
This is useful for changing an entity's priority at runtime. v2: don't modify the order of amd_sched_entity members Signed-off-by: Andres Rodriguez <andre...@gmail.com> Acked-by: Christian König <christian.koe...@amd.com> --- drivers/gpu/drm/amd/scheduler/gpu_sche

[PATCH 8/8] drm/amdgpu: add interface for editing a foreign process's priority v3

2017-07-07 Thread Andres Rodriguez
: removed unused output structure v3: change refcounted interface for a regular set operation Signed-off-by: Andres Rodriguez <andre...@gmail.com> Acked-by: Christian König <christian.koe...@amd.com> --- drivers/gpu/drm/amd/amdgpu/Makefile | 2 +- drivers/gpu/drm/amd/amdgpu/

[PATCH 4/8] drm/amdgpu: make amdgpu_to_sched_priority detect invalid parameters

2017-07-07 Thread Andres Rodriguez
Returning invalid priorities as _NORMAL is a backwards compatibility quirk of amdgpu_ctx_ioctl(). Move this detail one layer up where it belongs. Signed-off-by: Andres Rodriguez <andre...@gmail.com> Acked-by: Christian König <christian.koe...@amd.com> --- drivers/gpu/drm/amd/amdgpu/

[PATCH 3/8] drm/amdgpu: implement ring set_priority for gfx_v8 compute v9

2017-07-07 Thread Andres Rodriguez
servation to PIPE_PERCENT allocation v7: use kiq instead of MMIO v8: back to MMIO, and make the implementation sleep safe. v9: corresponding changes for splitting HIGH into _HW/_SW Acked-by: Christian König <christian.koe...@amd.com> Signed-off-by: Andres Rodriguez <andre...@gmail.com> ---

[PATCH resend] allow DRM_MASTER to change client's priorities v2

2017-07-07 Thread Andres Rodriguez
Little ping on this series for review. Also added recent reviews/acks and rebased. Andres Rodriguez (8): drm/amdgpu: add parameter to allocate high priority contexts v11 drm/amdgpu: add framework for HW specific priority settings v9 drm/amdgpu: implement ring set_priority for gfx_v8

[PATCH 2/8] drm/amdgpu: add framework for HW specific priority settings v9

2017-07-07 Thread Andres Rodriguez
<christian.koe...@amd.com> Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c| 2 + drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 4 ++ drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 76 ++- drivers/gpu/dr

[PATCH 1/8] drm/amdgpu: add parameter to allocate high priority contexts v11

2017-07-07 Thread Andres Rodriguez
ian König <christian.koe...@amd.com> Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 61 +-- drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 5 ++- include/uapi/drm/amdgpu_drm.h | 10 - 3 files c

[PATCH 7/8] drm/amdgpu: add plumbing for ctx priority changes v2

2017-06-26 Thread Andres Rodriguez
Introduce amdgpu_ctx_priority_override(). A mechanism to override a context's priority. An override can be terminated by setting the override to AMD_SCHED_PRIORITY_UNSET. v2: change refcounted interface for a direct set Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/g

[PATCH 8/8] drm/amdgpu: add interface for editing a foreign process's priority v3

2017-06-26 Thread Andres Rodriguez
: removed unused output structure v3: change refcounted interface for a regular set operation Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/Makefile | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 21 +- drivers/gpu/drm/amd/amdgpu/amdgpu

[PATCH 1/8] drm/amdgpu: add parameter to allocate high priority contexts v11

2017-06-26 Thread Andres Rodriguez
ian König <christian.koe...@amd.com> Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 61 +-- drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 5 ++- include/uapi/drm/amdgpu_drm.h | 10 - 3 files c

[PATCH 3/8] drm/amdgpu: implement ring set_priority for gfx_v8 compute v9

2017-06-26 Thread Andres Rodriguez
servation to PIPE_PERCENT allocation v7: use kiq instead of MMIO v8: back to MMIO, and make the implementation sleep safe. v9: corresponding changes for splitting HIGH into _HW/_SW Acked-by: Christian König <christian.koe...@amd.com> Signed-off-by: Andres Rodriguez <andre...@gmail.com> ---

[PATCH] allow DRM_MASTER to change client's priorities v2

2017-06-26 Thread Andres Rodriguez
Updated with Christian's request to simplify the process priority override interface. Series available in the wip-process-priorities-v2 branch of: git://people.freedesktop.org/~lostgoat/linux ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org

[PATCH 5/8] drm/amd/sched: allow clients to edit an entity's rq v2

2017-06-26 Thread Andres Rodriguez
This is useful for changing an entity's priority at runtime. v2: don't modify the order of amd_sched_entity members Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/scheduler/gpu_scheduler.c | 26 +++--- drivers/gpu/drm/amd/sch

[PATCH 6/8] drm/amdgpu: introduce AMDGPU_CTX_PRIORITY_UNSET

2017-06-26 Thread Andres Rodriguez
Use _INVALID to identify bad parameters and _UNSET to represent the lack of interest in a specific value. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 2 ++ drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 3 ++- include/ua

[PATCH 2/8] drm/amdgpu: add framework for HW specific priority settings v9

2017-06-26 Thread Andres Rodriguez
atomic for tracking job priorities instead of last_job v6: rename amdgpu_ring_priority_[get/put]() and align parameters v7: replace spinlocks with mutexes for KIQ compatibility v8: raise ring priority during cs_ioctl, instead of job_run v9: priority_get() before push_job() Signed-off-by: Andres

Re: [PATCH 5/8] drm/amdgpu: move priority decay logic into amd_sched_priority_ctr

2017-06-26 Thread Andres Rodriguez
On 2017-06-26 09:32 AM, Christian König wrote: Sorry for the delay, back from a rather long sick leave today and trying to catch up with my work. Don't worry too much. Get well soon! Quick ping on the query above. The query can be summarized as: which ioctl interface do we prefer for the

Re: [PATCH] drm/amdgpu: disable vga render in dce hw_init

2017-06-19 Thread Andres Rodriguez
This fixes display regressions on my MSI RX480 Gaming X Tested-by: Andres Rodriguez <andre...@gmail.com> On 2017-06-19 05:29 PM, Alex Deucher wrote: This got dropped accidently with the fb location changes, but for some reason, this doesn't seem to cause an issue on all cards which is

Re: [PATCH 5/8] drm/amdgpu: move priority decay logic into amd_sched_priority_ctr

2017-06-19 Thread Andres Rodriguez
On 2017-06-09 01:05 PM, Andres Rodriguez wrote: On 2017-06-09 06:54 AM, Christian König wrote: Am 09.06.2017 um 00:06 schrieb Andres Rodriguez: So that it can be re-used. A priority counter can be used to track priority requests. If no active requests exists, the counter will default

Re: [PATCH] drm/amd/sched: print sched job id in amd_sched_job trace

2017-06-13 Thread Andres Rodriguez
on if we hit the pointer re-use case. I think this is also the only trace that still prints the pointer, so it isn't actually very useful in the first place. With that change you can add: Reviewed-by: Andres Rodriguez <andre...@gmail.com> Regards, Andres __fiel

Re: [PATCH 1/2] drm/amdgpu/gfx: fix MEC interrupt enablement for pipes != 0

2017-06-09 Thread Andres Rodriguez
On 2017-06-09 11:16 PM, Deucher, Alexander wrote: -Original Message- From: Andres Rodriguez [mailto:andre...@gmail.com] Sent: Friday, June 09, 2017 7:49 PM To: Alex Deucher; amd-gfx@lists.freedesktop.org Cc: Deucher, Alexander Subject: Re: [PATCH 1/2] drm/amdgpu/gfx: fix MEC interrupt

[PATCH 8/8] drm/amdgpu: add interface for editing a foreign process's priority v2

2017-06-09 Thread Andres Rodriguez
process. This is simpler than passing a pid number, which is vulnerable to re-use, etc. This functionality is limited to DRM_MASTER since abuse of this interface can have a negative impact on the system's performance. v2: removed unused output structure Signed-off-by: Andres Rodriguez <an

[PATCH 6/8] drm/amd/sched: allow clients to edit an entity's rq v2

2017-06-09 Thread Andres Rodriguez
This is useful for changing an entity's priority at runtime. v2: don't modify the order of amd_sched_entity members Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/scheduler/gpu_scheduler.c | 26 +++--- drivers/gpu/drm/amd/sch

[PATCH 2/8] drm/amdgpu: add framework for HW specific priority settings v9

2017-06-09 Thread Andres Rodriguez
atomic for tracking job priorities instead of last_job v6: rename amdgpu_ring_priority_[get/put]() and align parameters v7: replace spinlocks with mutexes for KIQ compatibility v8: raise ring priority during cs_ioctl, instead of job_run v9: priority_get() before push_job() Signed-off-by: Andres

Re: [PATCH 7/8] drm/amdgpu: add plumbing for ctx priority changes

2017-06-09 Thread Andres Rodriguez
On 2017-06-09 07:11 AM, Christian König wrote: Am 09.06.2017 um 00:06 schrieb Andres Rodriguez: Introduce amdgpu_ctx_priority_get/put(). This a refcounted mechanism to change a context's priority. A context's priority will be set to the highest priority for which a request exists

Re: [PATCH 5/8] drm/amdgpu: move priority decay logic into amd_sched_priority_ctr

2017-06-09 Thread Andres Rodriguez
On 2017-06-09 06:54 AM, Christian König wrote: Am 09.06.2017 um 00:06 schrieb Andres Rodriguez: So that it can be re-used. A priority counter can be used to track priority requests. If no active requests exists, the counter will default to ()->default_priority. The re-factored vers

Re: [PATCH] drm/amdgpu: add parameter to allocate high priority contexts v11

2017-06-08 Thread Andres Rodriguez
I had forgotten to squash some fixups to the original patch. This should be the correct one. Regards, Andres On 2017-06-08 06:20 PM, Andres Rodriguez wrote: Add a new context creation parameter to express a global context priority. The priority ranking in descending order is as follows

[PATCH] drm/amdgpu: add parameter to allocate high priority contexts v11

2017-06-08 Thread Andres Rodriguez
ian König <christian.koe...@amd.com> Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 61 +-- drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 5 ++- include/uapi/drm/amdgpu_drm.h | 10 - 3 files c

[PATCH 7/8] drm/amdgpu: add plumbing for ctx priority changes

2017-06-08 Thread Andres Rodriguez
. Note that the priority requested at allocation does not create a request, therefore it can be overridden by a get() request for a lower priority. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 8 +- drivers/gpu/drm/amd/amdgpu/amdgpu

[PATCH 8/8] drm/amdgpu: add interface for editing a foreign process's priority

2017-06-08 Thread Andres Rodriguez
process. This is simpler than passing a pid number, which is vulnerable to re-use, etc. This functionality is limited to DRM_MASTER since abuse of this interface can have a negative impact on the system's performance. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/d

[PATCH] allow DRM_MASTER to change client's priorities

2017-06-08 Thread Andres Rodriguez
Hey Everyone, This series is the first spin-off from my RFC "Exclusive gpu access for SteamVR usecases". It also includes an updated version of my priority patchset. Some notable changes to the old priority patches: * Patch 1: DRM_MASTER is now allowed to allocate high priority contexts *

[PATCH 6/8] drm/amd/sched: allow clients to edit an entity's rq

2017-06-08 Thread Andres Rodriguez
This is useful for changing an entity's priority at runtime. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/scheduler/gpu_scheduler.c | 26 +++--- drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 6 +- 2 files changed, 28 insertions

[PATCH 5/8] drm/amdgpu: move priority decay logic into amd_sched_priority_ctr

2017-06-08 Thread Andres Rodriguez
ity. This didn't matter for rings, as no priority below NORMAL has an effect. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 69 +-- drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h | 6 +- drivers/gpu/drm/amd/scheduler/gpu_schedule

[PATCH 4/8] drm/amdgpu: make amdgpu_to_sched_priority detect invalid parameters

2017-06-08 Thread Andres Rodriguez
Returning invalid priorities as _NORMAL is a backwards compatibility quirk of amdgpu_ctx_ioctl(). Move this detail one layer up where it belongs. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 8 +--- drivers/gpu/drm/amd/sch

[PATCH 3/8] drm/amdgpu: implement ring set_priority for gfx_v8 compute v9

2017-06-08 Thread Andres Rodriguez
servation to PIPE_PERCENT allocation v7: use kiq instead of MMIO v8: back to MMIO, and make the implementation sleep safe. v9: corresponding changes for splitting HIGH into _HW/_SW Acked-by: Christian König <christian.koe...@amd.com> Signed-off-by: Andres Rodriguez <andre...@gmail.com> ---

[PATCH 1/8] drm/amdgpu: add parameter to allocate high priority contexts v11

2017-06-08 Thread Andres Rodriguez
ian König <christian.koe...@amd.com> Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 60 +-- drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 5 ++- include/uapi/drm/amdgpu_drm.h | 10 - 3 files c

[PATCH 2/8] drm/amdgpu: add framework for HW specific priority settings v8

2017-06-08 Thread Andres Rodriguez
atomic for tracking job priorities instead of last_job v6: rename amdgpu_ring_priority_[get/put]() and align parameters v7: replace spinlocks with mutexes for KIQ compatibility v8: raise ring priority during cs_ioctl, instead of job_run Signed-off-by: Andres Rodriguez <andre...@gmail.

Re: [PATCH] drm/amdgpu/gfx8: drop per-APU CU limits

2017-06-06 Thread Andres Rodriguez
com> Reviewed-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 71 +-- 1 file changed, 2 insertions(+), 69 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c b/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c index 58cc

Re: . [PATCH] drm/amd/amdgpu: Fix ring initialization for GFX9

2017-06-05 Thread Andres Rodriguez
On 2017-06-05 03:48 PM, Xie, AlexBin wrote: Hi Andres, I think the original patch was written by you. Would you comment? Is it a bug or intentional? Thank you. Alex Bin Xie Message: 1 Date: Mon, 5 Jun 2017 10:36:59 -0400 From: Tom St Denis To:

Re: [PATCH 2/2] drm/amdgpu/gfx9: new queue policy, take first 2 queues of each pipe

2017-06-05 Thread Andres Rodriguez
Reviewed-by: Andres Rodriguez <andre...@gmail.com> -Andres On 2017-06-05 11:06 AM, Alex Deucher wrote: Instead of taking the first pipe and giving the rest to kfd, take the first 2 queues of each pipe. Effectively, amdgpu and amdkfd own the same number of queues. But because the

Re: [RFC] Exclusive gpu access for SteamVR usecases

2017-05-31 Thread Andres Rodriguez
ave their final memory addresses attached. Let me read and think about this a bit more. Regards, Andres Regards, Christian. Am 30.05.2017 um 23:38 schrieb Andres Rodriguez: On 2017-05-30 11:19 AM, Christian König wrote: Looks like a good start, but a few notes in general: 1. Sp

Re: [RFC] Exclusive gpu access for SteamVR usecases

2017-05-30 Thread Andres Rodriguez
The current API does allow you to deadlock yourself pretty easily if misused. But so do many other APIs, like having a thread trying to grab the same lock twice :) Thanks for the comments, Andres Regards, Christian. Am 25.05.2017 um 02:00 schrieb Andres Rodriguez: When multiple environments are run

Re: [RFC] Exclusive gpu access for SteamVR usecases

2017-05-26 Thread Andres Rodriguez
iority of existing context in the same process unless the previous fd is closed. Thanks. Best Regards, David On 25 May 2017, at 8:00 AM, Andres Rodriguez <andre...@gmail.com <mailto:andre...@gmail.com>> wrote: When multiple environments are running simultaneously on a system, e.g. an X d

[PATCH 3/3] drm/amdgpu: add a mechanism to acquire gpu exclusivity

2017-05-24 Thread Andres Rodriguez
the next HMD vblank, general access to the gpu can be restored. The operation is limited to DRM_MASTER since it may lead to starvation. The implementation of drm leases is required to extend DRM_MASTER status to the SteamVRComposer. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drive

[RFC] Exclusive gpu access for SteamVR usecases

2017-05-24 Thread Andres Rodriguez
When multiple environments are running simultaneously on a system, e.g. an X desktop + a SteamVR game session, it may be useful to sacrifice performance in one environment in order to boost it on the other. This series provides a mechanism for a DRM_MASTER to provide exclusive gpu access to a

[PATCH 1/3] drm/amdgpu: add a new scheduler priority AMD_SCHED_PRIORITY_HIGH_SW

2017-05-24 Thread Andres Rodriguez
. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 8 +--- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 18 ++ drivers/gpu/drm/amd/scheduler/gpu_scheduler.h | 3 ++- include/uapi/drm/amdgpu_drm.h

[PATCH 2/3] drm/amdgpu: make amdgpu_to_sched_priority detect invalid parameters

2017-05-24 Thread Andres Rodriguez
Returning invalid priorities as _NORMAL is a backwards compatibility quirk of amdgpu_ctx_ioctl(). Move this detail one layer up where it belongs. Signed-off-by: Andres Rodriguez <andre...@gmail.com> --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 8 +--- drivers/gpu/drm/amd/sch

  1   2   3   4   5   >