diff options
author | Holger Hans Peter Freyther <holger@moiji-mobile.com> | 2017-11-15 12:25:47 +0100 |
---|---|---|
committer | Holger Hans Peter Freyther <holger@moiji-mobile.com> | 2017-11-27 17:54:03 +0800 |
commit | eddf339871559f282fe615f9c618a1220bd97743 (patch) | |
tree | b8fd59a2eb1b45cde02c6cb34ae26f7d89e07e56 /src/host/layer23/src/mobile/gsm480_ss.c | |
parent | 65774d447d8623257e1cbf3694542f4a421017d7 (diff) |
mobile: Instead of putting semantic in a comment, use an enum
The enum was created to understand the different states during
the shutdown and find places where it is used. The normal
transitions are like.
Idle -> Imsi Detach -> L1 Reset -> Done
Idle -> L1 Reset -> Done
The shutdown can get stuck in case:
* Out of memory situation while handling IMSI detach (timeout)
* Never receiving l1 reset acknnowledgment.
The code could benefit from the move to osmo fsm to deal with
proper timeouts.
Change-Id: Iee1140e4848923c7270495c381bf87b7e3fddee1
Diffstat (limited to 'src/host/layer23/src/mobile/gsm480_ss.c')
-rw-r--r-- | src/host/layer23/src/mobile/gsm480_ss.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/host/layer23/src/mobile/gsm480_ss.c b/src/host/layer23/src/mobile/gsm480_ss.c index ff90faaf..ee2c9439 100644 --- a/src/host/layer23/src/mobile/gsm480_ss.c +++ b/src/host/layer23/src/mobile/gsm480_ss.c @@ -603,7 +603,7 @@ int ss_send(struct osmocom_ms *ms, const char *code, int new_trans) } /* no running, no transaction */ - if (!ms->started || ms->shutdown) { + if (!ms->started || ms->shutdown != MS_SHUTDOWN_NONE) { gsm480_ss_result(ms, "<phone is down>", 0); return -EIO; } |