From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933594AbcKQTC6 (ORCPT ); Thu, 17 Nov 2016 14:02:58 -0500 Received: from mail.free-electrons.com ([62.4.15.54]:49351 "EHLO mail.free-electrons.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932335AbcKQTC4 (ORCPT ); Thu, 17 Nov 2016 14:02:56 -0500 Date: Thu, 17 Nov 2016 20:02:54 +0100 From: Maxime Ripard To: Chen-Yu Tsai Cc: David Airlie , linux-sunxi@googlegroups.com, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] drm/sun4i: Only count TCON endpoints as valid outputs Message-ID: <20161117190254.d4doghspvz6ma6x2@lukather> References: <20161116093732.12828-1-wens@csie.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="5rewihgziplgx6tf" Content-Disposition: inline In-Reply-To: <20161116093732.12828-1-wens@csie.org> User-Agent: Mutt/1.6.2-neo (2016-08-21) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --5rewihgziplgx6tf Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Nov 16, 2016 at 05:37:31PM +0800, Chen-Yu Tsai wrote: > The sun4i DRM driver counts the number of endpoints it found and > registers the whole DRM pipeline if any endpoints are found. >=20 > However, if the TCON and its child endpoints (LCD panels, TV encoder, > HDMI encoder, MIPI DSI encoder, etc.) aren't found, that means we > don't have any usable CRTCs, and the display pipeline is incomplete > and useless. If some node set as available is not probed, then yes, it does, but I'm not really sure how it's a problem. Quite the opposite actually. > The whole DRM display pipeline should only be registered and enabled > if there are proper outputs available. Unless I've misunderstood what you're saying, we could have the writeback for example that would just need the display engine. > The debug message "Queued %d outputs on pipeline %d\n" is also telling. >=20 > This patch makes the driver only count enabled TCON endpoints. If > none are found, the DRM pipeline is not used. This avoids screwing > up the simple framebuffer provided by the bootloader in cases where > we aren't able to support the display with the DRM subsystem, due > to lack of panel or bridge drivers, or just lack of progress. The framebuffer is removed only at bind time, which means that all the drivers have probed already. Lack of progress isn't an issue here, since the node simply won't be there, and we wouldn't have it in the component lists. And lack of drivers shouldn't be an issue either, since in order for bind to be called, all the drivers would have gone through their probe. So I'm not really sure what it fixes. Maxime --=20 Maxime Ripard, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com --5rewihgziplgx6tf Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIcBAEBCAAGBQJYLf7aAAoJEBx+YmzsjxAgeC8P/01h8w/t4kQhmIsDL8oMSy7F ox+nAHQcn/DCxxZ5cEAdWXfa8n5PPC1C/Du40y1x9uQCZrb34GgjOJVUBPU2qh5d YP9buDGULUNhNs7ST+1qKcZ7QriN3p9/lY/nyykCm85kH98iCdkmhX6rkLeWFWGU J5JHOYcm3mtsUEifd9J+4n4XNGV/CeHqZRzMYjThVKN/qS6f0nLPJaCQJqlQ1T7B 42DtgzuC3We5dwTmE5uZfLpejGngqS7IeuWuKG+ZkrMxFPQ53DI8TgGtPehkWExj tK+vJiZHf2ToIrE7+1+Ne82dBE+UNkP1ho9PRaQcY/GyZQc/5MoNfv3uV/rnqdnA VHQ54mVZBeLSdMaAaC0XAoq1U3jkuTQ2d9da4ZjXz4v250Q7koDsGwbE3h0CY4HG Cv0QsKZ7+NbdHOAkhgJjniMB+CWcQ7ckgI/jKahWft7pWgnsK9MJfhJTro5358lm GMG8bZRtdAgPST9Ha7pTQugn3G7Fb6FhQon44KwtxyH37dw/LUEbe1TfugcXebOa /8FCAp8xOCh4p0uPBuR8DGq0GD+vZqgSIJfugEfvVAKeuNbad9z1sotE0APYX/ot qd998oLra/Cv75rFl+80GErjJkbV/Kd83m5wQUYukKmyi8qm9SGUDJ+yKsqeTxoH u8ZaxXkBG9doidOe0k1v =bm0N -----END PGP SIGNATURE----- --5rewihgziplgx6tf--