to prevent submit two or more IBs with PREEMPT flags.
Change-Id: Icdac89ddc525436905b3544635fd8cfd9146cdfd
Signed-off-by: Monk Liu
---
drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 13 -
1 file changed, 12 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
Change-Id: I779abc6a47593be0ff5234c3e2f2cdfd25ba70ca
Signed-off-by: Monk Liu
---
drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 4
1 file changed, 4 insertions(+)
diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c
b/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c
index 8dba5ff..be49c30 100644
--- a/drivers
when MCBP supported, we will set pre_enb bit for those
IBs with PREEMPT flag tagged
Change-Id: I753a850e6acdce56e22f873bc7fee8874c5a1a12
Signed-off-by: Monk Liu
---
include/uapi/drm/amdgpu_drm.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/include/uapi/drm/amdgpu_drm.h b/include/uapi/d
Preamble in linux doesn't mean it is CE PREAMBLE IB,
instead it means this IB could be dropped if no
ctx switch happens.
Change-Id: I2a1e567bccc8abb6d9ce117d3f2eb93dfd649fa1
Signed-off-by: Monk Liu
---
include/uapi/drm/amdgpu_drm.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --gi
On Tue, Mar 07, 2017 at 03:30:30PM -0500, Alex Deucher wrote:
> On Fri, Feb 24, 2017 at 2:19 PM, Lukas Wunner wrote:
> > An external Thunderbolt GPU can neither drive the laptop's panel nor be
> > powered off by the platform, so there's no point in registering it with
> > vga_switcheroo. In fact,
Forgot to mention, lockdep was clean with the following options enabled:
[*] Spinlock and rw-lock debugging: basic checks
[*] Mutex debugging: basic checks
[*] Sleep inside atomic section checking
Regards,
Andres
On 2017-03-07 06:50 PM, Andres Rodriguez wrote:
Updated with Christian and Alex's
Add an initial framework for changing the HW priorities of rings. The
framework allows requesting priority changes for the lifetime of an
amdgpu_job. After the job completes the priority will decay to the next
lowest priority for which a request is still valid.
A new ring function set_priority() c
Use an LRU policy to map usermode rings to HW compute queues.
Most compute clients use one queue, and usually the first queue
available. This results in poor pipe/queue work distribution when
multiple compute apps are running. In most cases pipe 0 queue 0 is
the only queue that gets used.
In orde
The MQD structure matches the reg layout. Take advantage of this to
simplify HQD programming.
Note that the ACTIVE field still needs to be programmed last.
Suggested-by: Felix Kuehling
Signed-off-by: Andres Rodriguez
---
drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 44 +--
drivers/g
Add amdgpu_queue_mgr, a mechanism that allows disjointing usermode's
ring ids from the kernel's ring ids.
The queue manager maintains a per-file descriptor map of user ring ids
to amdgpu_ring pointers. Once a map is created it is permanent (this is
required to maintain FIFO execution guarantees fo
Add a new context creation parameter to express a global context priority.
Contexts allocated with AMDGPU_CTX_PRIORITY_HIGH will receive higher
priority to schedule their work than AMDGPU_CTX_PRIORITY_NORMAL
(default) contexts.
v2: Instead of using flags, repurpose __pad
v3: Swap enum values of _
Programming CP_HQD_QUEUE_PRIORITY enables a queue to take priority over
other queues on the same pipe. Multiple queues on a pipe are timesliced
so this gives us full precedence over other queues.
Programming CP_HQD_PIPE_PRIORITY changes the SPI_ARB_PRIORITY of the
wave as follows:
0x2: CS_
Tonga based asics may experience hangs when an HQD's EOP parameters
are modified.
Workaround this HW issue by avoiding writes to these registers for
tonga asics.
Based on the following ROCm commit:
2a0fb8 - drm/amdgpu: Synchronize KFD HQD load protocol with CP scheduler
From the ROCm git reposit
Replace adev->srbm_mutex with a spinlock adev->srbm_lock
Signed-off-by: Andres Rodriguez
---
drivers/gpu/drm/amd/amdgpu/amdgpu.h | 2 +-
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c | 4 ++--
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v8.c | 4 ++--
drivers/gpu/drm/amd/am
Make amdgpu the owner of all per-pipe state of the HQDs.
This change will allow us to split the queues between kfd and amdgpu
with a queue granularity instead of pipe granularity.
This patch fixes kfd allocating an HDP_EOP region for its 3 pipes which
goes unused.
Reviewed-by: Edward O'Callaghan
Use the same gfx_*_mqd_commit function for kfd and amdgpu codepaths.
This removes the last duplicates of this programming sequence.
Reviewed-by: Edward O'Callaghan
Acked-by: Christian König
Signed-off-by: Andres Rodriguez
---
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c | 51 ++--
This information is already available in adev.
Reviewed-by: Edward O'Callaghan
Acked-by: Christian König
Signed-off-by: Andres Rodriguez
---
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c | 12 ++--
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v8.c | 12 ++--
2 files changed
The current implementation is hardcoded to enable ME1/PIPE0 interrupts
only.
This patch allows amdgpu to enable interrupts for any pipe of ME1.
Signed-off-by: Andres Rodriguez
---
drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 48 +--
drivers/gpu/drm/amd/amdgpu/gfx_v8_0
Update the KGD to KFD interface to allow sharing pipes with queue
granularity instead of pipe granularity.
This allows for more interesting pipe/queue splits.
v2: fix overflow check for res.queue_mask
v3: fix shift overflow when setting res.queue_mask
v4: fix comment in is_pipeline_enabled()
Rev
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 queues are spread over multiple pipes the hardware will be
able to better handle concurrent compute workloads.
amdgpu go
Pipes provide better concurrency than queues, therefore we want to make
sure that apps use queues from different pipes whenever possible.
Optimize for the trivial case where an app will consume rings in order,
therefore we don't want adjacent rings to belong to the same pipe.
Reviewed-by: Edward
The CP_MEC_DOORBELL_RANGE_* and CP_PQ_STATUS.DOORBELL_ENABLE registers
are not HQD specific.
They only need to be set once if at least 1 pipe requested doorbell
support.
v2: move doorbell_enable to amdgpu_gfx instead of amdgpu_device
Reviewed-by: Edward O'Callaghan
Acked-by: Christian König
Si
Rename straggler instances of r(adeon)dev to a(mdgpu)dev
Reviewed-by: Edward O'Callaghan
Acked-by: Christian König
Signed-off-by: Andres Rodriguez
---
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c | 70 +++---
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.h | 14 +++---
drivers
The gfxv7 contains a slightly different version of cik_mqd called
bonaire_mqd. This can introduce subtle bugs if fixes are not applied in
both places.
Reviewed-by: Edward O'Callaghan
Acked-by: Christian König
Signed-off-by: Andres Rodriguez
---
drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 135 +
Take ownership of pipe initialization away from KFD.
Note that hpd_eop_gpu_addr was already large enough to accomodate all
pipes.
Reviewed-by: Edward O'Callaghan
Acked-by: Christian König
Signed-off-by: Andres Rodriguez
---
drivers/gpu/drm/radeon/cik.c| 27 ++-
The MQD programming sequence currently exists in 3 different places.
Refactor it to absorb all the duplicates.
The success path remains mostly identical except for a slightly
different order in the non-kiq case. This shouldn't matter if the HQD
is disabled.
The error handling paths have been upda
Handle HQD deactivation timeouts instead of ignoring them.
Reviewed-by: Edward O'Callaghan
Acked-by: Christian König
Signed-off-by: Andres Rodriguez
---
drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 22 --
1 file changed, 20 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu
Previously the queue/pipe split with kfd operated with pipe
granularity. This patch allows amdgpu to take ownership of an arbitrary
set of queues.
It also consolidates the last few magic numbers in the compute
initialization process into mec_init.
Reviewed-by: Edward O'Callaghan
Acked-by: Christ
Updated with Christian and Alex's feedback.
Also added missing initialization of ring->num_jobs[] to PATCH 18
Added a new patch:
[PATCH 19/22] drm/amdgpu: convert srbm lock to a spinlock
Also some new benchmarks for the high priority queue using a modified
computeparticles that only takes 0.2ms
On Fri, Feb 24, 2017 at 2:19 PM, Lukas Wunner wrote:
> An external Thunderbolt GPU can neither drive the laptop's panel nor be
> powered off by the platform, so there's no point in registering it with
> vga_switcheroo. In fact, when the external GPU is runtime suspended,
> vga_switcheroo will cut
On 2017-03-07 06:00 AM, Christian König wrote:
Am 07.03.2017 um 02:10 schrieb Andres Rodriguez:
Add an initial framework for changing the HW priorities of rings. The
framework allows requesting priority changes for the lifetime of an
amdgpu_job. After the job completes the priority will decay
Am 07.03.2017 um 17:57 schrieb Alex Deucher:
On Tue, Mar 7, 2017 at 11:25 AM, Andres Rodriguez wrote:
On 2017-03-07 10:19 AM, Deucher, Alexander wrote:
-Original Message-
From: amd-gfx [mailto:amd-gfx-boun...@lists.freedesktop.org] On Behalf
Of Christian König
Sent: Tuesday, March 07,
On Tue, Mar 7, 2017 at 11:25 AM, Andres Rodriguez wrote:
>
>
> On 2017-03-07 10:19 AM, Deucher, Alexander wrote:
>>>
>>> -Original Message-
>>> From: amd-gfx [mailto:amd-gfx-boun...@lists.freedesktop.org] On Behalf
>>> Of Christian König
>>> Sent: Tuesday, March 07, 2017 6:00 AM
>>> To: An
On 2017-03-07 10:19 AM, Deucher, Alexander wrote:
-Original Message-
From: amd-gfx [mailto:amd-gfx-boun...@lists.freedesktop.org] On Behalf
Of Christian König
Sent: Tuesday, March 07, 2017 6:00 AM
To: Andres Rodriguez; amd-gfx@lists.freedesktop.org
Subject: Re: [PATCH 18/21] drm/amdgpu:
On 2017-03-07 05:31 AM, Christian König wrote:
Am 07.03.2017 um 02:10 schrieb Andres Rodriguez:
Add amdgpu_queue_mgr, a mechanism that allows disjointing usermode's
ring ids from the kernel's ring ids.
The queue manager maintains a per-file descriptor map of user ring ids
to amdgpu_ring point
> -Original Message-
> From: amd-gfx [mailto:amd-gfx-boun...@lists.freedesktop.org] On Behalf
> Of Christian König
> Sent: Tuesday, March 07, 2017 6:00 AM
> To: Andres Rodriguez; amd-gfx@lists.freedesktop.org
> Subject: Re: [PATCH 18/21] drm/amdgpu: add framework for HW specific
> priority
Am 07.03.2017 um 02:10 schrieb Andres Rodriguez:
Add an initial framework for changing the HW priorities of rings. The
framework allows requesting priority changes for the lifetime of an
amdgpu_job. After the job completes the priority will decay to the next
lowest priority for which a request is
Patches #10 and #16 are Reviewed-by: Christian König
.
Patches #20 and #21 are Acked-by: Christian König
.
Give me a second to go through patch #18 once more, but apart from that
the series is ready to land if Felix and Alex don't have more comments.
Regards,
Christian.
Am 07.03.2017 um 0
Am 07.03.2017 um 02:10 schrieb Andres Rodriguez:
Add amdgpu_queue_mgr, a mechanism that allows disjointing usermode's
ring ids from the kernel's ring ids.
The queue manager maintains a per-file descriptor map of user ring ids
to amdgpu_ring pointers. Once a map is created it is permanent (this i
39 matches
Mail list logo