Revert "drm/bridge: dw-mipi-dsi: Find the possible DSI devices"
Subsystems (6)
PATCH v2 1/8 Revert "drm/bridge: dw-mipi-dsi: Find the possible DSI devices"
This reverts commit c206c7faeb3263a7cc7b4de443a3877cd7a5e74b.
In order to avoid any probe ordering issues, the I2C based downstream bridge drivers now register and attach the DSI devices at the probe instead of doing it on drm_bridge_function.attach().
Examples of those commits are:
commit <6ef7ee48765f> ("drm/bridge: sn65dsi83: Register and attach our DSI device at probe")
commit <d89078c37b10> ("drm/bridge: lt8912b: Register and attach our DSI device at probe")
commit <864c49a31d6b> ("drm/bridge: adv7511: Register and attach our DSI device at probe")
dw-mipi-dsi has panel or bridge finding code based on previous downstream bridges, so revert the same and make the panel or bridge funding in host attach as before.
---
Changes for v2:
- none
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 58 +++++-------------- 1 file changed, 15 insertions(+), 43 deletions(-)
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c +15 -43
@@ -246,7 +246,6 @@ struct dw_mipi_dsi {struct clk *pclk; -bool device_found;unsigned int lane_mbps;/* per lane */ u32 channel;u32 lanes;
@@ -310,37 +309,13 @@ static inline u32 dsi_read(struct dw_mipi_dsi *dsi, u32 reg)return readl (dsi->base + reg); } -static int dw_mipi_dsi_panel_or_bridge (struct dw_mipi_dsi *dsi, -struct device_node *node) -{ -struct drm_bridge *bridge; -struct drm_panel *panel; -int ret; - - ret =drm_of_find_panel_or_bridge (node,1 ,0 , &panel, &bridge); -if (ret) -return ret; - -if (panel) { - bridge =drm_panel_bridge_add_typed (panel, -DRM_MODE_CONNECTOR_DSI ); -if (IS_ERR (bridge)) -return PTR_ERR (bridge); - } - - dsi->panel_bridge = bridge; - -if (!dsi->panel_bridge) -return -EPROBE_DEFER ; - -return 0 ; -} -static int dw_mipi_dsi_host_attach (struct mipi_dsi_host *host,struct mipi_dsi_device *device) {struct dw_mipi_dsi *dsi =host_to_dsi (host);const struct dw_mipi_dsi_plat_data *pdata = dsi->plat_data; +struct drm_bridge *bridge; +struct drm_panel *panel;int ret;if (device->lanes > dsi->plat_data->max_data_lanes) {
@@ -354,14 +329,22 @@ static int dw_mipi_dsi_host_attach(struct mipi_dsi_host *host, dsi->format = device->format; dsi->mode_flags = device->mode_flags; -if (!dsi->device_found) { - ret =dw_mipi_dsi_panel_or_bridge (dsi, host->dev->of_node); -if (ret) -return ret; + ret =drm_of_find_panel_or_bridge (host->dev->of_node,1 ,0 , + &panel, &bridge); +if (ret) +return ret; - dsi->device_found = true; +if (panel) { + bridge =drm_panel_bridge_add_typed (panel, +DRM_MODE_CONNECTOR_DSI ); +if (IS_ERR (bridge)) +return PTR_ERR (bridge); } + dsi->panel_bridge = bridge; + +drm_bridge_add (&dsi->bridge); +if (pdata->host_ops && pdata->host_ops->attach) { ret = pdata->host_ops->attach (pdata->priv_data, device);if (ret <0 )
@@ -1021,16 +1004,6 @@ static int dw_mipi_dsi_bridge_attach(struct drm_bridge *bridge,/* Set the encoder type as caller does not know it */ bridge->encoder->encoder_type =DRM_MODE_ENCODER_DSI ; -if (!dsi->device_found) { -int ret; - - ret =dw_mipi_dsi_panel_or_bridge (dsi, dsi->dev->of_node); -if (ret) -return ret; - - dsi->device_found = true; - } -/* Attach the panel-bridge to the dsi bridge */ return drm_bridge_attach (bridge->encoder, dsi->panel_bridge, bridge, flags);
@@ -1217,7 +1190,6 @@ __dw_mipi_dsi_probe(struct platform_device *pdev,#ifdef CONFIG_OF dsi->bridge.of_node = pdev->dev.of_node;#endif -drm_bridge_add (&dsi->bridge);return dsi; }
Signature · 1 line
2.25.1
PATCH v2 2/8 drm: bridge: nwl-dsi: Switch to devm_drm_of_get_bridge
devm_drm_of_get_bridge is capable of looking up the downstream bridge and panel and trying to add a panel bridge if the panel is found.
Replace explicit finding calls with devm_drm_of_get_bridge.
---
Changes for v2:
- split the patch
drivers/gpu/drm/bridge/nwl-dsi.c | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-)
drivers/gpu/drm/bridge/nwl-dsi.c +3 -15
@@ -916,22 +916,10 @@ static int nwl_dsi_bridge_attach(struct drm_bridge *bridge, {struct nwl_dsi *dsi =bridge_to_dsi (bridge);struct drm_bridge *panel_bridge; -struct drm_panel *panel; -int ret; - - ret =drm_of_find_panel_or_bridge (dsi->dev->of_node,1 ,0 , &panel, - &panel_bridge); -if (ret) -return ret; - -if (panel) { - panel_bridge =drm_panel_bridge_add (panel); -if (IS_ERR (panel_bridge)) -return PTR_ERR (panel_bridge); - } -if (!panel_bridge) -return -EPROBE_DEFER ; + panel_bridge =devm_drm_of_get_bridge (dsi->dev, dsi->dev->of_node,1 ,0 ); +if (IS_ERR (panel_bridge)) +return PTR_ERR (panel_bridge);return drm_bridge_attach (bridge->encoder, panel_bridge, bridge, flags); }
Signature · 1 line
2.25.1
Re: [PATCH v2 2/8] drm: bridge: nwl-dsi: Switch to devm_drm_of_get_bridge
Hi,
Quoted 35 lines · Jagan Teki
devm_drm_of_get_bridgeis capable of looking up the downstream bridge and panel and trying to add a panel bridge if the panel is found.Replace explicit finding calls with
devm_drm_of_get_bridge.Cc Guido Günther <[email protected]>Signed-off-by Jagan Teki <[email protected]>---
Changes for v2:
- split the patchdrivers/gpu/drm/bridge/nwl-dsi.c | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-)drivers/gpu/drm/bridge/nwl-dsi.c +0
-12@@ -916,22 +916,10 @@ static int nwl_dsi_bridge_attach(struct drm_bridge *bridge, {struct nwl_dsi *dsi =bridge_to_dsi (bridge);struct drm_bridge *panel_bridge; -struct drm_panel *panel; -int ret; - - ret =drm_of_find_panel_or_bridge (dsi->dev->of_node,1 ,0 , &panel, - &panel_bridge); -if (ret) -return ret; - -if (panel) { - panel_bridge =drm_panel_bridge_add (panel); -if (IS_ERR (panel_bridge)) -return PTR_ERR (panel_bridge);
drivers/gpu/drm/bridge/nwl-dsi.c static int nwl_dsi_bridge_attach(struct drm_bridge *bridge, · line 925
Quoted 10 lines
drivers/gpu/drm/bridge/nwl-dsi.c +3
-3- } -if (!panel_bridge) -return -EPROBE_DEFER ; + panel_bridge =devm_drm_of_get_bridge (dsi->dev, dsi->dev->of_node,1 ,0 ); +if (IS_ERR (panel_bridge)) +return PTR_ERR (panel_bridge);return drm_bridge_attach (bridge->encoder, panel_bridge, bridge, flags); }
Thanks,
-- Guido
Quoted 3 lines
Signature · 1 line
2.25.1
PATCH v2 3/8 drm: mediatek: mtk_dsi: Switch to devm_drm_of_get_bridge
In reply to Jagan Tekidevm_drm_of_get_bridge is capable of looking up the downstream bridge and panel and trying to add a panel bridge if the panel is found.
Replace explicit finding calls with devm_drm_of_get_bridge.
---
Changes for v2:
- split the patch
drivers/gpu/drm/mediatek/mtk_dsi.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-)
drivers/gpu/drm/mediatek/mtk_dsi.c +3 -11
@@ -1004,7 +1004,6 @@ static int mtk_dsi_probe(struct platform_device *pdev) {struct mtk_dsi *dsi;struct device *dev = &pdev->dev; -struct drm_panel *panel;struct resource *regs;int irq_num;int ret;
@@ -1021,17 +1020,10 @@ static int mtk_dsi_probe(struct platform_device *pdev)return ret; } - ret =drm_of_find_panel_or_bridge (dev->of_node,0 ,0 , - &panel, &dsi->next_bridge); -if (ret) + dsi->next_bridge =devm_drm_of_get_bridge (dev, dev->of_node,0 ,0 ); +if (IS_ERR (dsi->next_bridge)) { + ret =PTR_ERR (dsi->next_bridge); goto err_unregister_host; - -if (panel) { - dsi->next_bridge =devm_drm_panel_bridge_add (dev, panel); -if (IS_ERR (dsi->next_bridge)) { - ret =PTR_ERR (dsi->next_bridge); - goto err_unregister_host; - } } dsi->driver_data =of_device_get_match_data (dev);
Signature · 1 line
2.25.1
PATCH v2 4/8 drm: bridge: dw-mipi-dsi: Switch to devm_drm_of_get_bridge
In reply to Jagan Tekidevm_drm_of_get_bridge is capable of looking up the downstream bridge and panel and trying to add a panel bridge if the panel is found.
Replace explicit finding calls with devm_drm_of_get_bridge.
---
Changes for v2:
- split the patch
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-)
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c +3 -12
@@ -315,7 +315,6 @@ static int dw_mipi_dsi_host_attach(struct mipi_dsi_host *host,struct dw_mipi_dsi *dsi =host_to_dsi (host);const struct dw_mipi_dsi_plat_data *pdata = dsi->plat_data;struct drm_bridge *bridge; -struct drm_panel *panel;int ret;if (device->lanes > dsi->plat_data->max_data_lanes) {
@@ -329,17 +328,9 @@ static int dw_mipi_dsi_host_attach(struct mipi_dsi_host *host, dsi->format = device->format; dsi->mode_flags = device->mode_flags; - ret =drm_of_find_panel_or_bridge (host->dev->of_node,1 ,0 , - &panel, &bridge); -if (ret) -return ret; - -if (panel) { - bridge =drm_panel_bridge_add_typed (panel, -DRM_MODE_CONNECTOR_DSI ); -if (IS_ERR (bridge)) -return PTR_ERR (bridge); - } + bridge =devm_drm_of_get_bridge (dsi->dev, dsi->dev->of_node,1 ,0 ); +if (IS_ERR (bridge)) +return PTR_ERR (bridge); dsi->panel_bridge = bridge;
Signature · 1 line
2.25.1
PATCH v2 5/8 drm: bridge: nxp-ptn3460: Switch to devm_drm_of_get_bridge
In reply to Jagan Tekidevm_drm_of_get_bridge is capable of looking up the downstream bridge and panel and trying to add a panel bridge if the panel is found.
Replace explicit finding calls with devm_drm_of_get_bridge.
---
Changes for v2:
- split the patch
drivers/gpu/drm/bridge/nxp-ptn3460.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-)
drivers/gpu/drm/bridge/nxp-ptn3460.c +1 -6
@@ -263,7 +263,6 @@ static int ptn3460_probe(struct i2c_client *client,struct device *dev = &client->dev;struct ptn3460_bridge *ptn_bridge;struct drm_bridge *panel_bridge; -struct drm_panel *panel;int ret; ptn_bridge =devm_kzalloc (dev,sizeof (*ptn_bridge),GFP_KERNEL );
@@ -271,11 +270,7 @@ static int ptn3460_probe(struct i2c_client *client,return -ENOMEM ; } - ret =drm_of_find_panel_or_bridge (dev->of_node,0 ,0 , &panel,NULL ); -if (ret) -return ret; - - panel_bridge =devm_drm_panel_bridge_add (dev, panel); + panel_bridge =devm_drm_of_get_bridge (dev, dev->of_node,0 ,0 );if (IS_ERR (panel_bridge))return PTR_ERR (panel_bridge);
Signature · 1 line
2.25.1
PATCH v2 6/8 drm: bridge: parade-ps8622: Switch to devm_drm_of_get_bridge
In reply to Jagan Tekidevm_drm_of_get_bridge is capable of looking up the downstream bridge and panel and trying to add a panel bridge if the panel is found.
Replace explicit finding calls with devm_drm_of_get_bridge.
---
Changes for v2:
- split the patch
drivers/gpu/drm/bridge/parade-ps8622.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-)
drivers/gpu/drm/bridge/parade-ps8622.c +1 -6
@@ -452,18 +452,13 @@ static int ps8622_probe(struct i2c_client *client,struct device *dev = &client->dev;struct ps8622_bridge *ps8622;struct drm_bridge *panel_bridge; -struct drm_panel *panel;int ret; ps8622 =devm_kzalloc (dev,sizeof (*ps8622),GFP_KERNEL );if (!ps8622)return -ENOMEM ; - ret =drm_of_find_panel_or_bridge (dev->of_node,0 ,0 , &panel,NULL ); -if (ret) -return ret; - - panel_bridge =devm_drm_panel_bridge_add (dev, panel); + panel_bridge =devm_drm_of_get_bridge (dev, dev->of_node,0 ,0 );if (IS_ERR (panel_bridge))return PTR_ERR (panel_bridge);
Signature · 1 line
2.25.1
PATCH v2 7/8 drm: bridge: anx7625: Switch to devm_drm_of_get_bridge
In reply to Jagan Tekidevm_drm_of_get_bridge is capable of looking up the downstream bridge and panel and trying to add a panel bridge if the panel is found.
Replace explicit finding calls with devm_drm_of_get_bridge.
---
Changes for v2:
- split the patch
drivers/gpu/drm/bridge/analogix/anx7625.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-)
drivers/gpu/drm/bridge/analogix/anx7625.c +1 -12
@@ -1606,8 +1606,6 @@ static int anx7625_parse_dt(struct device *dev, struct anx7625_platform_data *pdata) {struct device_node *np = dev->of_node, *ep0; -struct drm_panel *panel; -int ret;int bus_type, mipi_lanes;anx7625_get_swing_setting (dev, pdata);
@@ -1644,16 +1642,7 @@ static int anx7625_parse_dt(struct device *dev,if (of_property_read_bool (np,"analogix,audio-enable" )) pdata->audio_en =1 ; - ret =drm_of_find_panel_or_bridge (np,1 ,0 , &panel,NULL ); -if (ret <0 ) { -if (ret == -ENODEV ) -return 0 ; -return ret; - } -if (!panel) -return -ENODEV ; - - pdata->panel_bridge =devm_drm_panel_bridge_add (dev, panel); + pdata->panel_bridge =devm_drm_of_get_bridge (dev, dev->of_node,1 ,0 );if (IS_ERR (pdata->panel_bridge))return PTR_ERR (pdata->panel_bridge);DRM_DEV_DEBUG_DRIVER (dev,"get panel node.\n" );
Signature · 1 line
2.25.1
PATCH v2 8/8 drm: bridge: anx7625: Switch to devm_drm_of_get_bridge
In reply to Jagan Tekidevm_drm_of_get_bridge is capable of looking up the downstream bridge and panel and trying to add a panel bridge if the panel is found.
Replace explicit finding calls with devm_drm_of_get_bridge.
---
Changes for v2:
- split the patch
drivers/gpu/drm/mcde/mcde_dsi.c | 39 +++++---------------------------- 1 file changed, 5 insertions(+), 34 deletions(-)
drivers/gpu/drm/mcde/mcde_dsi.c +5 -34
@@ -1073,9 +1073,7 @@ static int mcde_dsi_bind(struct device *dev, struct device *master,struct drm_device *drm = data;struct mcde *mcde =to_mcde (drm);struct mcde_dsi *d =dev_get_drvdata (dev); -struct device_node *child; -struct drm_panel *panel =NULL ; -struct drm_bridge *bridge =NULL ; +struct drm_bridge *bridge;if (!of_get_available_child_count (dev->of_node)) {dev_info (dev,"unused DSI interface\n" );
@@ -1100,37 +1098,10 @@ static int mcde_dsi_bind(struct device *dev, struct device *master,return PTR_ERR (d->lp_clk); } -/* Look for a panel as a child to this node */ -for_each_available_child_of_node (dev->of_node, child) { - panel =of_drm_find_panel (child); -if (IS_ERR (panel)) { -dev_err (dev,"failed to find panel try bridge (%ld)\n" , -PTR_ERR (panel)); - panel =NULL ; - - bridge =of_drm_find_bridge (child); -if (!bridge) { -dev_err (dev,"failed to find bridge\n" ); -return -EINVAL ; - } - } - } -if (panel) { - bridge =drm_panel_bridge_add_typed (panel, -DRM_MODE_CONNECTOR_DSI ); -if (IS_ERR (bridge)) { -dev_err (dev,"error adding panel bridge\n" ); -return PTR_ERR (bridge); - } -dev_info (dev,"connected to panel\n" ); - d->panel = panel; - }else if (bridge) { -/* TODO: AV8100 HDMI encoder goes here for example */ -dev_info (dev,"connected to non-panel bridge (unsupported)\n" ); -return -ENODEV ; - }else { -dev_err (dev,"no panel or bridge\n" ); -return -ENODEV ; + bridge =devm_drm_of_get_bridge (dev, dev->of_node,0 ,0 ); +if (IS_ERR (bridge)) { +dev_err (dev,"error to get bridge\n" ); +return PTR_ERR (bridge); } d->bridge_out = bridge;
Signature · 1 line
2.25.1
Re: [PATCH v2 8/8] drm: bridge: anx7625: Switch to devm_drm_of_get_bridge
Quoted 11 lines · Jagan Teki
devm_drm_of_get_bridgeis capable of looking up the downstream bridge and panel and trying to add a panel bridge if the panel is found.Replace explicit finding calls with
devm_drm_of_get_bridge.Cc Linus Walleij <[email protected]>Signed-off-by Jagan Teki <[email protected]>---
Changes for v2:
- split the patch
This will be nice code reduction when it works!
drivers/gpu/drm/mcde/mcde_dsi.c static int mcde_dsi_bind(struct device *dev, struct device *master, · line 1076
Quoted 3 lines
drivers/gpu/drm/mcde/mcde_dsi.c +1
-2-struct drm_panel *panel =NULL ; -struct drm_bridge *bridge =NULL ; +struct drm_bridge *bridge;
OK... and then you delete the code that uses panel. But:
static void mcde_dsi_unbind(struct device *dev, struct device *master,
void *data)
{
struct mcde_dsi *d = dev_get_drvdata(dev);
if (d->panel)
drm_panel_bridge_remove(d->bridge_out);
regmap_update_bits(d->prcmu, PRCM_DSI_SW_RESET,
PRCM_DSI_SW_RESET_DSI0_SW_RESETN, 0);
}So this will not even compile.
I suppose you have a solution for removing the panel bridge automatically as well?
Yours,
Linus Walleij
Re: [PATCH v2 8/8] drm: bridge: anx7625: Switch to devm_drm_of_get_bridge
Quoted 23 lines · Linus Walleij
Quoted 11 lines · Jagan Teki
devm_drm_of_get_bridgeis capable of looking up the downstream bridge and panel and trying to add a panel bridge if the panel is found.Replace explicit finding calls with
devm_drm_of_get_bridge.Cc Linus Walleij <[email protected]>Signed-off-by Jagan Teki <[email protected]>---
Changes for v2:
- split the patchThis will be nice code reduction when it works!
drivers/gpu/drm/mcde/mcde_dsi.c static int mcde_dsi_bind(struct device *dev, struct device *master, · line 1076
Quoted 3 lines
drivers/gpu/drm/mcde/mcde_dsi.c +1
-2-struct drm_panel *panel =NULL ; -struct drm_bridge *bridge =NULL ; +struct drm_bridge *bridge;OK... and then you delete the code that uses panel. But:
Quoted 7 lines
static void mcde_dsi_unbind(struct device *dev, struct device *master,
void *data){ struct mcde_dsi *d = dev_get_drvdata(dev); if (d->panel) drm_panel_bridge_remove(d->bridge_out);
I think using drm_bridge_remove(d->bridge_out); will directly remove the bridge whether it is the next bridge or panel bridge as bridge_out is already found the relevant downstream.
Jagan.
Re: [PATCH v2 8/8] drm: bridge: anx7625: Switch to devm_drm_of_get_bridge
In reply to Jagan Tekidrivers/gpu/drm/mcde/mcde_dsi.c static int mcde_dsi_bind(struct device *dev, struct device *master, · line 1107
Quoted 7 lines · Jagan Teki
drivers/gpu/drm/mcde/mcde_dsi.c +4
-0+ bridge =devm_drm_of_get_bridge (dev, dev->of_node,0 ,0 ); +if (IS_ERR (bridge)) { +dev_err (dev,"error to get bridge\n" ); +return PTR_ERR (bridge); } d->bridge_out = bridge;
Also notice how this bridge gets used in other places:
struct drm_connector *connector = drm_panel_bridge_connector(mcde->bridge);
Since you deleted:
- } else if (bridge) {
- /* TODO: AV8100 HDMI encoder goes here for example */ - dev_info(dev, "connected to non-panel bridge (unsupported)\n"); - return -ENODEV;
This will now have "interesting" effects. I think.
I don't know if there is a way to solve this though?
Yours,
Linus Walleij
Re: [PATCH v2 8/8] drm: bridge: anx7625: Switch to devm_drm_of_get_bridge
Quoted 9 lines · Linus Walleij
Quoted 6 lines · Jagan Teki
drivers/gpu/drm/mcde/mcde_dsi.c +4
-0+ bridge =devm_drm_of_get_bridge (dev, dev->of_node,0 ,0 ); +if (IS_ERR (bridge)) { +dev_err (dev,"error to get bridge\n" ); +return PTR_ERR (bridge); }
Quoted 5 lines
Quoted 1 line
d->bridge_out = bridge;Also notice how this bridge gets used in other places:
struct
drm_connector*connector =drm_panel_bridge_connector(mcde->bridge);
mcde->bridge bridge is the current bridge pointer it cannot affect this change. d->bridge_out is what we are finding of the downstream bridge.
drivers/gpu/drm/mcde/mcde_dsi.c static int mcde_dsi_bind(struct device *dev, struct device *master, · line 1130
Quoted 7 lines
Since you deleted:
drivers/gpu/drm/mcde/mcde_dsi.c +0
-4- }else if (bridge) { -/* TODO: AV8100 HDMI encoder goes here for example */ -dev_info (dev,"connected to non-panel bridge (unsupported)\n" ); -return -ENODEV ;
So, this means mcde dsi can support if the downstream bridge is the panel not if the downstream bridge is the next bridge. With devm_drm_of_get_bridge we cannot find that diff. Identifying the panel-bridge with some name pointer during panel_bridge_add might solve this, not sure that is proper way to do that?
Thanks,
Jagan.
Re: [PATCH v2 8/8] drm: bridge: anx7625: Switch to devm_drm_of_get_bridge
Quoted 12 lines · Jagan Teki
Quoted 11 lines · Linus Walleij
Quoted 7 lines · Jagan Teki
drivers/gpu/drm/mcde/mcde_dsi.c +4
-0+ bridge =devm_drm_of_get_bridge (dev, dev->of_node,0 ,0 ); +if (IS_ERR (bridge)) { +dev_err (dev,"error to get bridge\n" ); +return PTR_ERR (bridge); } d->bridge_out = bridge;
Quoted 7 lines
Quoted 3 lines
Also notice how this bridge gets used in other places:
struct
drm_connector*connector =drm_panel_bridge_connector(mcde->bridge);
mcde->bridgebridge is the current bridge pointer it cannot affect this change.d->bridge_outis what we are finding of the downstream bridge.
Sorry I confused things.
Got lost in my own code :/
The bridge in the other file is for DPI obviously... I should rename it dpi_panel_bridge.
Quoted 7 lines
drivers/gpu/drm/mcde/mcde_dsi.c static int mcde_dsi_bind(struct device *dev, struct device *master, · line 1130
Quoted 6 lines
Since you deleted:
drivers/gpu/drm/mcde/mcde_dsi.c +0
-4- }else if (bridge) { -/* TODO: AV8100 HDMI encoder goes here for example */ -dev_info (dev,"connected to non-panel bridge (unsupported)\n" ); -return -ENODEV ;
Quoted 5 lines
So, this means mcde dsi can support if the downstream bridge is the panel not if the downstream bridge is the next bridge. With
devm_drm_of_get_bridgewe cannot find that diff. Identifying the panel-bridge with some name pointer duringpanel_bridge_addmight solve this, not sure that is proper way to do that?
I'd say leave it, as the DSI bridge (bridge_out) doesn't really care about this being a panel or not. A further bridge down the chain should "just work" (famous last words).
Just make sure we properly remove bridge_out in unbind call.
Yours,
Linus Walleij