Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp1806928imm; Tue, 22 May 2018 09:36:48 -0700 (PDT) X-Google-Smtp-Source: AB8JxZp5C7XLlg9bVxuxKhgDEcaXgeaWPIta3s7tG7TGAl6ns2tRY1p+TFd4WSXHLKCuIbZW6JEg X-Received: by 2002:a17:902:7146:: with SMTP id u6-v6mr24989212plm.289.1527007008775; Tue, 22 May 2018 09:36:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527007008; cv=none; d=google.com; s=arc-20160816; b=HbkuaYZ/Z7fZWpGS7FdlAzHwEpCYuCLfAsGNHXaZqYC3gNnBGcE41vKCleRur1jE5T vA7Z/VZ7CMCFn6agQLjqh7vb/VFE0kqMT6yYBA1dz+tG7+/wt2PRVoVoRiAU6FGJpXsx fMPSgVehAEvHmEpvGYJtc1Wq3OWeEaqdFrnw4tkIOOYmfDPXSFqetCGv8gnSlQVy2O9X maKwIbGpiqvsHmyF5wAHyjg/k0cYUkzzq/KeIviYEvLbJyWdE5mHiqWoR8gf0Bk+jPq5 08iIGmfMs5aWtAdX4PyUvwUcw0MAwI2Zb9cPZICeQpkRwQ8Zp3GEBUlKaA6i9Mv5xJOR b5ig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date :arc-authentication-results; bh=ZDBNuNOR2qvjpBsUaiqHCHTeB5es0RUHpy/ovTSHg5M=; b=mLuO51mfy4R9uYlAdHIwG1AaMsBsimULQfONKP5oo8Vw2l+9puMYXAHer166ejhNdO 75YB7GZk8rXMUglyP49UgLu4GIyft/NsXxoHhnTZlaWW2jeTIfn1ljlvzVzGlMz0LLAo c0aplGigJZyU0JcPBasTVt1KhYoeeinXJcBfTnUIdHzBQMIWf6ERyvi6pEzwRP4F3jTD 6xvts5/AO0HVstKYsNHrSZZ6C4fURzOqUQztfGvPYc8duRI1xTE9NKQ4qtjmu6c+HgfF JJN72fjHPbgp+B/D2W0INdHAPnOY/qK2nEdNDovzJ/H/FtVuMmSDl0MeZZFRcgrsCX8r LapA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u189-v6si5647715pgb.247.2018.05.22.09.36.32; Tue, 22 May 2018 09:36:48 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752276AbeEVQfz (ORCPT + 99 others); Tue, 22 May 2018 12:35:55 -0400 Received: from usa-sjc-mx-foss1.foss.arm.com ([217.140.101.70]:41500 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752187AbeEVQfw (ORCPT ); Tue, 22 May 2018 12:35:52 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 8388F1596; Tue, 22 May 2018 09:35:52 -0700 (PDT) Received: from e110455-lin.cambridge.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.72.51.249]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 546EF3F24A; Tue, 22 May 2018 09:35:52 -0700 (PDT) Received: by e110455-lin.cambridge.arm.com (Postfix, from userid 1000) id AC6696809DE; Tue, 22 May 2018 17:35:50 +0100 (BST) Date: Tue, 22 May 2018 17:35:50 +0100 From: Liviu Dudau To: Eric Anholt Cc: Gustavo Padovan , Maarten Lankhorst , Sean Paul , Jonathan Corbet , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, David Airlie , Brian Starkey , Alexandru-Cosmin Gheorghe , Boris Brezillon , Maxime Ripard , Daniel Stone , Mihail Atanassov Subject: Re: [PATCH v8 2/3] drm: writeback: Add out-fences for writeback connectors Message-ID: <20180522163550.GE1582@e110455-lin.cambridge.arm.com> References: <20180518151743.29937-1-Liviu.Dudau@arm.com> <20180518151743.29937-3-Liviu.Dudau@arm.com> <87a7ssu91a.fsf@anholt.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <87a7ssu91a.fsf@anholt.net> User-Agent: Mutt/1.9.5 (2018-04-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 21, 2018 at 12:02:25PM -0700, Eric Anholt wrote: > Liviu Dudau writes: > > > From: Brian Starkey > > > > Add the WRITEBACK_OUT_FENCE_PTR property to writeback connectors, to > > enable userspace to get a fence which will signal once the writeback is > > complete. It is not allowed to request an out-fence without a > > framebuffer attached to the connector. > > > > A timeline is added to drm_writeback_connector for use by the writeback > > out-fences. > > > > diff --git a/include/drm/drm_writeback.h b/include/drm/drm_writeback.h > > index cf3a28676006a..6a7462c1821ad 100644 > > --- a/include/drm/drm_writeback.h > > +++ b/include/drm/drm_writeback.h > > @@ -49,6 +49,32 @@ struct drm_writeback_connector { > > * drm_writeback_signal_completion() > > */ > > struct list_head job_queue; > > + > > + /** > > + * @fence_context: > > + * > > + * timeline context used for fence operations. > > + */ > > + unsigned int fence_context; > > + /** > > + * @fence_lock: > > + * > > + * spinlock to protect the fences in the fence_context. > > + */ > > + spinlock_t fence_lock; > > + /** > > + * @fence_seqno: > > + * > > + * Seqno variable used as monotonic counter for the fences > > + * created on the connector's timeline. > > + */ > > + unsigned long fence_seqno; > > + /** > > + * @timeline_name: > > + * > > + * The name of the connector's fence timeline. > > + */ > > + char timeline_name[32]; > > }; > > > > struct drm_writeback_job { > > @@ -59,12 +85,14 @@ struct drm_writeback_job { > > * framebuffer reference to a workqueue. > > */ > > struct work_struct cleanup_work; > > + > > /** > > * @list_entry: > > * > > * List item for the connector's @job_queue > > */ > > struct list_head list_entry; > > + > > /** > > * @fb: > > * > > Move this hunk into patch 1? I can, however this is the only change I will be making. Is it worth respinning a new revision for it? > > Other than that, the series is: > > Reviewed-by: Eric Anholt Many thanks for that! > > It's pretty clean and makes sense to me. I only had some questions > about the job_queue, which seems superfluous if we aren't supporting > firing off a new writeback while an old one is outstanding (and maybe we > should throw an error in that case). Still, I think this is ready to land. I know Sean and Daniel are on holiday. Are you OK to pull this into drm-misc? Should I ask Gustavo to do it? Best regards, Liviu -- ==================== | I would like to | | fix the world, | | but they're not | | giving me the | \ source code! / --------------- ¯\_(ツ)_/¯