trxcon: extended RACH != 11-bit RACH, correct logging messages
Change-Id: I7f977d5d2b68741a230c706f5b16cf307bc267d1
This commit is contained in:
parent
72da0554e8
commit
2881889b87
|
@ -472,7 +472,7 @@ exit:
|
|||
return rc;
|
||||
}
|
||||
|
||||
static int l1ctl_rx_rach_req(struct l1ctl_client *l1c, struct msgb *msg, bool ext)
|
||||
static int l1ctl_rx_rach_req(struct l1ctl_client *l1c, struct msgb *msg, bool is_11bit)
|
||||
{
|
||||
struct trxcon_param_tx_access_burst_req req;
|
||||
struct trxcon_inst *trxcon = l1c->priv;
|
||||
|
@ -480,8 +480,7 @@ static int l1ctl_rx_rach_req(struct l1ctl_client *l1c, struct msgb *msg, bool ex
|
|||
|
||||
ul = (struct l1ctl_info_ul *) msg->l1h;
|
||||
|
||||
/* Is it extended (11-bit) RACH or not? */
|
||||
if (ext) {
|
||||
if (is_11bit) {
|
||||
const struct l1ctl_ext_rach_req *rr = (void *)ul->payload;
|
||||
|
||||
req = (struct trxcon_param_tx_access_burst_req) {
|
||||
|
@ -492,7 +491,7 @@ static int l1ctl_rx_rach_req(struct l1ctl_client *l1c, struct msgb *msg, bool ex
|
|||
};
|
||||
|
||||
LOGPFSMSL(trxcon->fi, DL1C, LOGL_NOTICE,
|
||||
"Received extended (11-bit) RACH request "
|
||||
"Received 11-bit RACH request "
|
||||
"(offset=%u, synch_seq=%u, ra11=0x%02hx)\n",
|
||||
req.offset, req.synch_seq, req.ra);
|
||||
} else {
|
||||
|
@ -504,7 +503,7 @@ static int l1ctl_rx_rach_req(struct l1ctl_client *l1c, struct msgb *msg, bool ex
|
|||
};
|
||||
|
||||
LOGPFSMSL(trxcon->fi, DL1C, LOGL_NOTICE,
|
||||
"Received regular (8-bit) RACH request "
|
||||
"Received 8-bit RACH request "
|
||||
"(offset=%u, ra=0x%02x)\n", req.offset, req.ra);
|
||||
}
|
||||
|
||||
|
|
|
@ -84,7 +84,6 @@ int tx_rach_fn(struct l1sched_lchan_state *lchan,
|
|||
if (rach->offset-- > 0)
|
||||
return 0;
|
||||
|
||||
/* Is it extended (11-bit) RACH or not? */
|
||||
if (L1SCHED_PRIM_IS_RACH11(lchan->prim)) {
|
||||
/* Check requested synch. sequence */
|
||||
if (rach->synch_seq >= RACH_SYNCH_SEQ_NUM) {
|
||||
|
@ -97,11 +96,11 @@ int tx_rach_fn(struct l1sched_lchan_state *lchan,
|
|||
return -ENOTSUP;
|
||||
}
|
||||
|
||||
/* Encode extended (11-bit) payload */
|
||||
/* Encode 11-bit payload */
|
||||
rc = gsm0503_rach_ext_encode(payload, rach->ra, bsic, true);
|
||||
if (rc) {
|
||||
LOGP_LCHAND(lchan, LOGL_ERROR,
|
||||
"Could not encode extended RACH burst (ra=%u bsic=%u)\n",
|
||||
"Could not encode 11-bit RACH burst (ra=%u bsic=%u)\n",
|
||||
rach->ra, bsic);
|
||||
|
||||
/* Forget this primitive */
|
||||
|
@ -111,7 +110,7 @@ int tx_rach_fn(struct l1sched_lchan_state *lchan,
|
|||
} else if (L1SCHED_PRIM_IS_RACH8(lchan->prim)) {
|
||||
rach->synch_seq = RACH_SYNCH_SEQ_TS0;
|
||||
|
||||
/* Encode regular (8-bit) payload */
|
||||
/* Encode 8-bit payload */
|
||||
rc = gsm0503_rach_ext_encode(payload, rach->ra, bsic, false);
|
||||
if (rc) {
|
||||
LOGP_LCHAND(lchan, LOGL_ERROR,
|
||||
|
@ -147,8 +146,8 @@ int tx_rach_fn(struct l1sched_lchan_state *lchan,
|
|||
memset(burst_ptr, 0, br->burst + GSM_BURST_LEN - burst_ptr);
|
||||
br->burst_len = GSM_BURST_LEN;
|
||||
|
||||
LOGP_LCHAND(lchan, LOGL_NOTICE, "Scheduled %s RACH (%s) at fn=%u\n",
|
||||
L1SCHED_PRIM_IS_RACH11(lchan->prim) ? "extended (11-bit)" : "regular (8-bit)",
|
||||
LOGP_LCHAND(lchan, LOGL_NOTICE, "Scheduled %s-bit RACH (%s) at fn=%u\n",
|
||||
L1SCHED_PRIM_IS_RACH11(lchan->prim) ? "11" : "8",
|
||||
get_value_string(rach_synch_seq_names, rach->synch_seq), br->fn);
|
||||
|
||||
/* Confirm RACH request */
|
||||
|
|
Loading…
Reference in New Issue