trxcon: cosmetic: s/ts_list/ts/ in struct l1sched_state

Change-Id: I182b2a3ae1dcb1671aaaed9394cdfea34f7966a9
This commit is contained in:
Vadim Yanitskiy 2022-07-16 04:33:03 +07:00
parent 43cd9f270d
commit c4aa60317d
4 changed files with 17 additions and 17 deletions

View File

@ -363,7 +363,7 @@ struct l1sched_state {
/*! Frame callback */
void (*clock_cb)(struct l1sched_state *sched);
/*! List of timeslots maintained by this scheduler */
struct l1sched_ts *ts_list[TRX_TS_COUNT];
struct l1sched_ts *ts[TRX_TS_COUNT];
/*! BSIC value learned from SCH bursts */
uint8_t bsic;
};

View File

@ -482,7 +482,7 @@ static int l1ctl_rx_ccch_mode_req(struct l1ctl_link *l1l, struct msgb *msg)
req->ccch_mode); /* TODO: add value-string for ccch_mode */
/* Make sure that TS0 is allocated and configured */
ts = l1l->sched->ts_list[0];
ts = l1l->sched->ts[0];
if (ts == NULL || ts->mf_layout == NULL) {
LOGP(DL1C, LOGL_ERROR, "TS0 is not configured");
rc = -EINVAL;
@ -659,7 +659,7 @@ static int l1ctl_rx_dm_est_req(struct l1ctl_link *l1l, struct msgb *msg)
/* Configure requested TS */
rc = l1sched_configure_ts(l1l->sched, tn, config);
ts = l1l->sched->ts_list[tn];
ts = l1l->sched->ts[tn];
if (rc) {
rc = -EINVAL;
goto exit;
@ -767,7 +767,7 @@ static int l1ctl_rx_tch_mode_req(struct l1ctl_link *l1l, struct msgb *msg)
/* Iterate over timeslot list */
for (i = 0; i < TRX_TS_COUNT; i++) {
/* Timeslot is not allocated */
ts = l1l->sched->ts_list[i];
ts = l1l->sched->ts[i];
if (ts == NULL)
continue;
@ -813,7 +813,7 @@ static int l1ctl_rx_crypto_req(struct l1ctl_link *l1l, struct msgb *msg)
tn = ul->chan_nr & 0x7;
/* Make sure that required TS is allocated and configured */
ts = l1l->sched->ts_list[tn];
ts = l1l->sched->ts[tn];
if (ts == NULL || ts->mf_layout == NULL) {
LOGP(DL1C, LOGL_ERROR, "TS %u is not configured\n", tn);
rc = -EINVAL;

View File

@ -98,7 +98,7 @@ struct l1sched_ts_prim *l1sched_prim_push(struct l1sched_state *sched,
tn = chan_nr & 0x7;
/* Check whether required timeslot is allocated and configured */
ts = sched->ts_list[tn];
ts = sched->ts[tn];
if (ts == NULL || ts->mf_layout == NULL) {
LOGP(DSCH, LOGL_ERROR, "Timeslot %u isn't configured\n", tn);
return NULL;

View File

@ -78,7 +78,7 @@ static void sched_frame_clck_cb(struct l1sched_state *sched)
};
/* Timeslot is not allocated */
ts = sched->ts_list[i];
ts = sched->ts[i];
if (ts == NULL)
continue;
@ -208,18 +208,18 @@ void l1sched_reset(struct l1sched_state *sched, bool reset_clock)
struct l1sched_ts *l1sched_add_ts(struct l1sched_state *sched, int tn)
{
/* Make sure that ts isn't allocated yet */
if (sched->ts_list[tn] != NULL) {
if (sched->ts[tn] != NULL) {
LOGP(DSCH, LOGL_ERROR, "Timeslot #%u already allocated\n", tn);
return NULL;
}
LOGP(DSCH, LOGL_NOTICE, "Add a new TDMA timeslot #%u\n", tn);
sched->ts_list[tn] = talloc_zero(sched, struct l1sched_ts);
sched->ts_list[tn]->sched = sched;
sched->ts_list[tn]->index = tn;
sched->ts[tn] = talloc_zero(sched, struct l1sched_ts);
sched->ts[tn]->sched = sched;
sched->ts[tn]->index = tn;
return sched->ts_list[tn];
return sched->ts[tn];
}
void l1sched_del_ts(struct l1sched_state *sched, int tn)
@ -228,7 +228,7 @@ void l1sched_del_ts(struct l1sched_state *sched, int tn)
struct l1sched_ts *ts;
/* Find ts in list */
ts = sched->ts_list[tn];
ts = sched->ts[tn];
if (ts == NULL)
return;
@ -247,7 +247,7 @@ void l1sched_del_ts(struct l1sched_state *sched, int tn)
l1sched_prim_flush_queue(&ts->tx_prims);
/* Remove ts from list and free memory */
sched->ts_list[tn] = NULL;
sched->ts[tn] = NULL;
talloc_free(ts);
/* Notify transceiver about that */
@ -265,7 +265,7 @@ int l1sched_configure_ts(struct l1sched_state *sched, int tn,
struct l1sched_ts *ts;
/* Try to find specified ts */
ts = sched->ts_list[tn];
ts = sched->ts[tn];
if (ts != NULL) {
/* Reconfiguration of existing one */
l1sched_reset_ts(sched, tn);
@ -327,7 +327,7 @@ int l1sched_reset_ts(struct l1sched_state *sched, int tn)
struct l1sched_ts *ts;
/* Try to find specified ts */
ts = sched->ts_list[tn];
ts = sched->ts[tn];
if (ts == NULL)
return -EINVAL;
@ -719,7 +719,7 @@ int l1sched_handle_rx_burst(struct l1sched_state *sched, uint8_t tn,
int rc;
/* Check whether required timeslot is allocated and configured */
ts = sched->ts_list[tn];
ts = sched->ts[tn];
if (ts == NULL || ts->mf_layout == NULL) {
LOGP(DSCHD, LOGL_DEBUG, "TDMA timeslot #%u isn't configured, "
"ignoring burst...\n", tn);