Re: [PATCH 1/1] drm/amdkfd: Do not ignore requested queue size during allocation

2017-12-01 Thread Felix Kuehling
On 2017-11-30 06:51 PM, Jan Vesely wrote: > > It's not a userspace queue that stops. I'm using kernel dbgdev to issue > wave_resume commands. (waves are halted after executing > s_sendmsg_halt). > I bumped KFD_KERNEL_QUEUE_SIZE to 16KB to make sure all 320 resume > commads fit (otherwise I get

Re: [PATCH 1/1] drm/amdkfd: Do not ignore requested queue size during allocation

2017-12-01 Thread Felix Kuehling
DIQ is the debug interface queue. Are you running a GPU debugger? Otherwise I would not expect to even see a DIQ. Are you not seeing any compute queues in mqds? If there are no compute queues in mqds, that means your queue has been destroyed. That would explain why the read pointer is not

Re: [PATCH 1/1] drm/amdkfd: Do not ignore requested queue size during allocation

2017-12-01 Thread Felix Kuehling
To answer your questions about decoding MQDs, take a look at struct vi_mqd in drivers/gpu/drm/amd/include/vi_structs.h. What you're looking at is a binary dump of that structure, one per queue. The information in the MQD may not always be up to date, because the MQD represents an unmapped queue.

Re: [PATCH 1/1] drm/amdkfd: Do not ignore requested queue size during allocation

2017-11-30 Thread Jan Vesely
On Wed, 2017-11-29 at 16:58 -0500, Felix Kuehling wrote: > You can see the state of the queues in debugfs: > /sys/kernel/debug/kfd/... You can look at MQDs and HQDs. thanks. how do I decode the information? The rptr always stops at pos 60 which looks like this in mqds: DIQ on device 45a2

Re: [PATCH 1/1] drm/amdkfd: Do not ignore requested queue size during allocation

2017-11-29 Thread Felix Kuehling
You can see the state of the queues in debugfs: /sys/kernel/debug/kfd/... You can look at MQDs and HQDs. If your application isn't stopping queues deliberately, queues get disabled by evictions, usually temporarily. You'll see kernel messages when that happens. A VM fault will result in queues

Re: [PATCH 1/1] drm/amdkfd: Do not ignore requested queue size during allocation

2017-11-29 Thread Jan Vesely
On Mon, 2017-11-20 at 14:22 -0500, Felix Kuehling wrote: > I think this patch is not correct. The EOP-mem is not associated with > the queue size. The EOP buffer is a separate buffer used by the firmware > to handle command completion. As I understand it, this allows more > concurrency, while

Re: [PATCH 1/1] drm/amdkfd: Do not ignore requested queue size during allocation

2017-11-21 Thread Felix Kuehling
On 2017-11-21 06:44 AM, Oded Gabbay wrote: > Thanks Felix for catching that, For some reason I remembered EOP > buffer should be the same size of the queue. The EOP queue size is hard-coded to prop.eop_ring_buffer_size = PAGE_SIZE for kernel queues in initialize in kfd_kernel_queue.c. I'm not

Re: [PATCH 1/1] drm/amdkfd: Do not ignore requested queue size during allocation

2017-11-21 Thread Oded Gabbay
Thanks Felix for catching that, For some reason I remembered EOP buffer should be the same size of the queue. Then we can remove the queue size parameter from that function ? On Mon, Nov 20, 2017 at 9:22 PM, Felix Kuehling wrote: > I think this patch is not correct. The

Re: [PATCH 1/1] drm/amdkfd: Do not ignore requested queue size during allocation

2017-11-20 Thread Felix Kuehling
I think this patch is not correct. The EOP-mem is not associated with the queue size. The EOP buffer is a separate buffer used by the firmware to handle command completion. As I understand it, this allows more concurrency, while still making it look like all commands in the queue are completing in

Re: [PATCH 1/1] drm/amdkfd: Do not ignore requested queue size during allocation

2017-11-19 Thread Oded Gabbay
On Thu, Nov 16, 2017 at 11:36 PM, Jan Vesely wrote: > Signed-off-by: Jan Vesely > --- > drivers/gpu/drm/amd/amdkfd/kfd_kernel_queue_vi.c | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) > > diff --git

[PATCH 1/1] drm/amdkfd: Do not ignore requested queue size during allocation

2017-11-16 Thread Jan Vesely
Signed-off-by: Jan Vesely --- drivers/gpu/drm/amd/amdkfd/kfd_kernel_queue_vi.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_kernel_queue_vi.c b/drivers/gpu/drm/amd/amdkfd/kfd_kernel_queue_vi.c index