From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mout-p-103.mailbox.org (mout-p-103.mailbox.org [80.241.56.161]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 03AF0382F05; Mon, 2 Mar 2026 21:34:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=80.241.56.161 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772487286; cv=none; b=d0opz3GtTdwv9mSCz1rq0ZNroq794xhwZLos8kQA5PnzxOrWUqxBB6t8z/SzWXSY3D+HfCanDYY1laG/9CqKKx1xIkaik5YSkxuo2a/CBdLj5aKW3hmIjwN4jXlzezMqbaUhFaAa3tnQS1dZjaWWqR6qE56U6sTNLC/YQJb2vTA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772487286; c=relaxed/simple; bh=UQGveZAg1RdW8UUbtNEC9Z8+VEui6RAonhnhCSGXybI=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=qxxbrW4wuqdQ9IW/huTRHb9GpnK2oRQ1y7i+aswt7t705Bp/qlWsgFf62PE3tQW1xHnrN0T6XnMOhqjOIOfApSHdLlo+0+jSVhePmve366Q0wVMvBSquES0oqKW3523Cxha8EstepyHQeEbgHVYJOdSy7eDzQJAwfbVqYVG93zA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=mailbox.org; spf=pass smtp.mailfrom=mailbox.org; dkim=pass (2048-bit key) header.d=mailbox.org header.i=@mailbox.org header.b=LAxHCE/S; arc=none smtp.client-ip=80.241.56.161 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=mailbox.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mailbox.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=mailbox.org header.i=@mailbox.org header.b="LAxHCE/S" Received: from smtp202.mailbox.org (smtp202.mailbox.org [10.196.197.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-103.mailbox.org (Postfix) with ESMTPS id 4fPsdl6jx7z9sdH; Mon, 2 Mar 2026 22:34:35 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mailbox.org; s=mail20150812; t=1772487276; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=xp8sg5gVtxoKedtyD9+EqXP+jjBRz+jOb9nPGoQLblA=; b=LAxHCE/SWju9DJ7RUefqhrCGp/HxEgKgZ+/Dn4G6+umv0DfVTRTARwej2JbHvjkbae3e86 I7juJ3W6XjL5gZsRcp/14sFIcfOTsH3dr4SyM24H95VQbjAND8Y1vuz/o1Wv2zp36YbJPy vgtKGAiOJB0vWg6J/sLCWcOk+MNx+b7o8ezil2X2haqDe/TLBASWyRFLse+UxNdfVzF6uI oK35F4svLhLIpWYI2cetsGNsgKflH0y0DQdyypP34WcIJVUsRTeCuKEOcfg8dOLhWNWOt8 WX5ao+JEpVJfNO8Q5eUge9km80LTrW72+GjwXWoMTZQZaiqqr8/kMiLGKkSbSA== Message-ID: Date: Mon, 2 Mar 2026 22:34:31 +0100 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Subject: Re: [PATCH v2] drm/bridge: waveshare-dsi: Register and attach our DSI device at probe To: Luca Ceresoli , dri-devel@lists.freedesktop.org Cc: Andrzej Hajda , David Airlie , Jernej Skrabec , Jonas Karlman , Laurent Pinchart , Maarten Lankhorst , Maxime Ripard , Neil Armstrong , Robert Foss , Simona Vetter , Thomas Zimmermann , linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org References: <20260206125801.78705-1-marek.vasut+renesas@mailbox.org> Content-Language: en-US From: Marek Vasut In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-MBO-RS-ID: 0a60f08183c5a211308 X-MBO-RS-META: z3bdwrxqqkiyhhkwi8xtr3eyg31pu438 On 2/6/26 3:34 PM, Luca Ceresoli wrote: > Hi Marek, > > On Fri Feb 6, 2026 at 1:57 PM CET, Marek Vasut wrote: >> In order to avoid any probe ordering issue, the best practice is to move >> the secondary MIPI-DSI device registration and attachment to the >> MIPI-DSI host at probe time. >> >> Besides solving the probe ordering problems, this makes the bridge work >> with R-Car DU. The R-Car DU will attempt to locate the DSI host bridge in >> its own rcar_du_probe()->rcar_du_modeset_init()->rcar_du_encoder_init() >> by calling of_drm_find_bridge() which calls of_drm_find_and_get_bridge() >> and iterates over bridge_list to locate the DSI host bridge. >> >> However, unless the WS driver calls mipi_dsi_attach() in probe(), the >> DSI host bridge .attach callback rcar_mipi_dsi_host_attach() is not >> called and the DSI host bridge is not added into bridge_list. Therefore >> the of_drm_find_and_get_bridge() called from du_probe() will never find >> the DSI host bridge and probe will indefinitelly fail with -EPROBE_DEFER. >> >> The circular dependency here is, that if rcar_du_encoder_init() would >> manage to find the DSI host bridge, it would call the WS driver .attach >> callback ws_bridge_bridge_attach(), but this is too late and can never >> happen. This change avoids the circular dependency. >> >> Reviewed-by: Luca Ceresoli >> Signed-off-by: Marek Vasut > > Thanks for the very clear description! R-by confirmed. Can this be applied now ?