Harald Welte | 30fabdf | 2012-09-10 08:54:35 +0200 | [diff] [blame] | 1 | #ifndef _BSSGP_BSS_H |
| 2 | #define _BSSGP_BSS_H |
| 3 | |
| 4 | #include <osmocom/core/msgb.h> |
| 5 | #include <osmocom/gprs/gprs_bssgp.h> |
| 6 | |
| 7 | /* GPRS BSSGP protocol implementation as per 3GPP TS 08.18 */ |
| 8 | |
| 9 | /* (C) 2009-2012 by Harald Welte <laforge@gnumonks.org> |
| 10 | * |
| 11 | * All Rights Reserved |
| 12 | * |
| 13 | * This program is free software; you can redistribute it and/or modify |
| 14 | * it under the terms of the GNU Affero General Public License as published by |
| 15 | * the Free Software Foundation; either version 3 of the License, or |
| 16 | * (at your option) any later version. |
| 17 | * |
| 18 | * This program is distributed in the hope that it will be useful, |
| 19 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 20 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 21 | * GNU Affero General Public License for more details. |
| 22 | * |
| 23 | * You should have received a copy of the GNU Affero General Public License |
| 24 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 25 | * |
| 26 | */ |
| 27 | |
| 28 | |
| 29 | uint8_t *bssgp_msgb_tlli_put(struct msgb *msg, uint32_t tlli); |
| 30 | |
| 31 | int bssgp_tx_suspend(uint16_t nsei, uint32_t tlli, |
| 32 | const struct gprs_ra_id *ra_id); |
| 33 | |
| 34 | int bssgp_tx_resume(uint16_t nsei, uint32_t tlli, |
| 35 | const struct gprs_ra_id *ra_id, uint8_t suspend_ref); |
| 36 | |
| 37 | int bssgp_tx_ra_capa_upd(struct bssgp_bvc_ctx *bctx, uint32_t tlli, uint8_t tag); |
| 38 | |
| 39 | int bssgp_tx_radio_status_tlli(struct bssgp_bvc_ctx *bctx, uint8_t cause, |
| 40 | uint32_t tlli); |
| 41 | |
| 42 | int bssgp_tx_radio_status_tmsi(struct bssgp_bvc_ctx *bctx, uint8_t cause, |
| 43 | uint32_t tmsi); |
| 44 | |
| 45 | int bssgp_tx_radio_status_imsi(struct bssgp_bvc_ctx *bctx, uint8_t cause, |
| 46 | const char *imsi); |
| 47 | |
| 48 | int bssgp_tx_flush_ll_ack(struct bssgp_bvc_ctx *bctx, uint32_t tlli, |
| 49 | uint8_t action, uint16_t bvci_new, |
| 50 | uint32_t num_octets); |
| 51 | |
| 52 | int bssgp_tx_llc_discarded(struct bssgp_bvc_ctx *bctx, uint32_t tlli, |
| 53 | uint8_t num_frames, uint32_t num_octets); |
| 54 | |
| 55 | int bssgp_tx_bvc_block(struct bssgp_bvc_ctx *bctx, uint8_t cause); |
| 56 | |
| 57 | int bssgp_tx_bvc_unblock(struct bssgp_bvc_ctx *bctx); |
| 58 | |
| 59 | int bssgp_tx_bvc_reset(struct bssgp_bvc_ctx *bctx, uint16_t bvci, uint8_t cause); |
| 60 | |
| 61 | int bssgp_tx_ul_ud(struct bssgp_bvc_ctx *bctx, uint32_t tlli, |
| 62 | const uint8_t *qos_profile, struct msgb *llc_pdu); |
| 63 | |
| 64 | int bssgp_rx_paging(struct bssgp_paging_info *pinfo, |
| 65 | struct msgb *msg); |
| 66 | |
Andreas Eversberg | f44ed8c | 2012-09-23 06:05:20 +0200 | [diff] [blame] | 67 | int bssgp_tx_fc_bvc(struct bssgp_bvc_ctx *bctx, uint8_t tag, |
Harald Welte | e92866b | 2012-09-10 08:56:04 +0200 | [diff] [blame] | 68 | uint32_t bucket_size, uint32_t bucket_leak_rate, |
| 69 | uint16_t bmax_default_ms, uint32_t r_default_ms, |
| 70 | uint8_t *bucket_full_ratio, uint32_t *queue_delay_ms); |
| 71 | |
Andreas Eversberg | f44ed8c | 2012-09-23 06:05:20 +0200 | [diff] [blame] | 72 | int bssgp_tx_fc_ms(struct bssgp_bvc_ctx *bctx, uint32_t tlli, uint8_t tag, |
Harald Welte | e92866b | 2012-09-10 08:56:04 +0200 | [diff] [blame] | 73 | uint32_t ms_bucket_size, uint32_t bucket_leak_rate, |
| 74 | uint8_t *bucket_full_ratio); |
Harald Welte | 30fabdf | 2012-09-10 08:54:35 +0200 | [diff] [blame] | 75 | #endif |