This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
pravin gerrit-no-reply at lists.osmocom.orgHello Harald Welte, Jenkins Builder, Holger Freyther,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/1262
to look at the new patch set (#2).
Support Deactivate PDP Context Request from network
This commit will enable trigger of Deactivate PDP context Request message
based on the IMSI of the subscriber.
Change-Id: Ia0a41aa2218ec2fda4ea17a37c8cc55cba63dd13
---
M openbsc/include/openbsc/gprs_sgsn.h
M openbsc/src/gprs/gprs_sgsn.c
2 files changed, 27 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/openbsc refs/changes/62/1262/2
diff --git a/openbsc/include/openbsc/gprs_sgsn.h b/openbsc/include/openbsc/gprs_sgsn.h
index 24e286c..c72171a 100644
--- a/openbsc/include/openbsc/gprs_sgsn.h
+++ b/openbsc/include/openbsc/gprs_sgsn.h
@@ -369,6 +369,8 @@
* ottherwise lost state (recovery procedure) */
int drop_all_pdp_for_ggsn(struct sgsn_ggsn_ctx *ggsn);
+void drop_pdp_for_ms(const char *imsi);
+
char *gprs_pdpaddr2str(uint8_t *pdpa, uint8_t len);
/*
diff --git a/openbsc/src/gprs/gprs_sgsn.c b/openbsc/src/gprs/gprs_sgsn.c
index e5a54d9..d30f401 100644
--- a/openbsc/src/gprs/gprs_sgsn.c
+++ b/openbsc/src/gprs/gprs_sgsn.c
@@ -667,6 +667,31 @@
}
}
+/* High-level function to be called for PDP deactivation initiated from SGSN */
+void drop_pdp_for_ms(const char *imsi)
+{
+ OSMO_ASSERT(imsi != NULL);
+ struct sgsn_mm_ctx *mm;
+ struct sgsn_pdp_ctx *pdp;
+
+ LOGP(DGPRS, LOGL_NOTICE, "SGSN intiated Deactivate PDP for IMSI: %s\n",imsi);
+ /* Search the PDP for this subscriber */
+ mm = sgsn_mm_ctx_by_imsi(imsi);
+ if (mm) {
+ if (llist_empty(&mm->pdp_list)) {
+ gsm0408_gprs_access_cancelled(mm, GMM_CAUSE_GPRS_NOTALLOWED);
+ LOGP(DGPRS, LOGL_NOTICE, "No pdp context for this IMSI\n");
+ } else {
+
+ llist_for_each_entry(pdp, &mm->pdp_list, list) {
+ gsm48_tx_gsm_deact_pdp_req(pdp, GSM_CAUSE_DEACT_REGULAR);
+ LOGPDPCTXP(LOGL_NOTICE, pdp, "PDP Deactivation Successful\n");
+ }
+ }
+ } else
+ LOGP(DGPRS, LOGL_NOTICE, "No mm context for this IMSI\n");
+}
+
/* High-level function to be called in case a GGSN has disappeared or
* otherwise lost state (recovery procedure) */
int drop_all_pdp_for_ggsn(struct sgsn_ggsn_ctx *ggsn)
--
To view, visit https://gerrit.osmocom.org/1262
To unsubscribe, visit https://gerrit.osmocom.org/settings
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ia0a41aa2218ec2fda4ea17a37c8cc55cba63dd13
Gerrit-PatchSet: 2
Gerrit-Project: openbsc
Gerrit-Branch: master
Gerrit-Owner: pravin <pravin.manoharan at radisys.com>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Holger Freyther <holger at freyther.de>
Gerrit-Reviewer: Jenkins Builder