MLK-21168 imx: Set timeout of virtual driver service connection to 2s
authorYe Li <ye.li@nxp.com>
Mon, 18 Mar 2019 08:35:19 +0000 (01:35 -0700)
committerYe Li <ye.li@nxp.com>
Fri, 24 May 2019 11:28:20 +0000 (04:28 -0700)
The normal ready time of M4 side is less than 1s, so we can use
2s as the timeout of connection.  The current value is 10s, which seems
a little long if M4 SRTM service does not run.

Signed-off-by: Ye Li <ye.li@nxp.com>
Acked-by: Peng Fan <peng.fan@nxp.com>
(cherry picked from commit 4792d8967d3c631d055c133303bb6385b822a3ca)

arch/arm/mach-imx/imx_vservice.c

index 9a190e5..33f2486 100644 (file)
@@ -66,7 +66,7 @@ static int imx_vservice_connect(struct imx_vservice_channel *node)
        int ret = 0;
        union imx_m4_msg msg;
 
-       unsigned long timeout = timer_get_us() + 10000000; /* 10s timeout */
+       unsigned long timeout = timer_get_us() + 2000000; /* 2s timeout */
 
        for (;;) {
                msg.format.seq = 0;