From a4d255269a7d4e58d2ec0fbb42483495b8c247c9 Mon Sep 17 00:00:00 2001 From: Vadim Yanitskiy Date: Sat, 16 Dec 2017 17:52:31 +0700 Subject: L1CTL/L1CTL_CRYPTO_REQ: add key length and channel info Previously, the L1CTL_CRYPTO_REQ message contained only a ciphering algorithm and actual Kc key to be used. The key length was calculated manually using the MSGB API. Let's avoid manual calculations here, as it may cause unexpected behavior if the message structure is changed. Also, let's fill the UL header with minimal information about a channel, which is going to be encrypted. Change-Id: I5fab079907c5276322d3ec2b46cab81f10c7ed09 --- src/host/layer23/include/osmocom/bb/common/l1ctl.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/host/layer23/include') diff --git a/src/host/layer23/include/osmocom/bb/common/l1ctl.h b/src/host/layer23/include/osmocom/bb/common/l1ctl.h index 3534589d..824b1b03 100644 --- a/src/host/layer23/include/osmocom/bb/common/l1ctl.h +++ b/src/host/layer23/include/osmocom/bb/common/l1ctl.h @@ -16,8 +16,8 @@ int l1ctl_tx_data_req(struct osmocom_ms *ms, struct msgb *msg, uint8_t chan_nr, /* Transmit L1CTL_PARAM_REQ */ int l1ctl_tx_param_req(struct osmocom_ms *ms, uint8_t ta, uint8_t tx_power); -int l1ctl_tx_crypto_req(struct osmocom_ms *ms, uint8_t algo, uint8_t *key, - uint8_t len); +int l1ctl_tx_crypto_req(struct osmocom_ms *ms, uint8_t chan_nr, + uint8_t algo, uint8_t *key, uint8_t len); /* Transmit L1CTL_RACH_REQ */ int l1ctl_tx_rach_req(struct osmocom_ms *ms, uint8_t ra, uint16_t offset, -- cgit v1.2.3