Now there is an equivalent of this dev_err in mipi_dsi_attach(), valid for
all DSI hosts.

This avoids the need to access the @name field in struct mipi_dsi_device.

Signed-off-by: Luca Ceresoli <[email protected]>
---
 drivers/gpu/drm/bridge/cadence/cdns-dsi-core.c | 9 ++-------
 1 file changed, 2 insertions(+), 7 deletions(-)

diff --git a/drivers/gpu/drm/bridge/cadence/cdns-dsi-core.c 
b/drivers/gpu/drm/bridge/cadence/cdns-dsi-core.c
index 
a57ca8c3bdaea9d4d15dd23af221c111b7319ac4..005aa6121227b2f7ac682f3b724e4518e8e5f721
 100644
--- a/drivers/gpu/drm/bridge/cadence/cdns-dsi-core.c
+++ b/drivers/gpu/drm/bridge/cadence/cdns-dsi-core.c
@@ -1072,7 +1072,6 @@ static int cdns_dsi_attach(struct mipi_dsi_host *host,
        struct cdns_dsi_output *output = &dsi->output;
        struct cdns_dsi_input *input = &dsi->input;
        struct drm_bridge *bridge;
-       int ret;
 
        /*
         * We currently do not support connecting several DSI devices to the
@@ -1093,12 +1092,8 @@ static int cdns_dsi_attach(struct mipi_dsi_host *host,
         */
        bridge = devm_drm_of_get_bridge(dsi->base.dev, dsi->base.dev->of_node,
                                        DSI_OUTPUT_PORT, dev->channel);
-       if (IS_ERR(bridge)) {
-               ret = PTR_ERR(bridge);
-               dev_err(host->dev, "failed to add DSI device %s (err = %d)",
-                       dev->name, ret);
-               return ret;
-       }
+       if (IS_ERR(bridge))
+               return PTR_ERR(bridge);
 
        output->dev = dev;
        output->bridge = bridge;

-- 
2.49.0

Reply via email to