gprs_bssgp: use gprs_ns2_sns_add_bind() to allow the NSE to use the binds for IP-SNS configuration
The gprs_ns2 now requires to specify every bind which should be used by the NSE for IP-SNS
Related: SYS#5354
Depends: I9ab8092bf286e7d90e92f5702a5404425e959c84 (libosmocore)
Change-Id: I35c987224ce098f7ee9f189ce0fce9e68ad3feac
diff --git a/src/gprs_bssgp_pcu.c b/src/gprs_bssgp_pcu.c
index ce36c6b..84e9ec5 100644
--- a/src/gprs_bssgp_pcu.c
+++ b/src/gprs_bssgp_pcu.c
@@ -1023,6 +1023,14 @@
LOGP(DBSSGP, LOGL_ERROR, "Failed to bind to %s\n", osmo_sockaddr_to_str(&local[i]));
continue;
}
+
+ if (the_pcu->vty.ns_dialect == GPRS_NS2_DIALECT_SNS) {
+ rc = gprs_ns2_sns_add_bind(bts->nse, bind[i]);
+ if (rc < 0) {
+ LOGP(DBSSGP, LOGL_ERROR, "Failed to add bind %s to the NSE for IP-SNS\n", osmo_sockaddr_to_str(&local[i]));
+ continue;
+ }
+ }
}
binds |= 1 << i;