Received: by 10.223.176.5 with SMTP id f5csp2851184wra; Mon, 29 Jan 2018 05:09:19 -0800 (PST) X-Google-Smtp-Source: AH8x226nj1j541V5eJP6JyomirPfa+XeWy8BQg01Vtq4LlQfUSwscRgCA+/PpcEt+jvr1BlGhWht X-Received: by 10.98.112.4 with SMTP id l4mr26743377pfc.8.1517231359337; Mon, 29 Jan 2018 05:09:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517231359; cv=none; d=google.com; s=arc-20160816; b=wXu4SuGYaGTL06B8EZn6B0n9R3t3C5INIyyP+CpPbmML0LaS1xcAalmQkKtZuWL/SF wil78DWHjDKwwBMeaI9ahHZV1mrgYJEzsRuH7mHguFRKqC3Z2xflTbp9yxw7gZbYe/Y3 rSrPMtGUKBVGU5nY02jbnq4Vg1gim2GMTEImBEieSxYf3pfkL53R2Zbf72Xf+HCv6rcd MLmWJNDPduOREvg6kxZI1zScwGgoyP8FkwAFiTe3Q1/Gid2GyRUL5RU3nsChJNR4s9h1 ysyjVELBix+fNORmR1UomhwZX5cPO1eUPs65lWoCfKxxAuaXzxnbNsg9Dql3sISYTI7A qFWg== 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-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=JEMLSz91vkxAtOrCQ8aqzwo9ADota3pjP1d21+8AMJc=; b=AToqrim5HdoZQ2tkr5ECdOKo9UQzJuf7yULRHcC7DtQSc60l3d7GGeVKiq1xjlDGKB Ja0qSKzZhMFrD0FddWmYeDK6fv9YNqa8DhXvUEZSJwoWhe+hyqCx0sNFvFKyVhdjXPE6 /aSogAyWJGjkvJbC4xxBH88fmVtWOeBhuka5zHLv74tVa1uVn68uNfCIvF4hjRXzc6Xz Yyy69LBCwAOx1oXqBy/leA5DtUqRkMSs/1UEk8oxN567D3ztBQOFeAyIGU6S9MrnQDvv kyESJX0sK3u/NjRDKADiFG3uTyVWuohVS/YYbbmehBv8sFk9yKdj1PtPlGUmBZadNxOx xXaQ== 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 b63si11880198pfe.50.2018.01.29.05.09.05; Mon, 29 Jan 2018 05:09:19 -0800 (PST) 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 S1752023AbeA2NIZ (ORCPT + 99 others); Mon, 29 Jan 2018 08:08:25 -0500 Received: from mail.free-electrons.com ([62.4.15.54]:36687 "EHLO mail.free-electrons.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751839AbeA2NIY (ORCPT ); Mon, 29 Jan 2018 08:08:24 -0500 Received: by mail.free-electrons.com (Postfix, from userid 110) id 4573A219A7; Mon, 29 Jan 2018 14:08:23 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail.free-electrons.com X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,SHORTCIRCUIT, URIBL_BLOCKED shortcircuit=ham autolearn=disabled version=3.4.0 Received: from localhost (LStLambert-657-1-97-87.w90-63.abo.wanadoo.fr [90.63.216.87]) by mail.free-electrons.com (Postfix) with ESMTPSA id 12F09219A6; Mon, 29 Jan 2018 14:08:13 +0100 (CET) Date: Mon, 29 Jan 2018 14:08:13 +0100 From: Maxime Ripard To: Chen-Yu Tsai Cc: Daniel Vetter , Jani Nikula , Sean Paul , dri-devel , linux-kernel , linux-arm-kernel , thomas@vitsch.nl Subject: Re: [PATCH v2 16/19] drm/sun4i: backend: Assign the pipes automatically Message-ID: <20180129130813.rrnjzmskgjrbzxg2@flea.lan> References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="tos5ularur4d3or7" Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20171215 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --tos5ularur4d3or7 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Jan 29, 2018 at 10:22:54AM +0800, Chen-Yu Tsai wrote: > On Mon, Jan 22, 2018 at 6:35 PM, Maxime Ripard > wrote: > > Since we now have a way to enforce the zpos, check for the number of al= pha > > planes, the only missing part is to assign our pipe automatically inste= ad > > of hardcoding it. > > > > The algorithm is quite simple, but requires two iterations over the lis= t of > > planes. > > > > In the first one (which is the same one that we've had to check for alp= ha, > > the frontend usage, and so on), we order the planes by their zpos. > > > > We can then do a second iteration over that array by ascending zpos > > starting with the pipe 0. When and if we encounter our alpha plane, we = put > > it and all the other subsequent planes in the second pipe. > > > > And since we have runtime checks and pipe assignments now, we can just > > remove the static declaration of the planes we used to have. >=20 > It would be slightly better if you could split this out into a separate > patch. It's not immediately obvious to others that the changes to > sun4i_layer.c are self-contained, while the change to sun4i_layer.h > is part of the new pipeline tracking thing. Plus I think the way you > structured everything means it won't break if you split it out. You're right, I'll split this patch and resend it. I've pushed the patches 9-15 to drm-misc, with your suggestions when you had some. Thanks! Maxime --=20 Maxime Ripard, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com --tos5ularur4d3or7 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEE0VqZU19dR2zEVaqr0rTAlCFNr3QFAlpvHLwACgkQ0rTAlCFN r3QWAA/+JqxMUP+TpdaUaQJbs2bBUr0GqsVTb7Q0vVRMNPs2SdxK22VKSKsJkXvF QIZTfTb5+C3E7I0M4GWTgkGY5qm2UuFY9GijsbpcD/Wy4pzRplY8ldJ5XMUJXgZ2 MKq8v0tJPcCxdXULmjY6ilh1vJM1pwKUpCg4gmBkPGZilL/q9usY0k6FPhHaiJVj Wlw28vZfiTfEDHDyOh3MeLJ5ZxD5WGcwXJeRVzj2BWknRhsoLaVTlg6aKOss29uY vJhiNSLIFrljp3BVsBl9GqZ66FJaAuXtn+F61JfEClJScxJ+nERZGoI5S5jj/Xnm /EeopFZ3lDyARH7bsCQjsBvJQt/EuqRzT1xuu4xWjvhJWLOBqVfo8UYdXmf6Akqi 4GT9Mvb8Q4lF2KJxWZSyT4+WgkWuPC1qdrR8fdeClOUhBwFaOZSPoxWeW5Q/z9YV eNvgeN8ERSqZDET6mEjB+NZiuljgxhpKvs3A3dBWpXunAdozF89T2TDpKkPLBzwH 6gG0kNw5bCnZwMuItCRCWPz8ChGhoE4NKZ3A0lfIAWKJzwpndL45UWi0bleAA7pu Nq6G7WXg+rB0UoChdeRatRYDsOi12RSn8BbYIZeukeGpxGzcgpV+sDtUM0wLWDst wBB15LsMS1ZogAiW2nXGxyqIuhRjbKd/bpi65fGL0WEAJ0PCQj0= =oG3v -----END PGP SIGNATURE----- --tos5ularur4d3or7--