[MERGED] osmo-pcu[master]: Fix compiler warning

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/.

Max gerrit-no-reply at lists.osmocom.org
Mon Dec 4 09:41:19 UTC 2017


Max has submitted this change and it was merged.

Change subject: Fix compiler warning
......................................................................


Fix compiler warning

Move function declarations which use gprs_rlcmac_ul_tbf into tbf.h to
avoid compiler warning:

In file included from pcu_vty.c:15:0:
bts.h:166:27: warning: ‘struct gprs_rlcmac_ul_tbf’ declared inside parameter list will not be visible outside of this definition or declaration
 void update_tbf_ta(struct gprs_rlcmac_ul_tbf *tbf, int8_t ta_delta);
                           ^~~~~~~~~~~~~~~~~~
bts.h:167:24: warning: ‘struct gprs_rlcmac_ul_tbf’ declared inside parameter list will not be visible outside of this definition or declaration
 void set_tbf_ta(struct gprs_rlcmac_ul_tbf *tbf, uint8_t ta);
                        ^~~~~~~~~~~~~~~~~~

Change-Id: Ic34c72c8bff6d7c775f56bb6026fec5425f7dcb4
---
M src/bts.h
M src/tbf.h
2 files changed, 9 insertions(+), 2 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/bts.h b/src/bts.h
index aaf81cf..a32e87d 100644
--- a/src/bts.h
+++ b/src/bts.h
@@ -163,8 +163,6 @@
 extern "C" {
 #endif
 void bts_update_tbf_ta(const char *p, uint32_t fn, uint8_t trx_no, uint8_t ts, int8_t ta, bool is_rach);
-void update_tbf_ta(struct gprs_rlcmac_ul_tbf *tbf, int8_t ta_delta);
-void set_tbf_ta(struct gprs_rlcmac_ul_tbf *tbf, uint8_t ta);
 #ifdef __cplusplus
 }
 #endif
diff --git a/src/tbf.h b/src/tbf.h
index 95e1e89..e9d8df8 100644
--- a/src/tbf.h
+++ b/src/tbf.h
@@ -562,6 +562,15 @@
 	void maybe_schedule_uplink_acknack(const gprs_rlc_data_info *rlc);
 };
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+void update_tbf_ta(struct gprs_rlcmac_ul_tbf *tbf, int8_t ta_delta);
+void set_tbf_ta(struct gprs_rlcmac_ul_tbf *tbf, uint8_t ta);
+#ifdef __cplusplus
+}
+#endif
+
 inline enum gprs_rlcmac_tbf_direction reverse(enum gprs_rlcmac_tbf_direction dir)
 {
 	return (enum gprs_rlcmac_tbf_direction)

-- 
To view, visit https://gerrit.osmocom.org/5118
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic34c72c8bff6d7c775f56bb6026fec5425f7dcb4
Gerrit-PatchSet: 1
Gerrit-Project: osmo-pcu
Gerrit-Branch: master
Gerrit-Owner: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr at sysmocom.de>



More information about the gerrit-log mailing list