aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/gprs_bssgp_pcu.cpp3
-rw-r--r--src/gprs_bssgp_pcu.h4
2 files changed, 7 insertions, 0 deletions
diff --git a/src/gprs_bssgp_pcu.cpp b/src/gprs_bssgp_pcu.cpp
index cc662902..6f67f521 100644
--- a/src/gprs_bssgp_pcu.cpp
+++ b/src/gprs_bssgp_pcu.cpp
@@ -1,6 +1,7 @@
/* gprs_bssgp_pcu.cpp
*
* Copyright (C) 2012 Ivan Klyuchnikov
+ * Copyright (C) 2013 by Holger Hans Peter Freyther
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
@@ -314,6 +315,8 @@ static int gprs_bssgp_pcu_rx_ptp(struct msgb *msg, struct tlv_parsed *tp, struct
switch (pdu_type) {
case BSSGP_PDUT_DL_UNITDATA:
LOGP(DBSSGP, LOGL_DEBUG, "RX: [SGSN->PCU] BSSGP_PDUT_DL_UNITDATA\n");
+ if (the_pcu.on_dl_unit_data)
+ the_pcu.on_dl_unit_data(&the_pcu, msg, tp);
gprs_bssgp_pcu_rx_dl_ud(msg, tp);
break;
case BSSGP_PDUT_PAGING_PS:
diff --git a/src/gprs_bssgp_pcu.h b/src/gprs_bssgp_pcu.h
index 413c0567..7156bf08 100644
--- a/src/gprs_bssgp_pcu.h
+++ b/src/gprs_bssgp_pcu.h
@@ -61,6 +61,10 @@ struct gprs_bssgp_pcu {
/* The BSSGP has been unblocked */
void (*on_unblock_ack)(struct gprs_bssgp_pcu *pcu);
+
+ /* When BSSGP data arrives. The msgb is not only for reference */
+ void (*on_dl_unit_data)(struct gprs_bssgp_pcu *pcu, struct msgb *msg,
+ struct tlv_parsed *tp);
};
struct gprs_bssgp_pcu *gprs_bssgp_create_and_connect(struct gprs_rlcmac_bts *bts,