aboutsummaryrefslogtreecommitdiffstats
path: root/src/tbf.h
diff options
context:
space:
mode:
authorDaniel Willmann <dwillmann@sysmocom.de>2014-08-15 18:11:57 +0200
committerDaniel Willmann <daniel@totalueberwachung.de>2014-08-15 18:28:45 +0200
commit08e57c836699d3e509ad2c9539ac3b70f9df09e4 (patch)
tree7807c40017aef37d6266a787bdda6df85d7e0429 /src/tbf.h
parent341689d6c51d8db73d8691e947c49ede792b6652 (diff)
tbf: Include TBF state in tbf_name output
Sponsored-by: On-Waves ehf
Diffstat (limited to 'src/tbf.h')
-rw-r--r--src/tbf.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/tbf.h b/src/tbf.h
index 71721635..c0f976d4 100644
--- a/src/tbf.h
+++ b/src/tbf.h
@@ -115,6 +115,7 @@ struct gprs_rlcmac_tbf {
bool state_is(enum gprs_rlcmac_tbf_state rhs) const;
bool state_is_not(enum gprs_rlcmac_tbf_state rhs) const;
void set_state(enum gprs_rlcmac_tbf_state new_state);
+ const char *state_name() const;
struct msgb *create_dl_ass(uint32_t fn);
struct msgb *create_ul_ass(uint32_t fn);
@@ -255,6 +256,11 @@ inline bool gprs_rlcmac_tbf::state_is_not(enum gprs_rlcmac_tbf_state rhs) const
const char *tbf_name(gprs_rlcmac_tbf *tbf);
+inline const char *gprs_rlcmac_tbf::state_name() const
+{
+ return tbf_state_name[state];
+}
+
inline void gprs_rlcmac_tbf::set_state(enum gprs_rlcmac_tbf_state new_state)
{
LOGP(DRLCMAC, LOGL_DEBUG, "%s changes state from %s to %s\n",