diff options
Diffstat (limited to 'src/target/firmware/layer1/prim_tch.c')
-rw-r--r-- | src/target/firmware/layer1/prim_tch.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/target/firmware/layer1/prim_tch.c b/src/target/firmware/layer1/prim_tch.c index 2dadaaf4..a8036d2f 100644 --- a/src/target/firmware/layer1/prim_tch.c +++ b/src/target/firmware/layer1/prim_tch.c @@ -338,6 +338,7 @@ static int l1s_tch_resp(__unused uint8_t p1, __unused uint8_t p2, uint16_t p3) struct msgb *msg; struct l1ctl_info_dl *dl; struct l1ctl_traffic_ind *ti; + uint8_t *payload; /* Allocate msgb */ /* FIXME: we actually want all allocation out of L1S! */ @@ -349,15 +350,16 @@ static int l1s_tch_resp(__unused uint8_t p1, __unused uint8_t p2, uint16_t p3) dl = (struct l1ctl_info_dl *) msgb_put(msg, sizeof(*dl)); ti = (struct l1ctl_traffic_ind *) msgb_put(msg, sizeof(*ti)); + payload = (uint8_t *) msgb_put(msg, 33); /* Copy actual data, skipping the information block [0,1,2] */ - dsp_memcpy_from_api(ti->data, &traffic_buf[3], 33, 1); + dsp_memcpy_from_api(payload, &traffic_buf[3], 33, 1); /** * Perform some bit conversations * FIXME: what about other (than FR) codecs? */ - tch_fr_bit_magic(ti, 1); + tch_fr_bit_magic(payload, 1); /* Give message to up layer */ l1_queue_for_l2(msg); |