mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH] video: tc358767: register aux i2c bus after validating link
@ 2018-03-05 14:19 Andrey Gusakov
  2018-03-12 10:29 ` Sascha Hauer
  0 siblings, 1 reply; 2+ messages in thread
From: Andrey Gusakov @ 2018-03-05 14:19 UTC (permalink / raw)
  To: barebox; +Cc: andrey.gusakov

Register AUX i2c adapter only if AUX link is functional. This
should avoid possible hung during tc358767 probe when no display
connected.

Signed-off-by: Andrey Gusakov <andrey.gusakov@cogentembedded.com>
---
 drivers/video/tc358767.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/video/tc358767.c b/drivers/video/tc358767.c
index f9ca06c..5ad5cb4 100644
--- a/drivers/video/tc358767.c
+++ b/drivers/video/tc358767.c
@@ -1404,6 +1404,10 @@ static int tc_probe(struct device_d *dev)
 	if (ret)
 		goto err;
 
+	ret = tc_get_display_props(tc);
+	if (ret)
+		goto err;
+
 	/* Register DP AUX channel */
 	tc->adapter.master_xfer = tc_aux_i2c_xfer;
 	tc->adapter.nr = -1; /* any free */
@@ -1416,10 +1420,6 @@ static int tc_probe(struct device_d *dev)
 		goto err;
 	}
 
-	ret = tc_get_display_props(tc);
-	if (ret)
-		goto err;
-
 	/* add vlp */
 	tc->vpl.node = dev->device_node;
 	tc->vpl.ioctl = tc_ioctl;
-- 
1.9.1


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-03-12 10:30 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-05 14:19 [PATCH] video: tc358767: register aux i2c bus after validating link Andrey Gusakov
2018-03-12 10:29 ` Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox