Re: [PATCH 1/1] drm/amdkfd: Improve concurrency of event handling

2022-03-03 Thread Felix Kuehling
Am 2022-03-03 um 02:25 schrieb Christian König: Am 02.03.22 um 21:06 schrieb Felix Kuehling: Use rcu_read_lock to read p->event_idr concurrently with other readers and writers. Use p->event_mutex only for creating and destroying events and in kfd_wait_on_events. That might not necessary

Re: [PATCH 1/1] drm/amdkfd: Improve concurrency of event handling

2022-03-02 Thread Christian König
Am 02.03.22 um 21:06 schrieb Felix Kuehling: Use rcu_read_lock to read p->event_idr concurrently with other readers and writers. Use p->event_mutex only for creating and destroying events and in kfd_wait_on_events. That might not necessary work as you expected. rcu_read_lock() does not

RE: [PATCH 1/1] drm/amdkfd: Improve concurrency of event handling

2022-03-02 Thread Keely, Sean
[AMD Official Use Only] LGTM. Reviewed-by: Sean Keely -Original Message- From: Kuehling, Felix Sent: Wednesday, March 02, 2022 2:06 PM To: amd-gfx@lists.freedesktop.org Cc: Keely, Sean Subject: [PATCH 1/1] drm/amdkfd: Improve concurrency of event handling Use rcu_read_lock to read p

[PATCH 1/1] drm/amdkfd: Improve concurrency of event handling

2022-03-02 Thread Felix Kuehling
Use rcu_read_lock to read p->event_idr concurrently with other readers and writers. Use p->event_mutex only for creating and destroying events and in kfd_wait_on_events. Protect the contents of the kfd_event structure with a per-event spinlock that can be taken inside the rcu_read_lock critical