Re: [Intel-gfx] [PATCH 17/22] drm/i915: Use atomics to manipulate obj->frontbuffer_bits

2016-07-28 Thread Joonas Lahtinen
On to, 2016-07-28 at 11:10 +0100, Chris Wilson wrote: > On Thu, Jul 28, 2016 at 12:49:31PM +0300, Joonas Lahtinen wrote: > > > > On ke, 2016-07-27 at 12:14 +0100, Chris Wilson wrote: > > > > > >  static int i915_gem_object_list_info(struct seq_file *m, void *data) > > > diff --git

Re: [Intel-gfx] [PATCH 17/22] drm/i915: Use atomics to manipulate obj->frontbuffer_bits

2016-07-28 Thread Chris Wilson
On Thu, Jul 28, 2016 at 12:49:31PM +0300, Joonas Lahtinen wrote: > On ke, 2016-07-27 at 12:14 +0100, Chris Wilson wrote: > >  static int i915_gem_object_list_info(struct seq_file *m, void *data) > > diff --git a/drivers/gpu/drm/i915/i915_drv.h > > b/drivers/gpu/drm/i915/i915_drv.h > > index

Re: [Intel-gfx] [PATCH 17/22] drm/i915: Use atomics to manipulate obj->frontbuffer_bits

2016-07-28 Thread Daniel Vetter
On Wed, Jul 27, 2016 at 12:14:55PM +0100, Chris Wilson wrote: > The individual bits inside obj->frontbuffer_bits are protected by each > plane->mutex, but the whole bitfield may be accessed by multiple KMS > operations simultaneously and so the RMW need to be under atomics. > However, for updating

Re: [Intel-gfx] [PATCH 17/22] drm/i915: Use atomics to manipulate obj->frontbuffer_bits

2016-07-28 Thread Joonas Lahtinen
On ke, 2016-07-27 at 12:14 +0100, Chris Wilson wrote: >  static int i915_gem_object_list_info(struct seq_file *m, void *data) > diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h > index a24d31e3e014..b6b9a1f78238 100644 > --- a/drivers/gpu/drm/i915/i915_drv.h > +++

[Intel-gfx] [PATCH 17/22] drm/i915: Use atomics to manipulate obj->frontbuffer_bits

2016-07-27 Thread Chris Wilson
The individual bits inside obj->frontbuffer_bits are protected by each plane->mutex, but the whole bitfield may be accessed by multiple KMS operations simultaneously and so the RMW need to be under atomics. However, for updating the single field we do not need to mandate that it be under the