Received: by 2002:a05:6a10:1d13:0:0:0:0 with SMTP id pp19csp1627508pxb; Fri, 20 Aug 2021 09:55:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwSZ0+krDc55jXbK0s7dUFqgfuSKTFxrndwz/xUzY6JTUa9NDBIlqqIUzQTZh8nLGOeBeJd X-Received: by 2002:a50:99d9:: with SMTP id n25mr23703806edb.310.1629478512176; Fri, 20 Aug 2021 09:55:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1629478512; cv=none; d=google.com; s=arc-20160816; b=EP6IntkXwIRi1LjcgH/O+FXDLkCDgszW4vFB2wOMbQy1HkADw+/SqDHkacFi0mPNb+ D9ycqmY2xVpAEFeOy4Y/STywW+Ic7Q4grzDx+2bHll7hcqwPYVI5ugVq7dafdW0Avi2R CL4PGV2pEo4GgDPcRw6KqC2H2UPwQ/UWBz6VLvBOdElQ+kV0SYogvGub5PQrreGAsylA XhzTNnrCbhQy9nG0CCjBJxtWge/NmSV8NwZOkmP4ItKOFHT6F3tIYNF1INuF7uL4sZiR uwkU84uj7tTW1INBD1Iwse02VQOoBnUYcYUhx+dPTmexPeIgHBsKLgiq0LM17aZ2nZQs Ylxw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature :dkim-signature; bh=s6i/N6kug4HBurK8lYVaEHfU/qC+w14m1meq5QcLypw=; b=SZKYSY2rw9PTt/TTcWc2uwmNWGF2iG7F2/PeFI4ALP9SltMbPicCW2lt9ATyYv2Kg3 eEOO0F/tQCYEOlFBZGJbyVjjgpFTXorX+OydFTRNS7eDvjlu+B4OCEmIuSXMBFO75Tks U1XSNA4aoRQMv6IqFTJ8oux5jcsxeQIwFEHbrlwh0AcBBXoxwxZ3+JkDEbUFWAYpG5/I WA7hQEDDOndoGrtCAatJROy7id5XTD1tbPrGFqjQduwa++sH9oOVcD3gETqL46gRNbUk yJWhwxovK+Mt7et6+FdEuR+HK37TLp7CV/F72LXqROsAkSCKfW4ZMpBSXWN3zL3SR4Ie ZF0g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cerno.tech header.s=fm3 header.b=jzUwFvNH; dkim=pass header.i=@messagingengine.com header.s=fm3 header.b=JrakuMBS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=cerno.tech Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b2si6933079ejd.610.2021.08.20.09.54.45; Fri, 20 Aug 2021 09:55:12 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@cerno.tech header.s=fm3 header.b=jzUwFvNH; dkim=pass header.i=@messagingengine.com header.s=fm3 header.b=JrakuMBS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=cerno.tech Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231290AbhHTQwg (ORCPT + 99 others); Fri, 20 Aug 2021 12:52:36 -0400 Received: from new1-smtp.messagingengine.com ([66.111.4.221]:60969 "EHLO new1-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229977AbhHTQwg (ORCPT ); Fri, 20 Aug 2021 12:52:36 -0400 Received: from compute2.internal (compute2.nyi.internal [10.202.2.42]) by mailnew.nyi.internal (Postfix) with ESMTP id 1A33F5800F5; Fri, 20 Aug 2021 12:49:12 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute2.internal (MEProxy); Fri, 20 Aug 2021 12:49:12 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm3; bh=s6i/N6kug4HBurK8lYVaEHfU/qC +w14m1meq5QcLypw=; b=jzUwFvNHSnky2fJVWMG8FeWAXiTc7zvMecWmzPZXMTW 5rPzhaeHCgpj07VPQZxMU6qIgSFHdVUK2UqnhpwADyoH0kXGpdgwePsiTIZMU+Iq nlkCXjx8FVEO6E/IcFVCVnhl8zk8U0tUP5VTk7F8+CDwx8Ddn0Gp38Un86hvWuPz lpZCMl3Fr1lfhPIAvDUfq7lcKqPOuldU6aVSt5brTlgWRJ+KgXNpd7FQ8qnoroCL /LajLumexaZYZXywvsgctKAm2k1uJKYs2HZE8H44vxCWyKlccsY/27GTizTC4wQX b5J13f7ZuQsLawfUP+/08F/eFrUB0p9Kl/CxdBtf9Lw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=s6i/N6 kug4HBurK8lYVaEHfU/qC+w14m1meq5QcLypw=; b=JrakuMBSCwUYelRIEix1z1 oah9w8txJUS/EFjRMIfbQMP0tNQAuKP0YkJ/ZBwaPCkwJW2l1gycnJf4kYQRGXDE desxiEh0OnXOZ8JGgCog2h2Ndir0LyL0Pur9TfRUFml0MLiQtkSE8trgFg9mftyr Cqc0mpiFIFqF/niyT0ikwZ8X75O7agZXv2eNkRthdtRs+u9QEXr0qimLMheC/IYo dTVhGetGEbcSiJ+UZzYMY9VKkGuMEuuwlj+kZgAl1wZ30OLNNDyXtMiLxmyiwdxt 6WWxIcrTj7JzLrBbJYtdyPW7/vNwKaOBA+bIUUSBbnFy69L4P1Ag4KNkwGBz63xw == X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvtddrleelgddutdefucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvffukfhfgggtuggjsehgtderredttddvnecuhfhrohhmpeforgigihhm vgcutfhiphgrrhguuceomhgrgihimhgvsegtvghrnhhordhtvggthheqnecuggftrfgrth htvghrnhepleekgeehhfdutdeljefgleejffehfffgieejhffgueefhfdtveetgeehieeh gedunecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepmh grgihimhgvsegtvghrnhhordhtvggthh X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Fri, 20 Aug 2021 12:49:07 -0400 (EDT) Date: Fri, 20 Aug 2021 18:49:06 +0200 From: Maxime Ripard To: "a.hajda" Cc: Sam Ravnborg , Daniel Vetter , David Airlie , Thierry Reding , Laurent Pinchart , Maarten Lankhorst , Thomas Zimmermann , Jernej Skrabec , Neil Armstrong , Jonas Karlman , Robert Foss , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: Re: [PATCH v2 0/8] drm/bridge: Make panel and bridge probe order consistent Message-ID: <20210820164906.3xfxy43udc7hxflj@gilmour> References: <20210728133229.2247965-1-maxime@cerno.tech> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="sbpyoycfgn424k53" Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --sbpyoycfgn424k53 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Andrzej, On Wed, Aug 04, 2021 at 04:09:38PM +0200, a.hajda wrote: > Hi Maxime, >=20 > I have been busy with other tasks, and I did not follow the list last=20 > time, so sorry for my late response. >=20 > On 28.07.2021 15:32, Maxime Ripard wrote: > > Hi, > >=20 > > We've encountered an issue with the RaspberryPi DSI panel that prevente= d the > > whole display driver from probing. > >=20 > > The issue is described in detail in the commit 7213246a803f ("drm/vc4: = dsi: > > Only register our component once a DSI device is attached"), but the ba= sic idea > > is that since the panel is probed through i2c, there's no synchronizati= on > > between its probe and the registration of the MIPI-DSI host it's attach= ed to. > >=20 > > We initially moved the component framework registration to the MIPI-DSI= Host > > attach hook to make sure we register our component only when we have a = DSI > > device attached to our MIPI-DSI host, and then use lookup our DSI devic= e in our > > bind hook. > >=20 > > However, all the DSI bridges controlled through i2c are only registerin= g their > > associated DSI device in their bridge attach hook, meaning with our cha= nge >=20 > I guess this is incorrect. I have promoted several times the pattern=20 > that device driver shouldn't expose its interfaces (for example=20 > component_add, drm_panel_add, drm_bridge_add) until it gathers all=20 > required dependencies. In this particular case bridges should defer=20 > probe until DSI bus becomes available. I guess this way the patch you=20 > reverts would work. >=20 > I advised few times this pattern in case of DSI hosts, apparently I=20 > didn't notice the similar issue can appear in case of bridges. Or there= =20 > is something I have missed??? >=20 > Anyway there are already eleven(?) bridge drivers using this pattern. I= =20 > wonder if fixing it would be difficult, or if it expose other issues??? > The patches should be quite straightforward - move=20 > of_find_mipi_dsi_host_by_node and mipi_dsi_device_register_full to probe= =20 > time. I gave this a try today, went back to the current upstream code and found that indeed it works. I converted two bridges that works now. I'll send a new version some time next week and will convert all the others if we agree on the approach. Thanks for the suggestion! > Finally I think that if we will not fix these bridge drivers we will=20 > encounter another set of issues with new platforms connecting "DSI host= =20 > drivers assuming this pattern" and "i2c/dsi device drivers assuming=20 > pattern already present in the bridges". Yeah, this is exactly the situation I'm in :) Maxime --sbpyoycfgn424k53 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCYR/dAgAKCRDj7w1vZxhR xYyIAP9QJYMcMeJKGOWtfkVHWa6UcWUgQjWFK6FrcjkrrWVtxwD/a8rMGvXmVVJq OoGA9td4D3UANC1W0k+LCikxHGQpvwQ= =E8Tv -----END PGP SIGNATURE----- --sbpyoycfgn424k53--