projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1fdbf66
)
drm/bridge: lt8912b: Register and attach our DSI device at probe
author
Maxime Ripard
<maxime@cerno.tech>
Mon, 25 Oct 2021 15:15:21 +0000
(17:15 +0200)
committer
Maxime Ripard
<maxime@cerno.tech>
Wed, 27 Oct 2021 20:07:56 +0000
(22:07 +0200)
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. Let's do this.
Acked-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Link:
https://patchwork.freedesktop.org/patch/msgid/20211025151536.1048186-7-maxime@cerno.tech
drivers/gpu/drm/bridge/lontium-lt8912b.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/bridge/lontium-lt8912b.c
b/drivers/gpu/drm/bridge/lontium-lt8912b.c
index cc968d65936bedf560a3add1d4e63090104f98be..c642d1e02b2f8b43131bab76e09315e78bb79fd9 100644
(file)
--- a/
drivers/gpu/drm/bridge/lontium-lt8912b.c
+++ b/
drivers/gpu/drm/bridge/lontium-lt8912b.c
@@
-544,10
+544,6
@@
static int lt8912_bridge_attach(struct drm_bridge *bridge,
if (ret)
goto error;
- ret = lt8912_attach_dsi(lt);
- if (ret)
- goto error;
-
lt->is_attached = true;
return 0;
@@
-706,8
+702,15
@@
static int lt8912_probe(struct i2c_client *client,
drm_bridge_add(<->bridge);
+ ret = lt8912_attach_dsi(lt);
+ if (ret)
+ goto err_attach;
+
return 0;
+err_attach:
+ drm_bridge_remove(<->bridge);
+ lt8912_free_i2c(lt);
err_i2c:
lt8912_put_dt(lt);
err_dt_parse: