Skip to content

Commit

Permalink
motmdm: HACK: wait before opening next tty device
Browse files Browse the repository at this point in the history
It seems that modem is not fast enough to respond in time if multiple
channel open requests are done in parallel. This result in only DLC 1 being
functional if ofono is restarted.

Fix that by delaying each consecutive open

Signed-off-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com>
  • Loading branch information
freemangordon committed Aug 30, 2022
1 parent 33595ef commit f731edb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions plugins/motmdm.c
Expand Up @@ -401,6 +401,11 @@ static int motmdm_open_dlc_devices(struct ofono_modem *modem)
break;
}

/* If we open in a row, all channels but 1 time out on SABM(P)
* request, effectively remaining closed. Give modem a chance to
* catch up.
*/
sleep(1);
found++;
}

Expand Down

0 comments on commit f731edb

Please sign in to comment.