ABLE_SIGNAL_BIT
> unconditionally, it results in an expensive spinlock take for
> everyone. Instead just check if the callback is present. Suggested by
> Maarten.
>
> Also move misplaced kerneldoc hunk to the right patch.
>
> Cc: Maarten Lankhorst
> Reviewed-by: Christian König
Op 21-09-17 om 09:00 schreef Christian König:
> Am 20.09.2017 um 20:20 schrieb Daniel Vetter:
>> On Mon, Sep 11, 2017 at 01:06:32PM +0200, Christian König wrote:
>>> Am 11.09.2017 um 12:01 schrieb Chris Wilson:
[SNIP]
> Yeah, but that is illegal with a fence objects.
>
> When anybo
success (such as now).
>* This is paired with the write barrier from assigning
Should be safe from an infinite loop since the old fence is only unreffed after
the new pointer is written, so we'll always make progress. :)
Reviewed-by: Maarten Lankhorst
Op 15-12-15 om 18:19 schreef Dmitry Torokhov:
> On Tue, Dec 15, 2015 at 2:01 AM, Maarten Lankhorst
> wrote:
>> Op 15-12-15 om 02:29 schreef Dmitry Torokhov:
>>> Userspace can close the sync device while there are still active fence
>>> points, in which case kernel
Op 15-12-15 om 02:29 schreef Dmitry Torokhov:
> Userspace can close the sync device while there are still active fence
> points, in which case kernel produces the following warning:
>
> [ 43.853176] [ cut here ]
> [ 43.857834] WARNING: CPU: 0 PID: 892 at
> /mnt/host/sou
max_segment_count = (unsigned int)-1;
> + cons->max_segment_size = (unsigned int)-1;
> + cons->segment_boundary_mask = (unsigned long)-1;
> +}
Use DMA_SEGMENTS_MAX_SEG_COUNT or UINT/ULONG_MAX here instead?
Patches look sane,
Reviewed-By: Maarten Lankhorst
> +/*
> + * calc_cons
Op 28-01-15 om 13:54 schreef Sumit Semwal:
> At present, dma_buf_export() takes a series of parameters, which
> makes it difficult to add any new parameters for exporters, if required.
>
> Make it simpler by moving all these parameters into a struct, and pass
> the struct * as parameter to dma_buf_
op 02-07-14 07:37, Greg KH schreef:
> On Tue, Jul 01, 2014 at 12:57:02PM +0200, Maarten Lankhorst wrote:
>> So after some more hacking I've moved dma-buf to its own subdirectory,
>> drivers/dma-buf and applied the fence patches to its new place. I believe
>> that th
op 01-07-14 13:06, Arend van Spriel schreef:
> On 01-07-14 12:57, Maarten Lankhorst wrote:
>> Signed-off-by: Maarten Lankhorst
> It would help to use '-M' option with format-patch for this kind of rework.
>
> Regards,
> Arend
>
Thanks, was looking for some
r discussion w/ danvet and mlankorst
we decided that we need to be able to attach one fence to N dma-buf's,
so using the list_head in dma-fence struct would be problematic.
v5: [ Maarten Lankhorst ] Updated for dma-bikeshed-fence and dma-buf-manager.
v6: [ Maarten Lankhorst ] I remov
nce.h
v4: Add spinlock pointer to seqno_fence_init
v5: Add condition member to allow wait for != 0.
Fix small style errors pointed out by checkpatch.
v6: Move to a separate file. Fix up api changes in fences.
Signed-off-by: Maarten Lankhorst
Reviewed-by: Rob Clark #v4
---
Documentation/D
Signed-off-by: Maarten Lankhorst
---
Documentation/DocBook/device-drivers.tmpl |3
MAINTAINERS |4
drivers/Makefile |1
drivers/base/Makefile |1
drivers/base/dma-buf.c| 743
at it yet
I feel it should stay in staging, for now.
---
Maarten Lankhorst (9):
dma-buf: move to drivers/dma-buf
fence: dma-buf cross-device synchronization (v18)
seqno-fence: Hardware dma-buf implementation of fencing (v6)
dma-buf: use reservation objects
android: co
This allows reservation objects to be used in dma-buf. it's required
for implementing polling support on the fences that belong to a dma-buf.
Signed-off-by: Maarten Lankhorst
Acked-by: Mauro Carvalho Chehab #drivers/media/v4l2-core/
Acked-by: Thomas Hellstrom #drivers/gpu/drm/ttm
Signed-o
.
reservation_object_add_shared_fence() and
reservation_object_add_excl_fence() are used to assign a new
fence to a reservation_object pointer, to complete a reservation.
Signed-off-by: Maarten Lankhorst
Changes since v1:
- Add reservation_object_get_excl, reorder code a bit.
---
Documentation/DocBook/device-drivers.tmpl |1
allback in sync_fence_free if not all fences have fired.
v3:
- Merge Colin Cross' bugfixes, and the android fence merge optimization.
v4:
- Merge with the upstream fixes.
v5:
- Fix small style issues pointed out by Thomas Hellstrom.
v6:
- Fix for updates to fence api.
Signed-off-by: Maarten Lank
Thanks to Fengguang Wu for spotting a missing static cast.
v2:
- Kill unused variable need_shared.
v3:
- Clarify the BUG() in dma_buf_release some more. (Rob Clark)
Signed-off-by: Maarten Lankhorst
---
drivers/dma-buf/dma-buf.c | 108 +
include
Signed-off-by: Maarten Lankhorst
Reviewed-by: Rob Clark
---
include/linux/reservation.h | 20 +++-
1 file changed, 19 insertions(+), 1 deletion(-)
diff --git a/include/linux/reservation.h b/include/linux/reservation.h
index 813dae960ebd..f3f57460a205 100644
--- a/include
is needed,
rcu_dereference followed by fence_get_rcu can be used, if the shared
fences are needed it's recommended to use the supplied functions.
Signed-off-by: Maarten Lankhorst
Reviewed-By: Thomas Hellstrom
---
drivers/dma-buf/dma-buf.c | 47 --
drivers/dma-buf/fence.c |
Hey,
op 20-06-14 22:52, Thierry Reding schreef:
> On Thu, Jun 19, 2014 at 02:28:14PM +0200, Daniel Vetter wrote:
>> On Thu, Jun 19, 2014 at 1:48 PM, Thierry Reding
>> wrote:
> With these changes, can we pull the android sync logic out of
> drivers/staging/ now?
Afaik the google guys
op 19-06-14 17:22, Colin Cross schreef:
> On Wed, Jun 18, 2014 at 11:37 PM, Daniel Vetter wrote:
>> On Wed, Jun 18, 2014 at 06:15:56PM -0700, Greg KH wrote:
>>> On Wed, Jun 18, 2014 at 12:37:11PM +0200, Maarten Lankhorst wrote:
>>>> Just to show it's easy.
.
reservation_object_test_signaled_rcu() will test if all fences of the
reservation_object are signaled without using the ww_mutex.
reservation_object_get_excl() is added because touching the fence_excl
member directly will trigger a sparse warning.
Signed-off-by: Maarten Lankhorst
Reviewed-By: Thomas
r discussion w/ danvet and mlankorst
we decided that we need to be able to attach one fence to N dma-buf's,
so using the list_head in dma-fence struct would be problematic.
v5: [ Maarten Lankhorst ] Updated for dma-bikeshed-fence and dma-buf-manager.
v6: [ Maarten Lankhorst ] I remov
This allows reservation objects to be used in dma-buf. it's required
for implementing polling support on the fences that belong to a dma-buf.
Signed-off-by: Maarten Lankhorst
Acked-by: Mauro Carvalho Chehab #drivers/media/v4l2-core/
Acked-by: Thomas Hellstrom #drivers/gpu/drm/ttm
Signed-o
.
reservation_object_add_shared_fence() and
reservation_object_add_excl_fence() are used to assign a new
fence to a reservation_object pointer, to complete a reservation.
Signed-off-by: Maarten Lankhorst
Changes since v1:
- Add reservation_object_get_excl, reorder code a bit.
---
drivers/base/dma-buf.c | 35
ttm, and
make dealing with rcu less painful.
Patches slightly updated to fix compilation with armada and
new atomic primitives, but otherwise identical.
---
Maarten Lankhorst (8):
fence: dma-buf cross-device synchronization (v17)
seqno-fence: Hardware dma-buf implementation of fencing
Thanks to Fengguang Wu for spotting a missing static cast.
v2:
- Kill unused variable need_shared.
v3:
- Clarify the BUG() in dma_buf_release some more. (Rob Clark)
Signed-off-by: Maarten Lankhorst
---
drivers/base/dma-buf.c | 108 +++
include
allback in sync_fence_free if not all fences have fired.
v3:
- Merge Colin Cross' bugfixes, and the android fence merge optimization.
v4:
- Merge with the upstream fixes.
v5:
- Fix small style issues pointed out by Thomas Hellstrom.
Signed-off-by: Maarten Lankhorst
Acked-by: John Stultz
---
Signed-off-by: Maarten Lankhorst
Reviewed-by: Rob Clark
---
include/linux/reservation.h | 20 +++-
1 file changed, 19 insertions(+), 1 deletion(-)
diff --git a/include/linux/reservation.h b/include/linux/reservation.h
index 813dae960ebd..f3f57460a205 100644
--- a/include
nce.h
v4: Add spinlock pointer to seqno_fence_init
v5: Add condition member to allow wait for != 0.
Fix small style errors pointed out by checkpatch.
Signed-off-by: Maarten Lankhorst
Reviewed-by: Rob Clark #v4
---
Documentation/DocBook/device-drivers.tmpl |1
drivers
op 20-05-14 17:13, Thomas Hellstrom schreef:
On 05/19/2014 03:13 PM, Maarten Lankhorst wrote:
op 19-05-14 15:42, Thomas Hellstrom schreef:
Hi, Maarten!
Some nitpicks, and that krealloc within rcu lock still worries me.
Otherwise looks good.
/Thomas
On 04/23/2014 12:15 PM, Maarten
op 19-05-14 15:42, Thomas Hellstrom schreef:
Hi, Maarten!
Some nitpicks, and that krealloc within rcu lock still worries me.
Otherwise looks good.
/Thomas
On 04/23/2014 12:15 PM, Maarten Lankhorst wrote:
@@ -55,8 +60,8 @@ int reservation_object_reserve_shared(struct
reservation_object *obj
op 23-04-14 13:15, Maarten Lankhorst schreef:
This adds 4 more functions to deal with rcu.
reservation_object_get_fences_rcu() will obtain the list of shared
and exclusive fences without obtaining the ww_mutex.
reservation_object_wait_timeout_rcu() will wait on all fences of the
.
reservation_object_test_signaled_rcu() will test if all fences of the
reservation_object are signaled without using the ww_mutex.
reservation_object_get_excl() is added because touching the fence_excl
member directly will trigger a sparse warning.
Signed-off-by: Maarten Lankhorst
---
Using seqcount and
op 11-04-14 21:35, Thomas Hellstrom schreef:
On 04/11/2014 08:09 PM, Maarten Lankhorst wrote:
op 11-04-14 12:11, Thomas Hellstrom schreef:
On 04/11/2014 11:24 AM, Maarten Lankhorst wrote:
op 11-04-14 10:38, Thomas Hellstrom schreef:
Hi, Maarten.
Here I believe we encounter a lot of locking
op 11-04-14 21:30, Thomas Hellstrom schreef:
Hi!
On 04/11/2014 08:09 PM, Maarten Lankhorst wrote:
op 11-04-14 12:11, Thomas Hellstrom schreef:
On 04/11/2014 11:24 AM, Maarten Lankhorst wrote:
op 11-04-14 10:38, Thomas Hellstrom schreef:
Hi, Maarten.
Here I believe we encounter a lot of
op 11-04-14 12:11, Thomas Hellstrom schreef:
On 04/11/2014 11:24 AM, Maarten Lankhorst wrote:
op 11-04-14 10:38, Thomas Hellstrom schreef:
Hi, Maarten.
Here I believe we encounter a lot of locking inconsistencies.
First, it seems you're use a number of pointers as RCU pointers wi
op 11-04-14 10:38, Thomas Hellstrom schreef:
Hi, Maarten.
Here I believe we encounter a lot of locking inconsistencies.
First, it seems you're use a number of pointers as RCU pointers without
annotating them as such and use the correct rcu
macros when assigning those pointers.
Some pointers (l
op 10-04-14 13:08, Thomas Hellstrom schreef:
On 04/10/2014 12:07 PM, Maarten Lankhorst wrote:
Hey,
op 10-04-14 10:46, Thomas Hellstrom schreef:
Hi!
Ugh. This became more complicated than I thought, but I'm OK with moving
TTM over to fence while we sort out
how / if we're going t
Hey,
op 10-04-14 10:46, Thomas Hellstrom schreef:
Hi!
Ugh. This became more complicated than I thought, but I'm OK with moving
TTM over to fence while we sort out
how / if we're going to use this.
While reviewing, it struck me that this is kind of error-prone, and hard
to follow since we're op
assign a new
fence to a reservation_object pointer, to complete a reservation.
Signed-off-by: Maarten Lankhorst
---
drivers/base/dma-buf.c | 35 +++---
drivers/base/fence.c|4 +
drivers/base/reservation.c | 154 +++
include/linux
M to fence, so I had to keep it in.
If nobody objects I'll probably merge that patch through drm, because
some care is needed in ttm before it can flip the switch on rcu.
---
Maarten Lankhorst (2):
reservation: update api and add some helpers
[RFC] reservation: add suppport for r
.
reservation_object_get_excl() is added because touching the fence_excl
member directly will trigger a sparse warning.
Signed-off-by: Maarten Lankhorst
---
drivers/base/dma-buf.c | 46 +++--
drivers/base/reservation.c | 147 +--
include
op 04-03-14 11:00, Daniel Vetter schreef:
On Tue, Mar 04, 2014 at 09:20:58AM +0100, Maarten Lankhorst wrote:
op 04-03-14 09:14, Daniel Vetter schreef:
On Tue, Mar 04, 2014 at 08:50:38AM +0100, Maarten Lankhorst wrote:
op 03-03-14 22:11, Daniel Vetter schreef:
On Mon, Feb 17, 2014 at 04:57
op 04-03-14 09:14, Daniel Vetter schreef:
On Tue, Mar 04, 2014 at 08:50:38AM +0100, Maarten Lankhorst wrote:
op 03-03-14 22:11, Daniel Vetter schreef:
On Mon, Feb 17, 2014 at 04:57:19PM +0100, Maarten Lankhorst wrote:
Android syncpoints can be mapped to a timeline. This removes the need
to
op 03-03-14 22:11, Daniel Vetter schreef:
On Mon, Feb 17, 2014 at 04:57:19PM +0100, Maarten Lankhorst wrote:
Android syncpoints can be mapped to a timeline. This removes the need
to maintain a separate api for synchronization. I've left the android
trace events in place, but the core
This allows reservation objects to be used in dma-buf. it's required
for implementing polling support on the fences that belong to a dma-buf.
Signed-off-by: Maarten Lankhorst
Acked-by: Mauro Carvalho Chehab #drivers/media/v4l2-core/
Acked-by: Thomas Hellstrom #drivers/gpu/drm/ttm
---
dr
r discussion w/ danvet and mlankorst
we decided that we need to be able to attach one fence to N dma-buf's,
so using the list_head in dma-fence struct would be problematic.
v5: [ Maarten Lankhorst ] Updated for dma-bikeshed-fence and dma-buf-manager.
v6: [ Maarten Lankhorst ] I remov
allback in sync_fence_free if not all fences have fired.
v3:
- Merge Colin Cross' bugfixes, and the android fence merge optimization.
v4:
- Merge with the upstream fixes.
v5:
- Fix small style issues pointed out by Thomas Hellstrom.
Signed-off-by: Maarten Lankhorst
---
drivers/staging/
Signed-off-by: Maarten Lankhorst
Reviewed-by: Rob Clark
---
include/linux/reservation.h | 20 +++-
1 file changed, 19 insertions(+), 1 deletion(-)
diff --git a/include/linux/reservation.h b/include/linux/reservation.h
index 813dae960ebd..f3f57460a205 100644
--- a/include
Thanks to Fengguang Wu for spotting a missing static cast.
v2:
- Kill unused variable need_shared.
v3:
- Clarify the BUG() in dma_buf_release some more. (Rob Clark)
Signed-off-by: Maarten Lankhorst
---
drivers/base/dma-buf.c | 108 +++
include
nce.h
v4: Add spinlock pointer to seqno_fence_init
v5: Add condition member to allow wait for != 0.
Fix small style errors pointed out by checkpatch.
Signed-off-by: Maarten Lankhorst
Reviewed-by: Rob Clark #v4
---
Documentation/DocBook/device-drivers.tmpl |1
drivers
a comment removed)
- add poll support to dma-buf (added comment)
---
Maarten Lankhorst (6):
fence: dma-buf cross-device synchronization (v17)
seqno-fence: Hardware dma-buf implementation of fencing (v5)
dma-buf: use reservation objects
android: convert sync to fence api, v5
op 19-02-14 14:56, Thomas Hellstrom schreef:
>+static void fence_check_cb_func(struct fence *f, struct fence_cb *cb)
>+{
>+ struct sync_fence_cb *check = container_of(cb, struct sync_fence_cb, cb);
>+ struct sync_fence *fence = check->fence;
>+
>+ // TODO: Add a fence->status member and che
op 17-02-14 19:41, Christian König schreef:
Am 17.02.2014 19:24, schrieb Rob Clark:
On Mon, Feb 17, 2014 at 12:36 PM, Christian König
wrote:
Am 17.02.2014 18:27, schrieb Rob Clark:
On Mon, Feb 17, 2014 at 11:56 AM, Christian König
wrote:
Am 17.02.2014 16:56, schrieb Maarten Lankhorst
had to fix
some fallout from the rebase, hopefully everything's clean now,
and ready for -next.
---
Maarten Lankhorst (6):
fence: dma-buf cross-device synchronization (v17)
seqno-fence: Hardware dma-buf implementation of fencing (v4)
dma-buf: use reservation objects
a
Signed-off-by: Maarten Lankhorst
---
include/linux/reservation.h | 18 +-
1 file changed, 17 insertions(+), 1 deletion(-)
diff --git a/include/linux/reservation.h b/include/linux/reservation.h
index 813dae960ebd..92c4851b5a39 100644
--- a/include/linux/reservation.h
+++ b
Thanks to Fengguang Wu for spotting a missing static cast.
v2:
- Kill unused variable need_shared.
Signed-off-by: Maarten Lankhorst
---
drivers/base/dma-buf.c | 101 +++
include/linux/dma-buf.h | 12 ++
2 files changed, 113 insertions
t all fences have fired.
v3:
- Merge Colin Cross' bugfixes, and the android fence merge optimization.
v4:
- Merge with the upstream fixes.
Signed-off-by: Maarten Lankhorst
---
drivers/staging/android/Kconfig |1
drivers/staging/android/Makefile |2
drivers/staging/android
oved into dma-fence.c since
not much was left of the file. Lots of documentation added.
v3: Use fence_ops instead of custom callbacks. Moved to own file
to avoid circular dependency between dma-buf.h and fence.h
v4: Add spinlock pointer to seqno_fence_init
Signed-off-by: Maarten Lankhorst
---
This allows reservation objects to be used in dma-buf. it's required
for implementing polling support on the fences that belong to a dma-buf.
Signed-off-by: Maarten Lankhorst
Acked-by: Mauro Carvalho Chehab #drivers/media/v4l2-core/
---
drivers/base/dma-buf.c |
r discussion w/ danvet and mlankorst
we decided that we need to be able to attach one fence to N dma-buf's,
so using the list_head in dma-fence struct would be problematic.
v5: [ Maarten Lankhorst ] Updated for dma-bikeshed-fence and dma-buf-manager.
v6: [ Maarten Lankhorst ] I remov
op 13-01-14 19:50, Colin Cross schreef:
> On Mon, Jan 13, 2014 at 4:31 AM, Maarten Lankhorst
> wrote:
>> The kernel fence implementation doesn't use event queues, but needs
>> to perform the same wake up. The symbol is not exported, since the
>> fence implementa
Thanks to Fengguang Wu for spotting a missing static cast.
Signed-off-by: Maarten Lankhorst
---
drivers/base/dma-buf.c | 102 +++
include/linux/dma-buf.h | 12 ++
2 files changed, 114 insertions(+)
diff --git a/drivers/base/dma-buf.c b
Signed-off-by: Maarten Lankhorst
---
include/linux/reservation.h | 18 +-
1 file changed, 17 insertions(+), 1 deletion(-)
diff --git a/include/linux/reservation.h b/include/linux/reservation.h
index 813dae960ebd..92c4851b5a39 100644
--- a/include/linux/reservation.h
+++ b
t all fences have fired.
v3:
- Merge Colin Cross' bugfixes, and the android fence merge optimization.
Signed-off-by: Maarten Lankhorst
---
drivers/staging/android/Kconfig |1
drivers/staging/android/Makefile |2
drivers/staging/android/sw_sync.c|4
drivers/stagi
This allows reservation objects to be used in dma-buf. it's required
for implementing polling support on the fences that belong to a dma-buf.
Signed-off-by: Maarten Lankhorst
---
drivers/base/dma-buf.c | 22 --
drivers/gpu/drm/drm_pr
The kernel fence implementation doesn't use event queues, but needs
to perform the same wake up. The symbol is not exported, since the
fence implementation is not built as a module.
Signed-off-by: Maarten Lankhorst
---
include/linux/wait.h |1 +
kernel/sched/core.c |2 +-
2
danvet and mlankorst
we decided that we need to be able to attach one fence to N dma-buf's,
so using the list_head in dma-fence struct would be problematic.
v5: [ Maarten Lankhorst ] Updated for dma-bikeshed-fence and dma-buf-manager.
v6: [ Maarten Lankhorst ] I removed dma_fence_cance
The following series implements fence and converts dma-buf and
android sync to use it. Patch 6 and 7 add support for polling
to dma-buf, blocking until all fences are signaled.
---
Maarten Lankhorst (7):
sched: allow try_to_wake_up to be used internally outside of core.c
fence: dma
oved into dma-fence.c since
not much was left of the file. Lots of documentation added.
v3: Use fence_ops instead of custom callbacks. Moved to own file
to avoid circular dependency between dma-buf.h and fence.h
v4: Add spinlock pointer to seqno_fence_init
Signed-off-by: Maarten Lankhorst
---
Op 20-08-13 11:51, Christian König schreef:
> Am 20.08.2013 11:36, schrieb Maarten Lankhorst:
> [SNIP]
>
>>>>>> [SNIP]
>>>>>> +/**
>>>>>> + * radeon_fence_enable_signaling - enable signalling on fence
>>>>>> + * @fenc
Op 20-08-13 10:37, Christian König schreef:
> Am 19.08.2013 21:37, schrieb Maarten Lankhorst:
>> Op 19-08-13 14:35, Christian König schreef:
>>> Am 19.08.2013 12:17, schrieb Maarten Lankhorst:
>>>> [SNIP]
>>>> @@ -190,25 +225,24 @@ void radeon_fence_pro
Op 19-08-13 14:35, Christian König schreef:
> Am 19.08.2013 12:17, schrieb Maarten Lankhorst:
>> [SNIP]
>> @@ -190,25 +225,24 @@ void radeon_fence_process(struct radeon_device *rdev,
>> int ring)
>> }
>> } while (atomic64_xchg(&rdev-
Signed-off-by: Maarten Lankhorst
---
diff --git a/drivers/gpu/drm/radeon/radeon.h b/drivers/gpu/drm/radeon/radeon.h
index 9f19259..971284e 100644
--- a/drivers/gpu/drm/radeon/radeon.h
+++ b/drivers/gpu/drm/radeon/radeon.h
@@ -64,6 +64,7 @@
#include
#include
#include
+#include
#include
nouveau was a bit tricky, it has no support for interrupts on
---
diff --git a/drivers/gpu/drm/nouveau/nouveau_fence.c
b/drivers/gpu/drm/nouveau/nouveau_fence.c
index be31499..78714e4 100644
--- a/drivers/gpu/drm/nouveau/nouveau_fence.c
+++ b/drivers/gpu/drm/nouveau/nouveau_fence.c
@@ -35,88 +35
Op 15-08-13 15:14, Rob Clark schreef:
> On Thu, Aug 15, 2013 at 7:16 AM, Maarten Lankhorst
> wrote:
>> Op 12-08-13 17:43, Rob Clark schreef:
>>> On Mon, Jul 29, 2013 at 10:05 AM, Maarten Lankhorst
>>> wrote:
>>>> +
> [snip]
>>>> +/**
>&
Op 15-08-13 14:45, Marcin Ślusarz schreef:
> 2013/8/15 Maarten Lankhorst :
>> A fence can be attached to a buffer which is being filled or consumed
>> by hw, to allow userspace to pass the buffer without waiting to another
>> device. For example, userspace can call page_flip
n the
fence is passed).
v3: Fix locking fail in attach_fence() and get_fence()
v4: Remove tie-in w/ dma-buf.. after discussion w/ danvet and mlankorst
we decided that we need to be able to attach one fence to N dma-buf's,
so using the list_head in dma-fence struct would be problem
n the
fence is passed).
v3: Fix locking fail in attach_fence() and get_fence()
v4: Remove tie-in w/ dma-buf.. after discussion w/ danvet and mlankorst
we decided that we need to be able to attach one fence to N dma-buf's,
so using the list_head in dma-fence struct would be problem
Op 12-08-13 17:43, Rob Clark schreef:
> On Mon, Jul 29, 2013 at 10:05 AM, Maarten Lankhorst
> wrote:
>> A fence can be attached to a buffer which is being filled or consumed
>> by hw, to allow userspace to pass the buffer without waiting to another
>> device. For exa
n the
fence is passed).
v3: Fix locking fail in attach_fence() and get_fence()
v4: Remove tie-in w/ dma-buf.. after discussion w/ danvet and mlankorst
we decided that we need to be able to attach one fence to N dma-buf's,
so using the list_head in dma-fence struct would be problem
Op 20-06-13 14:23, Ingo Molnar schreef:
> * Maarten Lankhorst wrote:
>
>> Well they've helped me with some of the changes and contributed some
>> code and/or fixes, but if acked-by is preferred I'll use that..
> Such contributions can be credited in the changel
Op 20-06-13 13:55, Ingo Molnar schreef:
> * Maarten Lankhorst wrote:
>
>> Changes since RFC patch v1:
>> - Updated to use atomic_long instead of atomic, since the reservation_id
>> was a long.
>> - added mutex_reserve_lock_slow and mutex_reserv
Vetter (1):
mutex: w/w mutex slowpath debugging
Maarten Lankhorst (6):
arch: make __mutex_fastpath_lock_retval return whether fastpath succeeded
or not.
mutex: add support for wound/wait style locks, v5
mutex: Add ww tests to lib/locking-selftest.c. v5
mutex: add more
locking after ww_acquire_done has been called.
- Added a test for unbalance for ctx->acquired dropping below zero.
- Added a test for unlocked ww_mutex with ctx != NULL.
Signed-off-by: Maarten Lankhorst
---
lib/locking-selftest.c | 400 ++--
1 f
was previously used.
Changes since v1, pointed out by Francesco Lavra:
- fix a small comment issue in mutex_32.h
- fix the __mutex_fastpath_lock_retval macro for mutex-null.h
Signed-off-by: Maarten Lankhorst
---
arch/ia64/include/asm/mutex.h| 10 --
arch/powerpc/include/asm/mutex.h
*, normal
functions can be used. Inline versions still exist for extra
debugging.
- Cleanup unneeded memory barriers, add comment to the remaining
smp_mb().
Signed-off-by: Maarten Lankhorst
Signed-off-by: Daniel Vetter
Signed-off-by: Rob Clark
---
Documentation/ww-mutex-design.txt | 343
.debug definition
to work correctly. (mlankhorst)
v6:
Do not inject -EDEADLK when ctx->acquired == 0, because
the _slow paths are merged now. (mlankhorst)
Cc: Steven Rostedt
Signed-off-by: Daniel Vetter
Signed-off-by: Maarten Lankhorst
---
include/linux/mutex.h |8
When CONFIG_PROVE_LOCKING is not enabled, more tests are expected to
pass unexpectedly, but there no tests that should start to fail that
pass with CONFIG_PROVE_LOCKING enabled.
Signed-off-by: Maarten Lankhorst
---
lib/locking-selftest.c |8 +---
1 file changed, 5 insertions(+), 3
None of the ww_mutex codepaths should be taken in the 'normal'
mutex calls. The easiest way to verify this is by using the
normal mutex calls, and making sure o.ctx is unmodified.
Signed-off-by: Maarten Lankhorst
---
lib/locking-selftes
Signed-off-by: Maarten Lankhorst
---
lib/locking-selftest.c | 264 +++-
1 file changed, 261 insertions(+), 3 deletions(-)
diff --git a/lib/locking-selftest.c b/lib/locking-selftest.c
index 37faefd..d554f3f 100644
--- a/lib/locking-selftest.c
+++ b
Op 17-06-13 15:04, Inki Dae schreef:
>
>> -Original Message-
>> From: Maarten Lankhorst [mailto:maarten.lankho...@canonical.com]
>> Sent: Monday, June 17, 2013 8:35 PM
>> To: Inki Dae
>> Cc: dri-de...@lists.freedesktop.org; linux-fb...@v
Op 17-06-13 13:15, Inki Dae schreef:
> This patch adds a buffer synchronization framework based on DMA BUF[1]
> and reservation[2] to use dma-buf resource, and based on ww-mutexes[3]
> for lock mechanism.
>
> The purpose of this framework is not only to couple cache operations,
> and buffer access
Op 28-05-13 16:48, Maarten Lankhorst schreef:
> Version 4 already?
>
> Small api changes since v3:
> - Remove ww_mutex_unlock_single and ww_mutex_lock_single.
> - Rename ww_mutex_trylock_single to ww_mutex_trylock.
> - Remove separate implementations of ww_mutex_lock_slow*, no
Op 07-06-13 04:32, 김승우 schreef:
> Hello Maarten,
>
> On 2013년 06월 05일 22:23, Maarten Lankhorst wrote:
>> Op 31-05-13 10:54, Seung-Woo Kim schreef:
>>> dma-buf attachment has only exporter private data, but importer private data
>>> can be useful for importer esp
Op 31-05-13 10:54, Seung-Woo Kim schreef:
> dma-buf attachment has only exporter private data, but importer private data
> can be useful for importer especially to re-import the same dma-buf.
> To use importer private data in attachment of the device, the function to
> search attachment in the atta
Op 29-05-13 12:33, Inki Dae schreef:
> Hi,
>
> Just minor comments
>
> +Usage
>> +-
>> +
>> +Three different ways to acquire locks within the same w/w class. Common
>> +definitions for methods #1 and #2:
>> +
>> +static DEFINE_WW_CLASS(ww_class);
>> +
>> +struct obj {
>> + struct ww_mutex
Op 28-05-13 21:18, Daniel Vetter schreef:
> On Tue, May 28, 2013 at 04:48:45PM +0200, Maarten Lankhorst wrote:
>> This stresses the lockdep code in some ways specifically useful to
>> ww_mutexes. It adds checks for most of the common locking errors.
>>
>> Changes s
debugging, and to annotate.
- Cleanup unneeded memory barriers, add comment to the remaining
smp_mb().
Thanks to Daniel Vetter, Rob Clark and Peter Zijlstra for their feedback.
---
Daniel Vetter (1):
mutex: w/w mutex slowpath debugging
Maarten Lankhorst (3):
arch: make
1 - 100 of 197 matches
Mail list logo