Harald Welte | 75827d6 | 2010-05-18 11:07:34 +0200 | [diff] [blame] | 1 | #ifndef _GPRS_GMM_H |
| 2 | #define _GPRS_GMM_H |
| 3 | |
Pablo Neira Ayuso | 136f453 | 2011-03-22 16:47:59 +0100 | [diff] [blame] | 4 | #include <osmocom/core/msgb.h> |
Neels Hofmeyr | 396f2e6 | 2017-09-04 15:13:25 +0200 | [diff] [blame] | 5 | #include <osmocom/sgsn/gprs_sgsn.h> |
Harald Welte | 807a5d8 | 2010-06-01 11:53:01 +0200 | [diff] [blame] | 6 | |
Max | 8204010 | 2016-07-06 11:59:18 +0200 | [diff] [blame] | 7 | #include <stdbool.h> |
| 8 | |
Harald Welte | a9b473a | 2010-12-24 21:13:26 +0100 | [diff] [blame] | 9 | int gsm48_tx_gsm_deact_pdp_req(struct sgsn_pdp_ctx *pdp, uint8_t sm_cause); |
Harald Welte | 75827d6 | 2010-05-18 11:07:34 +0200 | [diff] [blame] | 10 | int gsm48_tx_gsm_act_pdp_rej(struct sgsn_mm_ctx *mm, uint8_t tid, |
| 11 | uint8_t cause, uint8_t pco_len, uint8_t *pco_v); |
Harald Welte | 75827d6 | 2010-05-18 11:07:34 +0200 | [diff] [blame] | 12 | int gsm48_tx_gsm_act_pdp_acc(struct sgsn_pdp_ctx *pdp); |
Harald Welte | 77289c2 | 2010-05-18 14:32:29 +0200 | [diff] [blame] | 13 | int gsm48_tx_gsm_deact_pdp_acc(struct sgsn_pdp_ctx *pdp); |
Alexander Couzens | d4788cd | 2018-05-02 22:32:19 +0200 | [diff] [blame] | 14 | int gsm48_tx_gmm_auth_ciph_req(struct sgsn_mm_ctx *mm, |
| 15 | const struct osmo_auth_vector *vec, |
| 16 | uint8_t key_seq, bool force_standby); |
Harald Welte | 77289c2 | 2010-05-18 14:32:29 +0200 | [diff] [blame] | 17 | |
Max | 8204010 | 2016-07-06 11:59:18 +0200 | [diff] [blame] | 18 | int gsm0408_gprs_rcvmsg_gb(struct msgb *msg, struct gprs_llc_llme *llme, |
| 19 | bool drop_cipherable); |
Daniel Willmann | 6292c8d | 2016-05-21 17:35:57 +0200 | [diff] [blame] | 20 | int gsm0408_gprs_rcvmsg_iu(struct msgb *msg, struct gprs_ra_id *ra_id, |
| 21 | uint16_t *sai); |
Jacob Erlbeck | abdf02b | 2014-10-31 12:20:49 +0100 | [diff] [blame] | 22 | int gsm0408_gprs_force_reattach(struct sgsn_mm_ctx *mmctx); |
Max | b997f84 | 2016-07-06 15:57:01 +0200 | [diff] [blame] | 23 | int gsm0408_gprs_force_reattach_oldmsg(struct msgb *msg, |
| 24 | struct gprs_llc_llme *llme); |
Jacob Erlbeck | 423f8bf | 2014-10-24 18:09:54 +0200 | [diff] [blame] | 25 | void gsm0408_gprs_access_granted(struct sgsn_mm_ctx *mmctx); |
Jacob Erlbeck | af3d5c5 | 2015-01-05 17:51:17 +0100 | [diff] [blame] | 26 | void gsm0408_gprs_access_denied(struct sgsn_mm_ctx *mmctx, int gmm_cause); |
| 27 | void gsm0408_gprs_access_cancelled(struct sgsn_mm_ctx *mmctx, int gmm_cause); |
Jacob Erlbeck | 4adb136 | 2014-12-02 09:47:26 +0100 | [diff] [blame] | 28 | void gsm0408_gprs_authenticate(struct sgsn_mm_ctx *mmctx); |
Harald Welte | 75827d6 | 2010-05-18 11:07:34 +0200 | [diff] [blame] | 29 | |
Harald Welte | 5bfe499 | 2010-06-09 11:22:47 +0200 | [diff] [blame] | 30 | int gprs_gmm_rx_suspend(struct gprs_ra_id *raid, uint32_t tlli); |
| 31 | int gprs_gmm_rx_resume(struct gprs_ra_id *raid, uint32_t tlli, |
| 32 | uint8_t suspend_ref); |
| 33 | |
Jacob Erlbeck | 81ffb74 | 2015-01-23 11:33:51 +0100 | [diff] [blame] | 34 | time_t gprs_max_time_to_idle(void); |
| 35 | |
Neels Hofmeyr | 2188a77 | 2016-05-20 21:59:55 +0200 | [diff] [blame] | 36 | int iu_rab_act_ps(uint8_t rab_id, struct sgsn_pdp_ctx *pdp); |
Daniel Willmann | 6b7b319 | 2016-05-21 00:53:42 +0200 | [diff] [blame] | 37 | |
Alexander Couzens | d4788cd | 2018-05-02 22:32:19 +0200 | [diff] [blame] | 38 | int gsm48_tx_gmm_id_req(struct sgsn_mm_ctx *mm, uint8_t id_type); |
| 39 | int gsm48_tx_gmm_att_rej(struct sgsn_mm_ctx *mm, |
| 40 | uint8_t gmm_cause); |
| 41 | int gsm48_tx_gmm_att_ack(struct sgsn_mm_ctx *mm); |
| 42 | |
Alexander Couzens | 8007be4 | 2018-05-14 06:48:24 +0200 | [diff] [blame] | 43 | /* TODO: move extract_subscr_* when gsm48_gmm_authorize() got removed */ |
| 44 | void extract_subscr_msisdn(struct sgsn_mm_ctx *ctx); |
| 45 | void extract_subscr_hlr(struct sgsn_mm_ctx *ctx); |
Harald Welte | 75827d6 | 2010-05-18 11:07:34 +0200 | [diff] [blame] | 46 | #endif /* _GPRS_GMM_H */ |