Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 1 | /* gprs_rlcmac.h |
| 2 | * |
| 3 | * Copyright (C) 2012 Ivan Klyuchnikov |
Holger Hans Peter Freyther | d6bd91e | 2013-08-24 21:16:55 +0200 | [diff] [blame] | 4 | * Copyright (C) 2013 by Holger Hans Peter Freyther |
Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 5 | * |
| 6 | * This program is free software; you can redistribute it and/or |
| 7 | * modify it under the terms of the GNU General Public License |
| 8 | * as published by the Free Software Foundation; either version 2 |
| 9 | * of the License, or (at your option) any later version. |
| 10 | * |
| 11 | * This program is distributed in the hope that it will be useful, |
| 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 14 | * GNU General Public License for more details. |
| 15 | * |
| 16 | * You should have received a copy of the GNU General Public License |
| 17 | * along with this program; if not, write to the Free Software |
| 18 | * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
| 19 | */ |
| 20 | |
| 21 | #ifndef GPRS_RLCMAC_H |
| 22 | #define GPRS_RLCMAC_H |
| 23 | |
Andreas Eversberg | 8b761a3 | 2012-07-20 21:50:31 +0200 | [diff] [blame] | 24 | #ifdef __cplusplus |
Ivan Kluchnikov | 835f91e | 2012-04-30 18:00:36 +0400 | [diff] [blame] | 25 | #include <bitvector.h> |
Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 26 | #include <gsm_rlcmac.h> |
Ivan Kluchnikov | 61a33f7 | 2012-04-12 15:22:06 +0400 | [diff] [blame] | 27 | #include <gsm_timer.h> |
Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 28 | |
| 29 | extern "C" { |
| 30 | #include <osmocom/core/linuxlist.h> |
Ivan Kluchnikov | 61a33f7 | 2012-04-12 15:22:06 +0400 | [diff] [blame] | 31 | #include <osmocom/core/timer.h> |
Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 32 | } |
Andreas Eversberg | 8b761a3 | 2012-07-20 21:50:31 +0200 | [diff] [blame] | 33 | #endif |
Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 34 | |
Andreas Eversberg | b83e2a7 | 2012-10-07 15:26:00 +0200 | [diff] [blame] | 35 | /* generate a diagram for debugging timing issues */ |
| 36 | //#define DEBUG_DIAGRAM |
| 37 | |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 38 | /* This special feature will delay assignment of downlink TBF by one second, |
| 39 | * in case there is already a TBF. |
| 40 | * This is usefull to debug downlink establishment during packet idle mode. |
| 41 | */ |
| 42 | //#define DEBUG_DL_ASS_IDLE |
Ivan Kluchnikov | c5d8c27 | 2012-06-04 21:55:02 +0400 | [diff] [blame] | 43 | |
Andreas Eversberg | 5dac2f0 | 2012-06-27 15:52:04 +0200 | [diff] [blame] | 44 | /* |
| 45 | * PDCH instanc |
| 46 | */ |
| 47 | |
| 48 | struct gprs_rlcmac_tbf; |
| 49 | |
| 50 | struct gprs_rlcmac_pdch { |
| 51 | uint8_t enable; /* TS is enabled */ |
| 52 | uint8_t tsc; /* TSC of this slot */ |
| 53 | uint8_t next_ul_tfi; /* next uplink TBF/TFI to schedule (0..31) */ |
| 54 | uint8_t next_dl_tfi; /* next downlink TBF/TFI to schedule (0..31) */ |
Andreas Eversberg | b0c7ea7 | 2012-07-13 14:46:03 +0200 | [diff] [blame] | 55 | struct gprs_rlcmac_tbf *ul_tbf[32]; /* array of UL TBF, by UL TFI */ |
| 56 | struct gprs_rlcmac_tbf *dl_tbf[32]; /* array of DL TBF, by DL TFI */ |
Andreas Eversberg | 2b91464 | 2012-07-19 13:06:26 +0200 | [diff] [blame] | 57 | struct llist_head paging_list; /* list of paging messages */ |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 58 | uint32_t last_rts_fn; /* store last frame number of RTS */ |
Ivan Kluchnikov | a9e6dc5 | 2012-06-17 08:30:06 +0400 | [diff] [blame] | 59 | }; |
| 60 | |
Andreas Eversberg | 5dac2f0 | 2012-06-27 15:52:04 +0200 | [diff] [blame] | 61 | struct gprs_rlcmac_trx { |
Andreas Eversberg | a23c7ee | 2012-12-18 10:47:28 +0100 | [diff] [blame] | 62 | void *fl1h; |
Andreas Eversberg | 5dac2f0 | 2012-06-27 15:52:04 +0200 | [diff] [blame] | 63 | uint16_t arfcn; |
| 64 | struct gprs_rlcmac_pdch pdch[8]; |
Andreas Eversberg | adb2f18 | 2012-08-07 17:06:08 +0200 | [diff] [blame] | 65 | struct gprs_rlcmac_tbf *ul_tbf[32]; /* array of UL TBF, by UL TFI */ |
| 66 | struct gprs_rlcmac_tbf *dl_tbf[32]; /* array of DL TBF, by DL TFI */ |
Andreas Eversberg | 5dac2f0 | 2012-06-27 15:52:04 +0200 | [diff] [blame] | 67 | }; |
| 68 | |
| 69 | struct gprs_rlcmac_bts { |
Andreas Eversberg | a23c7ee | 2012-12-18 10:47:28 +0100 | [diff] [blame] | 70 | uint8_t bsic; |
Andreas Eversberg | cd8a83a | 2012-09-23 06:41:21 +0200 | [diff] [blame] | 71 | uint8_t fc_interval; |
Andreas Eversberg | b3c6f6c | 2012-07-06 07:40:08 +0200 | [diff] [blame] | 72 | uint8_t cs1; |
| 73 | uint8_t cs2; |
| 74 | uint8_t cs3; |
| 75 | uint8_t cs4; |
Andreas Eversberg | 499ff41 | 2012-10-03 14:21:36 +0200 | [diff] [blame] | 76 | uint8_t initial_cs_dl, initial_cs_ul; |
Andreas Eversberg | 8b761a3 | 2012-07-20 21:50:31 +0200 | [diff] [blame] | 77 | uint8_t force_cs; /* 0=use from BTS 1=use from VTY */ |
Andreas Eversberg | 24131bf | 2012-07-21 11:09:58 +0200 | [diff] [blame] | 78 | uint16_t force_llc_lifetime; /* overrides lifetime from SGSN */ |
Andreas Eversberg | b3c6f6c | 2012-07-06 07:40:08 +0200 | [diff] [blame] | 79 | uint8_t t3142; |
| 80 | uint8_t t3169; |
| 81 | uint8_t t3191; |
| 82 | uint16_t t3193_msec; |
| 83 | uint8_t t3195; |
| 84 | uint8_t n3101; |
| 85 | uint8_t n3103; |
| 86 | uint8_t n3105; |
Andreas Eversberg | 5dac2f0 | 2012-06-27 15:52:04 +0200 | [diff] [blame] | 87 | struct gprs_rlcmac_trx trx[8]; |
Holger Hans Peter Freyther | b67a8a3 | 2013-07-28 18:55:14 +0200 | [diff] [blame] | 88 | int (*alloc_algorithm)(struct gprs_rlcmac_bts *bts, |
| 89 | struct gprs_rlcmac_tbf *old_tbf, |
Andreas Eversberg | f01929b | 2012-10-08 12:40:49 +0200 | [diff] [blame] | 90 | struct gprs_rlcmac_tbf *tbf, uint32_t cust, uint8_t single); |
Andreas Eversberg | 592e04a | 2012-07-15 06:25:37 +0200 | [diff] [blame] | 91 | uint32_t alloc_algorithm_curst; /* options to customize algorithm */ |
Andreas Eversberg | 07e97cf | 2012-08-07 16:00:56 +0200 | [diff] [blame] | 92 | uint8_t force_two_phase; |
Andreas Eversberg | aafcbbb | 2012-09-27 09:20:45 +0200 | [diff] [blame] | 93 | uint8_t alpha, gamma; |
Andreas Eversberg | 5dac2f0 | 2012-06-27 15:52:04 +0200 | [diff] [blame] | 94 | }; |
| 95 | |
| 96 | extern struct gprs_rlcmac_bts *gprs_rlcmac_bts; |
| 97 | |
Andreas Eversberg | 8b761a3 | 2012-07-20 21:50:31 +0200 | [diff] [blame] | 98 | #ifdef __cplusplus |
Andreas Eversberg | 5dac2f0 | 2012-06-27 15:52:04 +0200 | [diff] [blame] | 99 | /* |
Andreas Eversberg | 2b91464 | 2012-07-19 13:06:26 +0200 | [diff] [blame] | 100 | * paging entry |
| 101 | */ |
| 102 | struct gprs_rlcmac_paging { |
| 103 | struct llist_head list; |
| 104 | uint8_t chan_needed; |
| 105 | uint8_t identity_lv[9]; |
| 106 | }; |
Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 107 | |
Andreas Eversberg | 07e97cf | 2012-08-07 16:00:56 +0200 | [diff] [blame] | 108 | /* |
| 109 | * single block allocation entry |
| 110 | */ |
| 111 | struct gprs_rlcmac_sba { |
| 112 | struct llist_head list; |
| 113 | uint8_t trx; |
| 114 | uint8_t ts; |
| 115 | uint32_t fn; |
| 116 | uint8_t ta; |
| 117 | }; |
Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 118 | |
Andreas Eversberg | 3b1332c | 2012-10-03 14:20:53 +0200 | [diff] [blame] | 119 | /* |
| 120 | * coding scheme info |
| 121 | */ |
| 122 | struct gprs_rlcmac_cs { |
| 123 | uint8_t block_length; |
| 124 | uint8_t block_data; |
| 125 | uint8_t block_payload; |
| 126 | }; |
Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 127 | |
Andreas Eversberg | 3b1332c | 2012-10-03 14:20:53 +0200 | [diff] [blame] | 128 | extern struct gprs_rlcmac_cs gprs_rlcmac_cs[]; |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 129 | |
Andreas Eversberg | b83e2a7 | 2012-10-07 15:26:00 +0200 | [diff] [blame] | 130 | #ifdef DEBUG_DIAGRAM |
| 131 | void debug_diagram(int diag, const char *format, ...); |
| 132 | #else |
| 133 | #define debug_diagram(a, b, args...) ; |
| 134 | #endif |
| 135 | |
Andreas Eversberg | 050ace2 | 2013-03-16 16:22:02 +0100 | [diff] [blame] | 136 | int gprs_rlcmac_received_lost(struct gprs_rlcmac_tbf *tbf, uint16_t received, |
| 137 | uint16_t lost); |
| 138 | |
| 139 | int gprs_rlcmac_lost_rep(struct gprs_rlcmac_tbf *tbf); |
| 140 | |
| 141 | int gprs_rlcmac_meas_rep(Packet_Measurement_Report_t *pmr); |
| 142 | |
| 143 | int gprs_rlcmac_rssi(struct gprs_rlcmac_tbf *tbf, int8_t rssi); |
| 144 | |
| 145 | int gprs_rlcmac_rssi_rep(struct gprs_rlcmac_tbf *tbf); |
| 146 | |
| 147 | int gprs_rlcmac_dl_bw(struct gprs_rlcmac_tbf *tbf, uint16_t octets); |
| 148 | |
Andreas Eversberg | 07e97cf | 2012-08-07 16:00:56 +0200 | [diff] [blame] | 149 | int sba_alloc(uint8_t *_trx, uint8_t *_ts, uint32_t *_fn, uint8_t ta); |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 150 | |
Andreas Eversberg | 07e97cf | 2012-08-07 16:00:56 +0200 | [diff] [blame] | 151 | struct gprs_rlcmac_sba *sba_find(uint8_t trx, uint8_t ts, uint32_t fn); |
| 152 | |
Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 153 | /* TS 44.060 Section 10.4.7 Table 10.4.7.1: Payload Type field */ |
| 154 | enum gprs_rlcmac_block_type { |
| 155 | GPRS_RLCMAC_DATA_BLOCK = 0x0, |
| 156 | GPRS_RLCMAC_CONTROL_BLOCK = 0x1, |
| 157 | GPRS_RLCMAC_CONTROL_BLOCK_OPT = 0x2, |
| 158 | GPRS_RLCMAC_RESERVED = 0x3 |
| 159 | }; |
| 160 | |
Andreas Eversberg | b0c7ea7 | 2012-07-13 14:46:03 +0200 | [diff] [blame] | 161 | int gprs_rlcmac_rcv_block(uint8_t trx, uint8_t ts, uint8_t *data, uint8_t len, |
Andreas Eversberg | 570b44b | 2013-03-16 16:15:01 +0100 | [diff] [blame] | 162 | uint32_t fn, int8_t rssi); |
Ivan Kluchnikov | a9e6dc5 | 2012-06-17 08:30:06 +0400 | [diff] [blame] | 163 | |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 164 | int write_immediate_assignment(bitvec * dest, uint8_t downlink, uint8_t ra, |
Andreas Eversberg | 07e97cf | 2012-08-07 16:00:56 +0200 | [diff] [blame] | 165 | uint32_t ref_fn, uint8_t ta, uint16_t arfcn, uint8_t ts, uint8_t tsc, |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 166 | uint8_t tfi, uint8_t usf, uint32_t tlli, uint8_t polling, |
Andreas Eversberg | afdd9e1 | 2012-10-07 17:08:55 +0200 | [diff] [blame] | 167 | uint32_t fn, uint8_t single_block, uint8_t alpha, uint8_t gamma, |
| 168 | int8_t ta_idx); |
Ivan Kluchnikov | cf7b3a5 | 2012-06-26 16:54:22 +0400 | [diff] [blame] | 169 | |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 170 | void write_packet_uplink_assignment(bitvec * dest, uint8_t old_tfi, |
Andreas Eversberg | b0c7ea7 | 2012-07-13 14:46:03 +0200 | [diff] [blame] | 171 | uint8_t old_downlink, uint32_t tlli, uint8_t use_tlli, |
Andreas Eversberg | aafcbbb | 2012-09-27 09:20:45 +0200 | [diff] [blame] | 172 | struct gprs_rlcmac_tbf *tbf, uint8_t poll, uint8_t alpha, |
Andreas Eversberg | afdd9e1 | 2012-10-07 17:08:55 +0200 | [diff] [blame] | 173 | uint8_t gamma, int8_t ta_idx); |
Ivan Kluchnikov | a9e6dc5 | 2012-06-17 08:30:06 +0400 | [diff] [blame] | 174 | |
Ivan Kluchnikov | ef7f28c | 2012-07-12 14:49:15 +0400 | [diff] [blame] | 175 | void write_packet_downlink_assignment(RlcMacDownlink_t * block, uint8_t old_tfi, |
Andreas Eversberg | aafcbbb | 2012-09-27 09:20:45 +0200 | [diff] [blame] | 176 | uint8_t old_downlink, struct gprs_rlcmac_tbf *tbf, uint8_t poll, |
Andreas Eversberg | afdd9e1 | 2012-10-07 17:08:55 +0200 | [diff] [blame] | 177 | uint8_t alpha, uint8_t gamma, int8_t ta_idx, uint8_t ta_ts); |
Andreas Eversberg | b0c7ea7 | 2012-07-13 14:46:03 +0200 | [diff] [blame] | 178 | |
| 179 | |
Ivan Kluchnikov | a9e6dc5 | 2012-06-17 08:30:06 +0400 | [diff] [blame] | 180 | |
Ivan Kluchnikov | ef7f28c | 2012-07-12 14:49:15 +0400 | [diff] [blame] | 181 | void write_packet_uplink_ack(RlcMacDownlink_t * block, struct gprs_rlcmac_tbf *tbf, |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 182 | uint8_t final); |
Ivan Kluchnikov | a9e6dc5 | 2012-06-17 08:30:06 +0400 | [diff] [blame] | 183 | |
Andreas Eversberg | 3e372d5 | 2012-07-06 09:28:15 +0200 | [diff] [blame] | 184 | int gprs_rlcmac_tx_ul_ud(gprs_rlcmac_tbf *tbf); |
Ivan Kluchnikov | a9e6dc5 | 2012-06-17 08:30:06 +0400 | [diff] [blame] | 185 | |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 186 | int gprs_rlcmac_poll_timeout(struct gprs_rlcmac_tbf *tbf); |
Andreas Eversberg | 0aed654 | 2012-06-23 10:33:16 +0200 | [diff] [blame] | 187 | |
Andreas Eversberg | a004e6a | 2013-05-13 16:45:21 +0200 | [diff] [blame] | 188 | int gprs_rlcmac_sba_timeout(struct gprs_rlcmac_sba *sba); |
| 189 | |
Andreas Eversberg | 0aed654 | 2012-06-23 10:33:16 +0200 | [diff] [blame] | 190 | int gprs_rlcmac_rcv_rach(uint8_t ra, uint32_t Fn, int16_t qta); |
Ivan Kluchnikov | 5310d45 | 2012-04-17 22:00:31 +0400 | [diff] [blame] | 191 | |
Andreas Eversberg | b0c7ea7 | 2012-07-13 14:46:03 +0200 | [diff] [blame] | 192 | int gprs_rlcmac_rcv_control_block(bitvec *rlc_block, uint8_t trx, uint8_t ts, |
| 193 | uint32_t fn); |
Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 194 | |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 195 | struct msgb *gprs_rlcmac_send_packet_uplink_assignment( |
| 196 | struct gprs_rlcmac_tbf *tbf, uint32_t fn); |
Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 197 | |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 198 | struct msgb *gprs_rlcmac_send_packet_downlink_assignment( |
| 199 | struct gprs_rlcmac_tbf *tbf, uint32_t fn); |
Ivan Kluchnikov | c320d86 | 2012-03-18 15:04:48 +0400 | [diff] [blame] | 200 | |
Andreas Eversberg | 7f5352c | 2012-07-23 18:20:36 +0200 | [diff] [blame] | 201 | void gprs_rlcmac_trigger_downlink_assignment(struct gprs_rlcmac_tbf *tbf, |
Holger Hans Peter Freyther | 52c911b | 2013-08-24 18:30:54 +0200 | [diff] [blame] | 202 | struct gprs_rlcmac_tbf *old_tbf, const char *imsi); |
Ivan Kluchnikov | c7e7f68 | 2012-06-29 22:53:15 +0400 | [diff] [blame] | 203 | |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 204 | int gprs_rlcmac_downlink_ack(struct gprs_rlcmac_tbf *tbf, uint8_t final, |
| 205 | uint8_t ssn, uint8_t *rbb); |
Andreas Eversberg | 5dac2f0 | 2012-06-27 15:52:04 +0200 | [diff] [blame] | 206 | |
Andreas Eversberg | 8c3680d | 2012-10-08 12:30:56 +0200 | [diff] [blame] | 207 | int gprs_rlcmac_paging_request(uint8_t *ptmsi, uint16_t ptmsi_len, |
| 208 | const char *imsi); |
| 209 | |
Andreas Eversberg | 2b91464 | 2012-07-19 13:06:26 +0200 | [diff] [blame] | 210 | unsigned write_packet_paging_request(bitvec * dest); |
| 211 | |
| 212 | unsigned write_repeated_page_info(bitvec * dest, unsigned& wp, uint8_t len, |
| 213 | uint8_t *identity, uint8_t chan_needed); |
| 214 | |
Andreas Eversberg | b0c7ea7 | 2012-07-13 14:46:03 +0200 | [diff] [blame] | 215 | int gprs_rlcmac_rcv_data_block_acknowledged(uint8_t trx, uint8_t ts, |
Andreas Eversberg | 570b44b | 2013-03-16 16:15:01 +0100 | [diff] [blame] | 216 | uint8_t *data, uint8_t len, int8_t rssi); |
Andreas Eversberg | 5dac2f0 | 2012-06-27 15:52:04 +0200 | [diff] [blame] | 217 | |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 218 | struct msgb *gprs_rlcmac_send_data_block_acknowledged( |
Andreas Eversberg | 592e04a | 2012-07-15 06:25:37 +0200 | [diff] [blame] | 219 | struct gprs_rlcmac_tbf *tbf, uint32_t fn, uint8_t ts); |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 220 | |
Andreas Eversberg | 5dac2f0 | 2012-06-27 15:52:04 +0200 | [diff] [blame] | 221 | struct msgb *gprs_rlcmac_send_uplink_ack(struct gprs_rlcmac_tbf *tbf, |
| 222 | uint32_t fn); |
Ivan Kluchnikov | 9c795ab | 2012-05-24 23:12:59 +0400 | [diff] [blame] | 223 | |
Andreas Eversberg | e6228b3 | 2012-07-03 13:36:03 +0200 | [diff] [blame] | 224 | int gprs_rlcmac_rcv_rts_block(uint8_t trx, uint8_t ts, uint16_t arfcn, |
| 225 | uint32_t fn, uint8_t block_nr); |
| 226 | |
Andreas Eversberg | a9be154 | 2012-09-27 09:23:24 +0200 | [diff] [blame] | 227 | int gprs_rlcmac_imm_ass_cnf(uint8_t *data, uint32_t fn); |
| 228 | |
Andreas Eversberg | 2b91464 | 2012-07-19 13:06:26 +0200 | [diff] [blame] | 229 | int gprs_rlcmac_add_paging(uint8_t chan_needed, uint8_t *identity_lv); |
| 230 | |
| 231 | struct gprs_rlcmac_paging *gprs_rlcmac_dequeue_paging( |
| 232 | struct gprs_rlcmac_pdch *pdch); |
| 233 | |
| 234 | struct msgb *gprs_rlcmac_send_packet_paging_request( |
| 235 | struct gprs_rlcmac_pdch *pdch); |
Andreas Eversberg | a1503fa | 2012-07-22 08:58:09 +0200 | [diff] [blame] | 236 | |
Andreas Eversberg | a004e6a | 2013-05-13 16:45:21 +0200 | [diff] [blame] | 237 | int remember_timing_advance(uint32_t tlli, uint8_t ta); |
| 238 | |
| 239 | int recall_timing_advance(uint32_t tlli); |
| 240 | |
| 241 | int flush_timing_advance(void); |
| 242 | |
Andreas Eversberg | a1503fa | 2012-07-22 08:58:09 +0200 | [diff] [blame] | 243 | extern "C" { |
| 244 | #endif |
Holger Hans Peter Freyther | b67a8a3 | 2013-07-28 18:55:14 +0200 | [diff] [blame] | 245 | int alloc_algorithm_a(struct gprs_rlcmac_bts *bts, |
| 246 | struct gprs_rlcmac_tbf *old_tbf, |
Andreas Eversberg | f01929b | 2012-10-08 12:40:49 +0200 | [diff] [blame] | 247 | struct gprs_rlcmac_tbf *tbf, uint32_t cust, uint8_t single); |
Andreas Eversberg | a1503fa | 2012-07-22 08:58:09 +0200 | [diff] [blame] | 248 | |
Holger Hans Peter Freyther | b67a8a3 | 2013-07-28 18:55:14 +0200 | [diff] [blame] | 249 | int alloc_algorithm_b(struct gprs_rlcmac_bts *bts, |
| 250 | struct gprs_rlcmac_tbf *old_tbf, |
Andreas Eversberg | f01929b | 2012-10-08 12:40:49 +0200 | [diff] [blame] | 251 | struct gprs_rlcmac_tbf *tbf, uint32_t cust, uint8_t single); |
Andreas Eversberg | a1503fa | 2012-07-22 08:58:09 +0200 | [diff] [blame] | 252 | #ifdef __cplusplus |
| 253 | } |
Andreas Eversberg | 8b761a3 | 2012-07-20 21:50:31 +0200 | [diff] [blame] | 254 | #endif |
Andreas Eversberg | 2b91464 | 2012-07-19 13:06:26 +0200 | [diff] [blame] | 255 | |
Ivan Kluchnikov | 8ee6051 | 2012-03-05 19:24:57 +0400 | [diff] [blame] | 256 | #endif // GPRS_RLCMAC_H |