Hi Russell,
On 29 September 2015 at 19:10, Russell King rmk+kernel@arm.linux.org.uk wrote:
Rather than using a spinlock, use xchg() to atomically update dplane->old_fb. This allows us to eliminate dplane->lock.
Signed-off-by: Russell King rmk+kernel@arm.linux.org.uk
[...]
@@ -76,13 +75,10 @@ static void armada_ovl_retire_fb(struct armada_ovl_plane *dplane, { struct drm_framebuffer *old_fb;
spin_lock(&dplane->lock);
old_fb = dplane->old_fb;
dplane->old_fb = fb;
spin_unlock(&dplane->lock);
old_fb = xchg(&dplane->old_fb, fb); if (old_fb)
armada_drm_queue_unref_work(dplane->base.dev, old_fb);
armada_drm_queue_unref_work(dplane->base.base.dev, old_fb);
Shouldn't this be part of another patch ?
-Emil