Re: [RFC PATCH v3 13/21] drm/exec: Rework contended locking

2024-05-29 Thread Thomas Hellström
On Tue, 2024-05-28 at 13:03 +0200, Christian König wrote: > Am 28.05.24 um 10:07 schrieb Thomas Hellström: > > On Tue, 2024-05-28 at 08:51 +0200, Christian König wrote: > > > > 2) Any contended lock held at loop start is completely > > > > encapsulated > > > > in > > > > the ww transaction and can

Re: [RFC PATCH v3 13/21] drm/exec: Rework contended locking

2024-05-28 Thread Christian König
Am 28.05.24 um 10:07 schrieb Thomas Hellström: On Tue, 2024-05-28 at 08:51 +0200, Christian König wrote: 2) Any contended lock held at loop start is completely encapsulated in the ww transaction and can and will be unlocked when exiting it, so this patch doesn't introduce any additional problems

Re: [RFC PATCH v3 13/21] drm/exec: Rework contended locking

2024-05-28 Thread Thomas Hellström
On Tue, 2024-05-28 at 08:51 +0200, Christian König wrote: > Hi Thomas, > > Am 28.05.24 um 08:36 schrieb Thomas Hellström: > > Hi, Christian. > > > > I'd appreciate if you could respond to the below, since it is a bit > > hard to try to design around a problem I don't believe exists, and > > come

Re: [RFC PATCH v3 13/21] drm/exec: Rework contended locking

2024-05-27 Thread Christian König
Hi Thomas, Am 28.05.24 um 08:36 schrieb Thomas Hellström: Hi, Christian. I'd appreciate if you could respond to the below, since it is a bit hard to try to design around a problem I don't believe exists, and come up with a good solution for that. In short. 1) To prefault userptr we have to exi

Re: [RFC PATCH v3 13/21] drm/exec: Rework contended locking

2024-05-27 Thread Thomas Hellström
Hi, Christian. I'd appreciate if you could respond to the below, since it is a bit hard to try to design around a problem I don't believe exists, and come up with a good solution for that. In short. 1) To prefault userptr we have to exit the ww transaction anyway. 2) Any contended lock held at lo

Re: [RFC PATCH v3 13/21] drm/exec: Rework contended locking

2024-05-22 Thread Thomas Hellström
On Wed, 2024-05-22 at 18:52 +0200, Christian König wrote: > Am 22.05.24 um 16:32 schrieb Thomas Hellström: > > On Wed, 2024-05-22 at 07:52 +0200, Christian König wrote: > > > Am 21.05.24 um 09:16 schrieb Thomas Hellström: > > > > If contention and backoff occurs during a drm_exec ww > > > > transac

Re: [RFC PATCH v3 13/21] drm/exec: Rework contended locking

2024-05-22 Thread Christian König
Am 22.05.24 um 16:32 schrieb Thomas Hellström: On Wed, 2024-05-22 at 07:52 +0200, Christian König wrote: Am 21.05.24 um 09:16 schrieb Thomas Hellström: If contention and backoff occurs during a drm_exec ww transaction, the contended lock is not locked again until the next orinary attempt to loc

Re: [RFC PATCH v3 13/21] drm/exec: Rework contended locking

2024-05-22 Thread Thomas Hellström
On Wed, 2024-05-22 at 07:52 +0200, Christian König wrote: > Am 21.05.24 um 09:16 schrieb Thomas Hellström: > > If contention and backoff occurs during a drm_exec ww transaction, > > the contended lock is not locked again until the next orinary > > attempt to lock a dma_resv lock. However, with the

Re: [RFC PATCH v3 13/21] drm/exec: Rework contended locking

2024-05-21 Thread Christian König
Am 21.05.24 um 09:16 schrieb Thomas Hellström: If contention and backoff occurs during a drm_exec ww transaction, the contended lock is not locked again until the next orinary attempt to lock a dma_resv lock. However, with the introduction of drm_exec_trylock(), that doesn't work, since the locki