blob: c9cdfebca8086c17694f74bdbcd87f0f3217452f [file] [log] [blame]
Harald Welted26d3d92009-08-10 11:35:33 +02001
2GSM 04.08 7.1.7 / 9.1.7 RR CHANNEL RELESE
3
4RSL 08.58 3.4 / ? RLL Link Release Request
5
6RSL 08.58 4.6 / 8.4.5 DEACTivate SACCH
7 * Deactivate SACCH according to Channel Release Proc 04.08
8 * to be sent after RR CHANNEL RELEASE is sent to MS
9
10RSL 08.58 4.7 / 8.4.14 RF CHANnel RELease
11 * tells the BTS to release a radio channel
12 * "when an activated radio channel is no longer needed"
13 * BTS responds with RF CHANnel RELease ACKnowledge
14
15
16GSM 04.08 3.4.13: RR connection release procedure
17
18* network sends RR CHANNEL RELEASE to MS on the DCCH
19 * start T3109
20 * deactivate SACCH
21* MS disconnects main signalling link (by sending DISC)
22 * all other data links are disconnected by local end link release
23* network receives DISC (BTS sends RLL REL IND to BSC)
24 * stop T3109
25 * start T3111
26* when T3111 times out, the network can reuse the channls
27* if T3109 times out, the network deactivates the channels
28 and can reuse them
29 * this probably means simply RF CHANnel RELease
30
31
32== Implementation in OpenBSC ==
33
Holger Hans Peter Freyther62626432010-09-03 15:34:12 +080034There are two possible reasons a gsm_subscriber_connection
35will be released. One is a network failure, the other is
36the completion of an operation/transaction.
Holger Hans Peter Freyther40494552010-06-28 17:09:29 +080037
Holger Hans Peter Freyther62626432010-09-03 15:34:12 +080038=== Failure ===
39The BSC API will call the gsm_04_08.c:gsm0408_clear_request callback
40and the MSC part will release all transactions, operations and such
41and the channels will be released as error case.
42
43=== Success ===
44Every time an 'operation' or 'transaction' is finished msc_release_connection
45will be called and it will determine if the gsm_subscriber_connection can
46be released.
47
48In case it can be released bsc_api.c:gsm0808_clear will be called
49which will release all lchan's associated with the connection. For the
50primary channel a SACH Deactivate will be send with the release
51reason NORMAL RELEASE.
52
53
54bsc_api.c:gsm0808_clear
55 * Release a channel used for handover
56 * Release the primary lchan with normal release, SACH deactivate
57
Holger Hans Peter Freytherafa0ad12012-04-18 18:58:36 +020058chan_alloc.c:lchan_release(chan, sacch_deactivate, reason)
Holger Hans Peter Freyther85825352011-12-27 22:24:17 +010059 * Start the release procedure. It is working in steps with callbacks
60 coming from the abis_rsl.c code.
61 * Release all SAPI's > 0 as local end (The BTS should send a
62 REL_CONF a message)
63 * Send SACH Deactivate on SAPI=0 if required.
Holger Hans Peter Freytherb3489392011-12-28 16:21:05 +010064 * Start T3109 (stop it when the main signalling link is disconnected)
65 or when the channel released. On timeout start the error handling.
Holger Hans Peter Freyther85825352011-12-27 22:24:17 +010066 * abis_rsl.c schedules the RSL_MT_RF_CHAN_REL once all SAPI's are
67 released and after T3111 has timed out or there is an error.
Holger Hans Peter Freyther62626432010-09-03 15:34:12 +080068
Harald Welted26d3d92009-08-10 11:35:33 +020069RX of RELease INDication:
Holger Hans Peter Freyther62626432010-09-03 15:34:12 +080070 * Calls internal rsl_handle_release which might release the RF.
Harald Welted26d3d92009-08-10 11:35:33 +020071
Holger Hans Peter Freyther85825352011-12-27 22:24:17 +010072RX of RELease CONFirmation:
Holger Hans Peter Freyther62626432010-09-03 15:34:12 +080073 * Calls internal rsl_handle_release which might release the RF.
Harald Welted26d3d92009-08-10 11:35:33 +020074
75* RX of RF_CHAN_REL_ACK
76 * call lchan_free()
Harald Welted26d3d92009-08-10 11:35:33 +020077
78
79=== Integration with SMS ===
80
81* RX of CP_ERROR or unimplemented MT
Holger Hans Peter Freyther62626432010-09-03 15:34:12 +080082 * trigger trans_free() which will msc_release_connection()
Harald Welted26d3d92009-08-10 11:35:33 +020083
84* CP TC1* expired while waiting for CP-ACK
Holger Hans Peter Freyther62626432010-09-03 15:34:12 +080085 * trigger trans_free() which will msc_release_connection()
Harald Welted26d3d92009-08-10 11:35:33 +020086
87* RX of RP_ERROR
Holger Hans Peter Freyther62626432010-09-03 15:34:12 +080088 * trigger trans_free() which will msc_release_connection()
Harald Welted26d3d92009-08-10 11:35:33 +020089
90* TX of CP-ACK in MT DELIVER
Holger Hans Peter Freyther62626432010-09-03 15:34:12 +080091 * trigger trans_free() which will msc_release_connection()
Harald Welted26d3d92009-08-10 11:35:33 +020092
93* RX of CP-ACK in MO SUBMIT
Holger Hans Peter Freyther62626432010-09-03 15:34:12 +080094 * trigger trans_free() which will msc_release_connection()
Harald Welted26d3d92009-08-10 11:35:33 +020095