From 16f30b53739386810783a5fa78b6af989f5dd330 Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Mon, 4 Aug 2014 11:24:25 +0200 Subject: gbproxy: Have a clear namespace for the public functions Done with Jacob --- openbsc/include/openbsc/gb_proxy.h | 3 +-- openbsc/src/gprs/gb_proxy.c | 8 ++++---- openbsc/src/gprs/gb_proxy_vty.c | 2 +- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/openbsc/include/openbsc/gb_proxy.h b/openbsc/include/openbsc/gb_proxy.h index 09ac83657..a251e5ba5 100644 --- a/openbsc/include/openbsc/gb_proxy.h +++ b/openbsc/include/openbsc/gb_proxy.h @@ -115,6 +115,5 @@ void gbprox_delete_tlli(struct gbprox_peer *peer, int gbprox_remove_stale_tllis(struct gbprox_peer *peer, time_t now); int gbprox_cleanup_peers(uint16_t nsei, uint16_t bvci); -/* tmp */ -struct gbprox_peer *peer_by_nsei(uint16_t nsei); +struct gbprox_peer *gbprox_peer_by_nsei(uint16_t nsei); #endif diff --git a/openbsc/src/gprs/gb_proxy.c b/openbsc/src/gprs/gb_proxy.c index 158950dc1..504b1a464 100644 --- a/openbsc/src/gprs/gb_proxy.c +++ b/openbsc/src/gprs/gb_proxy.c @@ -144,7 +144,7 @@ static struct gbprox_peer *peer_by_bvci(uint16_t bvci) } /* Find the gbprox_peer by its NSEI */ -struct gbprox_peer *peer_by_nsei(uint16_t nsei) +struct gbprox_peer *gbprox_peer_by_nsei(uint16_t nsei) { struct gbprox_peer *peer; llist_for_each_entry(peer, &gbcfg.bts_peers, list) { @@ -1332,7 +1332,7 @@ static void gbprox_patch_bssgp_message(struct msgb *msg, peer = peer_by_bvci(msgb_bvci(msg)); if (!peer && !to_bss) - peer = peer_by_nsei(msgb_nsei(msg)); + peer = gbprox_peer_by_nsei(msgb_nsei(msg)); if (!peer) peer = peer_by_bssgp_tlv(&tp); @@ -1544,7 +1544,7 @@ static int gbprox_rx_sig_from_bss(struct msgb *msg, uint16_t nsei, * BSSGP */ if (!TLVP_PRESENT(&tp, BSSGP_IE_ROUTEING_AREA)) goto err_mand_ie; - from_peer = peer_by_nsei(nsei); + from_peer = gbprox_peer_by_nsei(nsei); if (!from_peer) goto err_no_peer; memcpy(from_peer->ra, TLVP_VAL(&tp, BSSGP_IE_ROUTEING_AREA), @@ -1911,7 +1911,7 @@ int gbprox_signal(unsigned int subsys, unsigned int signal, if (!nsvc->remote_end_is_sgsn) { /* from BSS to SGSN */ - peer = peer_by_nsei(nsvc->nsei); + peer = gbprox_peer_by_nsei(nsvc->nsei); if (!peer) { LOGP(DGPRS, LOGL_NOTICE, "signal %u for unknown peer " "NSEI=%u/NSVCI=%u\n", signal, nsvc->nsei, diff --git a/openbsc/src/gprs/gb_proxy_vty.c b/openbsc/src/gprs/gb_proxy_vty.c index ee13e4cb7..41129d861 100644 --- a/openbsc/src/gprs/gb_proxy_vty.c +++ b/openbsc/src/gprs/gb_proxy_vty.c @@ -509,7 +509,7 @@ DEFUN(delete_gb_tlli, delete_gb_tlli_cmd, break; } - peer = peer_by_nsei(nsei); + peer = gbprox_peer_by_nsei(nsei); if (!peer) { vty_out(vty, "Didn't find peer with NSEI %d%s", nsei, VTY_NEWLINE); -- cgit v1.2.3