aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/gprs/sgsn_libgtp.c
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <holger@moiji-mobile.com>2015-05-02 19:55:38 +0200
committerHolger Hans Peter Freyther <holger@moiji-mobile.com>2015-05-06 17:14:51 +0200
commitb100895557af0980d5910a3dc81903179dea615e (patch)
tree72b97e900680fad022778dc24f42c0ff44cdb7f5 /openbsc/src/gprs/sgsn_libgtp.c
parent20de3ae17cbb61f831ca8f06a4cf7436441cfdc6 (diff)
sgsn: Add various signals consumed by CDR or other client code
Diffstat (limited to 'openbsc/src/gprs/sgsn_libgtp.c')
-rw-r--r--openbsc/src/gprs/sgsn_libgtp.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/openbsc/src/gprs/sgsn_libgtp.c b/openbsc/src/gprs/sgsn_libgtp.c
index eee3ef21c..af5c93de3 100644
--- a/openbsc/src/gprs/sgsn_libgtp.c
+++ b/openbsc/src/gprs/sgsn_libgtp.c
@@ -287,6 +287,7 @@ static const struct cause_map gtp2sm_cause_map[] = {
/* The GGSN has confirmed the creation of a PDP Context */
static int create_pdp_conf(struct pdp_t *pdp, void *cbp, int cause)
{
+ struct sgsn_signal_data sig_data;
struct sgsn_pdp_ctx *pctx = cbp;
uint8_t reject_cause;
@@ -322,6 +323,11 @@ static int create_pdp_conf(struct pdp_t *pdp, void *cbp, int cause)
/* Activate the SNDCP layer */
sndcp_sm_activate_ind(&pctx->mm->llme->lle[pctx->sapi], pctx->nsapi);
+ /* Inform others about it */
+ memset(&sig_data, 0, sizeof(sig_data));
+ sig_data.pdp = pctx;
+ osmo_signal_dispatch(SS_SGSN, S_SGSN_PDP_ACT, &sig_data);
+
/* Send PDP CTX ACT to MS */
return gsm48_tx_gsm_act_pdp_acc(pctx);
@@ -349,12 +355,17 @@ reject:
/* Confirmation of a PDP Context Delete */
static int delete_pdp_conf(struct pdp_t *pdp, void *cbp, int cause)
{
+ struct sgsn_signal_data sig_data;
struct sgsn_pdp_ctx *pctx = cbp;
int rc = 0;
LOGPDPCTXP(LOGL_INFO, pctx, "Received DELETE PDP CTX CONF, cause=%d(%s)\n",
cause, get_value_string(gtp_cause_strs, cause));
+ memset(&sig_data, 0, sizeof(sig_data));
+ sig_data.pdp = pctx;
+ osmo_signal_dispatch(SS_SGSN, S_SGSN_PDP_DEACT, &sig_data);
+
if (pctx->mm) {
/* Deactivate the SNDCP layer */
sndcp_sm_deactivate_ind(&pctx->mm->llme->lle[pctx->sapi], pctx->nsapi);