bts: Count the number of llc frames that were "scheduled" to be sent
This does not mean that they have been successfully transferred to the SGSN/MS but at least that they have reached a certain point in the message flow.
This commit is contained in:
parent
51e093bd1c
commit
b3d5ee2934
|
@ -60,6 +60,7 @@ static const struct rate_ctr_desc bts_ctr_description[] = {
|
|||
{ "sba.timedout", "SBA Timeout "},
|
||||
{ "llc.timeout", "Timedout Frames "},
|
||||
{ "llc.dropped", "Dropped Frames "},
|
||||
{ "llc.scheduled", "Scheduled Frames "},
|
||||
{ "rach.requests", "RACH requests "},
|
||||
};
|
||||
|
||||
|
|
11
src/bts.h
11
src/bts.h
|
@ -164,6 +164,7 @@ public:
|
|||
CTR_SBA_TIMEDOUT,
|
||||
CTR_LLC_FRAME_TIMEDOUT,
|
||||
CTR_LLC_FRAME_DROPPED,
|
||||
CTR_LLC_FRAME_SCHED,
|
||||
CTR_RACH_REQUESTS,
|
||||
};
|
||||
|
||||
|
@ -207,8 +208,9 @@ public:
|
|||
void sba_allocated();
|
||||
void sba_freed();
|
||||
void sba_timedout();
|
||||
void timedout_frame();
|
||||
void dropped_frame();
|
||||
void llc_timedout_frame();
|
||||
void llc_dropped_frame();
|
||||
void llc_frame_sched();
|
||||
void rach_frame();
|
||||
|
||||
/*
|
||||
|
@ -269,8 +271,9 @@ CREATE_COUNT_INLINE(decode_error, CTR_DECODE_ERRORS)
|
|||
CREATE_COUNT_INLINE(sba_allocated, CTR_SBA_ALLOCATED)
|
||||
CREATE_COUNT_INLINE(sba_freed, CTR_SBA_FREED)
|
||||
CREATE_COUNT_INLINE(sba_timedout, CTR_SBA_TIMEDOUT)
|
||||
CREATE_COUNT_INLINE(timedout_frame, CTR_LLC_FRAME_TIMEDOUT);
|
||||
CREATE_COUNT_INLINE(dropped_frame, CTR_LLC_FRAME_DROPPED);
|
||||
CREATE_COUNT_INLINE(llc_timedout_frame, CTR_LLC_FRAME_TIMEDOUT);
|
||||
CREATE_COUNT_INLINE(llc_dropped_frame, CTR_LLC_FRAME_DROPPED);
|
||||
CREATE_COUNT_INLINE(llc_frame_sched, CTR_LLC_FRAME_SCHED);
|
||||
CREATE_COUNT_INLINE(rach_frame, CTR_RACH_REQUESTS);
|
||||
|
||||
#undef CREATE_COUNT_INLINE
|
||||
|
|
|
@ -60,7 +60,7 @@ void gprs_llc::clear(BTS *bts)
|
|||
struct msgb *msg;
|
||||
|
||||
while ((msg = msgb_dequeue(&queue))) {
|
||||
bts->dropped_frame();
|
||||
bts->llc_dropped_frame();
|
||||
msgb_free(msg);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -101,6 +101,7 @@ int gprs_rlcmac_tbf::append_data(const uint8_t ms_class,
|
|||
#warning "verify that m_llc.index/length is 0... check the state change"
|
||||
bts->tbf_reused();
|
||||
m_llc.put_frame(data, len);
|
||||
bts->llc_frame_sched();
|
||||
/* reset rlc states */
|
||||
memset(&dir.dl, 0, sizeof(dir.dl));
|
||||
/* keep to flags */
|
||||
|
@ -190,6 +191,7 @@ static int tbf_new_dl_assignment(struct gprs_rlcmac_bts *bts,
|
|||
|
||||
/* new TBF, so put first frame */
|
||||
tbf->m_llc.put_frame(data, len);
|
||||
tbf->bts->llc_frame_sched();
|
||||
|
||||
/* Store IMSI for later look-up and PCH retransmission */
|
||||
tbf->assign_imsi(imsi);
|
||||
|
@ -695,7 +697,7 @@ struct msgb *gprs_rlcmac_tbf::llc_dequeue(bssgp_bvc_ctx *bctx)
|
|||
LOGP(DRLCMACDL, LOGL_NOTICE, "%s Discarding LLC PDU "
|
||||
"because lifetime limit reached\n",
|
||||
tbf_name(this));
|
||||
bts->timedout_frame();
|
||||
bts->llc_timedout_frame();
|
||||
frames++;
|
||||
octets += msg->len;
|
||||
msgb_free(msg);
|
||||
|
@ -1083,6 +1085,7 @@ do_resend:
|
|||
LOGP(DRLCMACDL, LOGL_INFO, "- Dequeue next LLC for "
|
||||
"%s (len=%d)\n", tbf_name(this), msg->len);
|
||||
m_llc.put_frame(msg->data, msg->len);
|
||||
bts->llc_frame_sched();
|
||||
msgb_free(msg);
|
||||
}
|
||||
/* if we have more data and we have space left */
|
||||
|
@ -1538,6 +1541,7 @@ int gprs_rlcmac_tbf::snd_dl_ack(uint8_t final, uint8_t ssn, uint8_t *rbb)
|
|||
}
|
||||
#warning "Copy and paste on the sender path"
|
||||
m_llc.put_frame(msg->data, msg->len);
|
||||
bts->llc_frame_sched();
|
||||
msgb_free(msg);
|
||||
|
||||
/* we have a message, so we trigger downlink assignment, and there
|
||||
|
|
Loading…
Reference in New Issue