From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtpout-03.galae.net (smtpout-03.galae.net [185.246.85.4]) (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 778C839EF2E for ; Tue, 29 Sep 2026 07:27:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.246.85.4 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1790666876; cv=none; b=saaYXjvW3ej9Vt8lZQF5UnrgXRj/OwXsKP9T274f1CO/d5dY/BgMZXeBTx2obrpagLWt9I2E7F0aI/8jQ1OrxM3Zlua/qfA1kH++WzhpHmdriyiUa6gJJSp4Ei9jtY/qmSibeTT7crkImj5bDDYqwTShRqaOQGinqzo1PWZ5b4c= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1790666876; c=relaxed/simple; bh=z8eAcRt4TChyHTyuUodztbeR8MepdRK0oigfLeCJ1NY=; h=Mime-Version:Content-Type:Date:Message-Id:Subject:Cc:To:From: References:In-Reply-To; b=om1yjmc3BinuxtxYJhpg9I7k2VGuQNolH2f01BN3QS0LQOv1oXvCICM6iatk2K/rvy9q3H55pnkBKZbErfjCL9gZIZYG+rUMOJJp8BTdT+qbuI9VmFNRg6g85YAw54z9lwIxsZW+x98aGA+lWz1tpnHuyMTFXVNaWQuQPoBiWNg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b=zUtWawuc; arc=none smtp.client-ip=185.246.85.4 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="zUtWawuc" Received: from smtpout-01.galae.net (smtpout-01.galae.net [212.83.139.233]) by smtpout-03.galae.net (Postfix) with ESMTPS id B301F4E410BB for ; Tue, 29 Sep 2026 07:27:49 +0000 (UTC) Received: from mail.galae.net (mail.galae.net [212.83.136.155]) by smtpout-01.galae.net (Postfix) with ESMTPS id 6FBA760749; Tue, 29 Sep 2026 07:27:49 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id 7A173102F1E1D; Tue, 29 Sep 2026 09:27:27 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=dkim; t=1790666865; h=from:subject:date:message-id:to:cc:mime-version:content-type: content-transfer-encoding:in-reply-to:references; bh=6z9//+D0Q6VMBTcc9ojEGZtfSdov1XXVNeeruScr3A0=; b=zUtWawucfhqE9LJMaIjV23h5QqOgTgci0S2/yjUEsAvPdCO6+bcMPxKW3dwUHIgc/dlDHx 5I7l8Yg/Hj68EnIDUYKxmON+sEx9ElxKZIwM2kR31LlP61b/94Qkrq23jBaphNnrwKs20S S+stRQckkC6yK420QjVVmcJafrgIWE3JAUWRcCkZvA422vzZSW+RfAYUzjTJFwF9VSpQa7 kww6z0UxwVbrMy4jFGgWYj6glw/rQUkcdAchSzs5Qhzh/QBOIjS/dgAh0Fi4oSTnV/7GHL SbBfslNPDNdkpmRMeIYgidzdyu0XQ6VG0OWSxpY8ucTWEpvnzYDlSxWjUShPyQ== Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8 Date: Tue, 29 Sep 2026 09:27:26 +0200 Message-Id: Subject: Re: [PATCH] drm/bridge: add missing drm/drm_panel.h inclusions Cc: "Arnd Bergmann" , "Sasha Finkelstein" , "Janne Grunau" , "Maarten Lankhorst" , "Maxime Ripard" , "Thomas Zimmermann" , "Manikandan Muralidharan" , "Dharma Balasubiramani" , "Nicolas Ferre" , "Alexandre Belloni" , "Claudiu Beznea" , "Jagan Teki" , "Andrzej Hajda" , "Neil Armstrong" , "Robert Foss" , "Laurent Pinchart" , "Jonas Karlman" , "Jernej Skrabec" , "Liu Ying" , "Frank Li" , "Sascha Hauer" , "Pengutronix Kernel Team" , "Fabio Estevam" , "Douglas Anderson" , "Philipp Zabel" , "Chun-Kuang Hu" , "Matthias Brugger" , "AngeloGioacchino Del Regno" , "Rob Clark" , "Dmitry Baryshkov" , "Abhinav Kumar" , "Jessica Zhang" , "Sean Paul" , "Marijn Suijten" , "Marek Vasut" , "Stefan Agner" , "Orson Zhai" , "Baolin Wang" , "Chunyan Zhang" , "Jyri Sarha" , "Tomi Valkeinen" , "Icenowy Zheng" , , , , , , , , To: "Arnd Bergmann" , "David Airlie" , "Simona Vetter" , "Luca Ceresoli" From: "Luca Ceresoli" X-Mailer: aerc 0.22.0 References: <20260928161605.2271412-1-arnd@kernel.org> In-Reply-To: <20260928161605.2271412-1-arnd@kernel.org> X-Last-TLS-Session-Version: TLSv1.3 Hello Arnd, On Mon Sep 28, 2026 at 6:04 PM CEST, Arnd Bergmann wrote: > From: Arnd Bergmann > > The devm_drm_of_get_bridge() declaration moved to drm_panel.h, but > not all callers include this, which leads to build failures in > some configurations: > > drivers/gpu/drm/imx/lcdc/imx-lcdc.c: In function 'imx_lcdc_probe': > drivers/gpu/drm/imx/lcdc/imx-lcdc.c:404:18: error: implicit declaration o= f function 'devm_drm_of_get_bridge' [-Wimplicit-function-declaration] > 404 | bridge =3D devm_drm_of_get_bridge(dev, dev->of_node, 0, 0= ); > | ^~~~~~~~~~~~~~~~~~~~~~ > drivers/gpu/drm/verisilicon/vs_bridge.c: In function 'vs_bridge_init': > drivers/gpu/drm/verisilicon/vs_bridge.c:306:16: error: implicit declarati= on of function 'devm_drm_of_get_bridge' [-Wimplicit-function-declaration] > 306 | next =3D devm_drm_of_get_bridge(drm_dev->dev, drm_dev->de= v->of_node, > | ^~~~~~~~~~~~~~~~~~~~~~ > > Include the new header in all files that need it. > > Fixes: aa8a8c7e4641 ("drm/bridge: panel: move all code to drm_panel.c") > Signed-off-by: Arnd Bergmann Thanks for the very quick reaction to this regression! However I think we should fix it differently. I had definitely build-tested most if not all these drivers, and also runtime tested a few. Now I realized the build failure actually happens only in !OF defconfigs which I haven't build-tested (sorry about that!). Here's why: * the affected drivers (all or most of them) include drm_of.h * drm_of.h does: #if IS_ENABLED(CONFIG_OF) && IS_ENABLED(CONFIG_DRM_PANEL_BRIDGE) #include #include #include #endif * DRM_PANEL_BRIDGE is always set when DRM is set, so not a problem * drivers which don't depend on OF and don't include drm_panel.h now fail Most of the drivers changed by this patch do 'depend on OF', so they are not affected. So the patch could be trimmed significantly. But still I'm not in favor of including drm_panel.h in the remaining drivers, because: * in the first place most/all of these drivers are now supposed to not use the drm_panel API anymore; thsy should just use the drm_bridge API * devm_drm_of_get_bridge() is now a deprecated [0], complicated way of calling of_drm_get_bridge_by_endpoint(), which is rightfully in drm_bridge.h * for this reason Documentation/drm/todo.rst says it must be removed [1] * removal is easy, so I plan to do it in a few weeks globally * after the removal all these #include would have to be removed, but some might easily be forgotten So I see two option for a better fix: * Option 1 -- fix the really affected drivers by switching from the deprecated API to the one they recommended one. Based on quick analysis there are about 6. * Option 2 -- a quick surgical fix: In drm_of.h: #if IS_ENABLED(CONFIG_OF) && IS_ENABLED(CONFIG_DRM_PANEL_BRIDGE) #include #include -#include #endif +#include /* Temporary for *_of_get_bridge() */ This can easily be tracked and reverted once all devm_drm_of_get_bridge() users are converted to of_drm_get_bridge_by_endpoint(). I'm working right now on option 1, hoping to get a series in a few hours from now. I can switch to option 2 in case of unexpected issues with option 1, or if a fix "really right now" is wanted. [0] https://lore.kernel.org/lkml/20260916-drm-bridge-every-panel-v3-7-83afb= 4f1a707@bootlin.com/ [1] https://lore.kernel.org/lkml/20260916-drm-bridge-every-panel-v3-8-83afb= 4f1a707@bootlin.com/ Luca > --- > drivers/gpu/drm/adp/adp_drv.c | 1 + > drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_output.c | 1 + > drivers/gpu/drm/bridge/chipone-icn6211.c | 1 + > drivers/gpu/drm/bridge/imx/imx-ldb-helper.c | 1 + > drivers/gpu/drm/bridge/ite-it6263.c | 1 + > drivers/gpu/drm/bridge/microchip-lvds.c | 1 + > drivers/gpu/drm/bridge/nwl-dsi.c | 1 + > drivers/gpu/drm/bridge/nxp-ptn3460.c | 1 + > drivers/gpu/drm/bridge/parade-ps8622.c | 1 + > drivers/gpu/drm/bridge/parade-ps8640.c | 1 + > drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 1 + > drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi2.c | 1 + > drivers/gpu/drm/bridge/tc358762.c | 1 + > drivers/gpu/drm/bridge/tc358764.c | 1 + > drivers/gpu/drm/bridge/tc358775.c | 1 + > drivers/gpu/drm/bridge/ti-dlpc3433.c | 1 + > drivers/gpu/drm/bridge/ti-sn65dsi83.c | 1 + > drivers/gpu/drm/bridge/ti-sn65dsi86.c | 1 + > drivers/gpu/drm/drm_bridge.c | 1 + > drivers/gpu/drm/imx/ipuv3/imx-ldb.c | 1 + > drivers/gpu/drm/imx/ipuv3/parallel-display.c | 1 + > drivers/gpu/drm/imx/lcdc/imx-lcdc.c | 1 + > drivers/gpu/drm/mediatek/mtk_dpi.c | 1 + > drivers/gpu/drm/msm/disp/mdp4/mdp4_kms.c | 1 + > drivers/gpu/drm/mxsfb/lcdif_drv.c | 1 + > drivers/gpu/drm/sprd/sprd_dsi.c | 1 + > drivers/gpu/drm/tidss/tidss_oldi.c | 1 + > drivers/gpu/drm/tilcdc/tilcdc_encoder.c | 1 + > drivers/gpu/drm/verisilicon/vs_bridge.c | 1 + > 29 files changed, 29 insertions(+) > > diff --git a/drivers/gpu/drm/adp/adp_drv.c b/drivers/gpu/drm/adp/adp_drv.= c > index fdf0e6316175..eb67c6fe9c01 100644 > --- a/drivers/gpu/drm/adp/adp_drv.c > +++ b/drivers/gpu/drm/adp/adp_drv.c > @@ -16,6 +16,7 @@ > #include > #include > #include > +#include > #include > #include > #include > diff --git a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_output.c b/drivers/g= pu/drm/atmel-hlcdc/atmel_hlcdc_output.c > index e8aea905fb10..d16945ebb2f5 100644 > --- a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_output.c > +++ b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_output.c > @@ -15,6 +15,7 @@ > #include > #include > #include > +#include > #include > #include > > diff --git a/drivers/gpu/drm/bridge/chipone-icn6211.c b/drivers/gpu/drm/b= ridge/chipone-icn6211.c > index 4ec50fb63aba..fc4a49b2b246 100644 > --- a/drivers/gpu/drm/bridge/chipone-icn6211.c > +++ b/drivers/gpu/drm/bridge/chipone-icn6211.c > @@ -6,6 +6,7 @@ > > #include > #include > +#include > #include > #include > > diff --git a/drivers/gpu/drm/bridge/imx/imx-ldb-helper.c b/drivers/gpu/dr= m/bridge/imx/imx-ldb-helper.c > index 6149ba141a38..018fedb0162c 100644 > --- a/drivers/gpu/drm/bridge/imx/imx-ldb-helper.c > +++ b/drivers/gpu/drm/bridge/imx/imx-ldb-helper.c > @@ -13,6 +13,7 @@ > > #include > #include > +#include > #include > > #include "imx-ldb-helper.h" > diff --git a/drivers/gpu/drm/bridge/ite-it6263.c b/drivers/gpu/drm/bridge= /ite-it6263.c > index 21ac8e58b9d2..12a23bb45c84 100644 > --- a/drivers/gpu/drm/bridge/ite-it6263.c > +++ b/drivers/gpu/drm/bridge/ite-it6263.c > @@ -26,6 +26,7 @@ > #include > #include > #include > +#include > #include > > /* ---------------------------------------------------------------------= -------- > diff --git a/drivers/gpu/drm/bridge/microchip-lvds.c b/drivers/gpu/drm/br= idge/microchip-lvds.c > index dd4ffc9f4df3..53291cde0636 100644 > --- a/drivers/gpu/drm/bridge/microchip-lvds.c > +++ b/drivers/gpu/drm/bridge/microchip-lvds.c > @@ -24,6 +24,7 @@ > #include > #include > #include > +#include > #include > #include > #include > diff --git a/drivers/gpu/drm/bridge/nwl-dsi.c b/drivers/gpu/drm/bridge/nw= l-dsi.c > index 09992529f3d8..f7043dcd76cb 100644 > --- a/drivers/gpu/drm/bridge/nwl-dsi.c > +++ b/drivers/gpu/drm/bridge/nwl-dsi.c > @@ -27,6 +27,7 @@ > #include > #include > #include > +#include > #include > > #include