lists.osmocom.org
Sign In Sign Up
Manage this list Sign In Sign Up

Keyboard Shortcuts

Thread View

  • j: Next unread message
  • k: Previous unread message
  • j a: Jump to all threads
  • j l: Jump to MailingList overview

gerrit-log

Thread Start a new thread
Download
Threads by month
  • ----- 2026 -----
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2025 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2024 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2023 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2022 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
gerrit-log@lists.osmocom.org

November 2022

  • 2 participants
  • 2503 discussions
Change in osmo-hnodeb[master]: configure: don't turn some warnings into errors
by fixeria 10 Nov '22

10 Nov '22
Attention is currently required from: osmith. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-hnodeb/+/26213 ) Change subject: configure: don't turn some warnings into errors ...................................................................... Patch Set 1: (1 comment) Patchset: PS1: Can we still rebase this patch on top of the master branch and get it merged? -- To view, visit https://gerrit.osmocom.org/c/osmo-hnodeb/+/26213 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-hnodeb Gerrit-Branch: master Gerrit-Change-Id: I783035fcded73f9c3938c4110ccb84eddc36a274 Gerrit-Change-Number: 26213 Gerrit-PatchSet: 1 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-CC: msuraev <msuraev(a)sysmocom.de> Gerrit-Attention: osmith <osmith(a)sysmocom.de> Gerrit-Comment-Date: Thu, 10 Nov 2022 16:14:51 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment
1 0
0 0
Change in osmocom-bb[master]: trxcon: fixup: handle DATA.cnf/TRAFFIC.cnf via TRXCON_EV_TX_DATA_CNF
by osmith 10 Nov '22

10 Nov '22
osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30056 ) Change subject: trxcon: fixup: handle DATA.cnf/TRAFFIC.cnf via TRXCON_EV_TX_DATA_CNF ...................................................................... Patch Set 2: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30056 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: Ifc538f940571172fa237ecb7000f3cfea3655edc Gerrit-Change-Number: 30056 Gerrit-PatchSet: 2 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Comment-Date: Thu, 10 Nov 2022 16:10:55 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmocom-bb[master]: trxcon: configure.ac: call LT_INIT after setting CFLAGS
by fixeria 10 Nov '22

10 Nov '22
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30060 ) Change subject: trxcon: configure.ac: call LT_INIT after setting CFLAGS ...................................................................... trxcon: configure.ac: call LT_INIT after setting CFLAGS If $CFLAGS is empty prior to calling the LT_INIT, this macro will set $CFLAGS to "-g -O2". We don't want implicit flags out of nowhere, so let's simply move the invocation of LT_INIT down below. Change-Id: I8d8eb1e3428ffcb84ddd53230fada39328337d15 Related: OS#5749 --- M src/host/trxcon/configure.ac 1 file changed, 3 insertions(+), 1 deletion(-) Approvals: laforge: Looks good to me, but someone else must approve fixeria: Looks good to me, approved Hoernchen: Looks good to me, but someone else must approve Jenkins Builder: Verified diff --git a/src/host/trxcon/configure.ac b/src/host/trxcon/configure.ac index 554caab..6508689 100644 --- a/src/host/trxcon/configure.ac +++ b/src/host/trxcon/configure.ac @@ -1,7 +1,6 @@ dnl Process this file with autoconf to produce a configure script AC_INIT([trxcon], [0.0.0]) AM_INIT_AUTOMAKE -LT_INIT CFLAGS="$CFLAGS -std=gnu11" @@ -21,6 +20,9 @@ dnl checks for header files AC_HEADER_STDC +dnl init libtool +LT_INIT + AC_ARG_ENABLE(sanitize, [AS_HELP_STRING( [--enable-sanitize], -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30060 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I8d8eb1e3428ffcb84ddd53230fada39328337d15 Gerrit-Change-Number: 30060 Gerrit-PatchSet: 2 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Hoernchen <ewild(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-MessageType: merged
1 0
0 0
Change in osmocom-bb[master]: trxcon: fixup: handle DATA.cnf/TRAFFIC.cnf via TRXCON_EV_TX_DATA_CNF
by fixeria 10 Nov '22

10 Nov '22
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30056 ) Change subject: trxcon: fixup: handle DATA.cnf/TRAFFIC.cnf via TRXCON_EV_TX_DATA_CNF ...................................................................... trxcon: fixup: handle DATA.cnf/TRAFFIC.cnf via TRXCON_EV_TX_DATA_CNF Found this problem while trying to build with "-flto": ../include/osmocom/bb/trxcon/l1ctl.h:21:5: error: type of 'l1ctl_tx_dt_conf' does not match original declaration [-Werror=lto-type-mismatch] 21 | int l1ctl_tx_dt_conf(struct l1ctl_client *l1c, | ^ l1ctl.c:288:5: note: type mismatch in parameter 2 288 | int l1ctl_tx_dt_conf(struct l1ctl_client *l1c, bool traffic, | ^ The trxcon_fsm is passing only two arguments to l1ctl_tx_dt_conf(). The 'traffic' flag is included in struct trxcon_param_tx_data_cnf, so the 2rd argument is not needed and should have been removed. Change-Id: Ifc538f940571172fa237ecb7000f3cfea3655edc --- M src/host/trxcon/src/l1ctl.c 1 file changed, 2 insertions(+), 3 deletions(-) Approvals: laforge: Looks good to me, but someone else must approve fixeria: Looks good to me, approved Jenkins Builder: Verified diff --git a/src/host/trxcon/src/l1ctl.c b/src/host/trxcon/src/l1ctl.c index a483bbb..4923899 100644 --- a/src/host/trxcon/src/l1ctl.c +++ b/src/host/trxcon/src/l1ctl.c @@ -286,13 +286,12 @@ /** * Handles both L1CTL_DATA_CONF and L1CTL_TRAFFIC_CONF. */ -int l1ctl_tx_dt_conf(struct l1ctl_client *l1c, bool traffic, +int l1ctl_tx_dt_conf(struct l1ctl_client *l1c, struct trxcon_param_tx_data_cnf *cnf) { struct msgb *msg; - msg = l1ctl_alloc_msg(traffic ? - L1CTL_TRAFFIC_CONF : L1CTL_DATA_CONF); + msg = l1ctl_alloc_msg(cnf->traffic ? L1CTL_TRAFFIC_CONF : L1CTL_DATA_CONF); if (msg == NULL) return -ENOMEM; -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30056 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: Ifc538f940571172fa237ecb7000f3cfea3655edc Gerrit-Change-Number: 30056 Gerrit-PatchSet: 2 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
Change in osmocom-bb[master]: trxcon: fixup: handle DATA.cnf/TRAFFIC.cnf via TRXCON_EV_TX_DATA_CNF
by fixeria 10 Nov '22

10 Nov '22
Attention is currently required from: osmith. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30056 ) Change subject: trxcon: fixup: handle DATA.cnf/TRAFFIC.cnf via TRXCON_EV_TX_DATA_CNF ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30056 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: Ifc538f940571172fa237ecb7000f3cfea3655edc Gerrit-Change-Number: 30056 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Attention: osmith <osmith(a)sysmocom.de> Gerrit-Comment-Date: Thu, 10 Nov 2022 16:10:00 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmocom-bb[master]: trxcon: configure.ac: call LT_INIT after setting CFLAGS
by fixeria 10 Nov '22

10 Nov '22
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30060 ) Change subject: trxcon: configure.ac: call LT_INIT after setting CFLAGS ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30060 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I8d8eb1e3428ffcb84ddd53230fada39328337d15 Gerrit-Change-Number: 30060 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Hoernchen <ewild(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Comment-Date: Thu, 10 Nov 2022 16:09:41 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmocom-bb[master]: trxcon: move the trxcon_fsm related stuff into its own header
by fixeria 10 Nov '22

10 Nov '22
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30030 ) Change subject: trxcon: move the trxcon_fsm related stuff into its own header ...................................................................... trxcon: move the trxcon_fsm related stuff into its own header Change-Id: I32097b27f8de8d2b765a4399ad5fd3a1bdba85f4 Related: OS#5599 --- M src/host/trxcon/include/osmocom/bb/trxcon/trxcon.h A src/host/trxcon/include/osmocom/bb/trxcon/trxcon_fsm.h M src/host/trxcon/src/l1ctl.c M src/host/trxcon/src/trxcon.c M src/host/trxcon/src/trxcon_fsm.c 5 files changed, 169 insertions(+), 162 deletions(-) Approvals: Jenkins Builder: Verified laforge: Looks good to me, but someone else must approve osmith: Looks good to me, but someone else must approve fixeria: Looks good to me, approved diff --git a/src/host/trxcon/include/osmocom/bb/trxcon/trxcon.h b/src/host/trxcon/include/osmocom/bb/trxcon/trxcon.h index b553fe4..ad00a05 100644 --- a/src/host/trxcon/include/osmocom/bb/trxcon/trxcon.h +++ b/src/host/trxcon/include/osmocom/bb/trxcon/trxcon.h @@ -1,171 +1,10 @@ #pragma once #include <stdint.h> -#include <stdbool.h> -#include <osmocom/core/fsm.h> - +struct osmo_fsm_inst; struct l1sched_state; -extern struct osmo_fsm trxcon_fsm_def; - -enum trxcon_fsm_states { - TRXCON_ST_RESET, - TRXCON_ST_FULL_POWER_SCAN, - TRXCON_ST_FBSB_SEARCH, - TRXCON_ST_BCCH_CCCH, - TRXCON_ST_DEDICATED, - TRXCON_ST_PACKET_DATA, -}; - -enum trxcon_fsm_events { - TRXCON_EV_PHYIF_FAILURE, - TRXCON_EV_L2IF_FAILURE, - TRXCON_EV_RESET_FULL_REQ, - TRXCON_EV_RESET_SCHED_REQ, - TRXCON_EV_FULL_POWER_SCAN_REQ, - TRXCON_EV_FULL_POWER_SCAN_RES, - TRXCON_EV_FBSB_SEARCH_REQ, - TRXCON_EV_FBSB_SEARCH_RES, - TRXCON_EV_SET_CCCH_MODE_REQ, - TRXCON_EV_SET_TCH_MODE_REQ, - TRXCON_EV_SET_PHY_CONFIG_REQ, - TRXCON_EV_TX_ACCESS_BURST_REQ, - TRXCON_EV_TX_ACCESS_BURST_CNF, - TRXCON_EV_UPDATE_SACCH_CACHE_REQ, - TRXCON_EV_DEDICATED_ESTABLISH_REQ, - TRXCON_EV_DEDICATED_RELEASE_REQ, - TRXCON_EV_TX_DATA_REQ, - TRXCON_EV_TX_DATA_CNF, - TRXCON_EV_RX_DATA_IND, - TRXCON_EV_CRYPTO_REQ, -}; - -/* param of TRXCON_EV_FULL_POWER_SCAN_REQ */ -struct trxcon_param_full_power_scan_req { - uint16_t band_arfcn_start; - uint16_t band_arfcn_stop; -}; - -/* param of TRXCON_EV_FULL_POWER_SCAN_RES */ -struct trxcon_param_full_power_scan_res { - bool last_result; - uint16_t band_arfcn; - int dbm; -}; - -/* param of TRXCON_EV_FBSB_SEARCH_REQ */ -struct trxcon_param_fbsb_search_req { - uint16_t band_arfcn; - uint16_t timeout_ms; - uint8_t pchan_config; -}; - -/* param of TRXCON_EV_SET_{CCCH,TCH}_MODE_REQ */ -struct trxcon_param_set_ccch_tch_mode_req { - uint8_t mode; - struct { - uint8_t start_codec; - uint8_t codecs_bitmask; - } amr; - bool applied; -}; - -/* param of TRXCON_EV_SET_PHY_CONFIG_REQ */ -struct trxcon_param_set_phy_config_req { - enum { - TRXCON_PHY_CFGT_PCHAN_COMB, - TRXCON_PHY_CFGT_TX_PARAMS, - } type; - union { - struct { - uint8_t tn; - uint8_t pchan; - } pchan_comb; - struct { - uint8_t timing_advance; - uint8_t tx_power; - } tx_params; - }; -}; - -/* param of TRXCON_EV_TX_DATA_REQ */ -struct trxcon_param_tx_data_req { - bool traffic; - uint8_t chan_nr; - uint8_t link_id; - size_t data_len; - const uint8_t *data; -}; - -/* param of TRXCON_EV_TX_DATA_CNF */ -struct trxcon_param_tx_data_cnf { - bool traffic; - uint8_t chan_nr; - uint8_t link_id; - uint16_t band_arfcn; - uint32_t frame_nr; -}; - -/* param of TRXCON_EV_RX_DATA_IND */ -struct trxcon_param_rx_data_ind { - bool traffic; - uint8_t chan_nr; - uint8_t link_id; - uint16_t band_arfcn; - uint32_t frame_nr; - int16_t toa256; - int8_t rssi; - int n_errors; - int n_bits_total; - size_t data_len; - const uint8_t *data; -}; - -/* param of TRXCON_EV_TX_ACCESS_BURST_REQ */ -struct trxcon_param_tx_access_burst_req { - uint8_t chan_nr; - uint8_t link_id; - uint8_t offset; - uint8_t synch_seq; - uint16_t ra; - bool is_11bit; -}; - -/* param of TRXCON_EV_TX_ACCESS_BURST_CNF */ -struct trxcon_param_tx_access_burst_cnf { - uint16_t band_arfcn; - uint32_t frame_nr; -}; - -/* param of TRXCON_EV_DEDICATED_ESTABLISH_REQ */ -struct trxcon_param_dedicated_establish_req { - uint8_t chan_nr; - uint8_t tch_mode; - uint8_t tsc; - - bool hopping; - union { - struct { /* hopping=false */ - uint16_t band_arfcn; - } h0; - struct { /* hopping=true */ - uint8_t hsn; - uint8_t maio; - uint8_t n; - uint16_t ma[64]; - } h1; - }; -}; - -/* param of TRXCON_EV_CRYPTO_REQ */ -struct trxcon_param_crypto_req { - uint8_t chan_nr; - uint8_t a5_algo; /* 0 is A5/0 */ - uint8_t key_len; - const uint8_t *key; -}; - struct trxcon_inst { struct osmo_fsm_inst *fi; unsigned int id; diff --git a/src/host/trxcon/include/osmocom/bb/trxcon/trxcon_fsm.h b/src/host/trxcon/include/osmocom/bb/trxcon/trxcon_fsm.h new file mode 100644 index 0000000..e1ab84d --- /dev/null +++ b/src/host/trxcon/include/osmocom/bb/trxcon/trxcon_fsm.h @@ -0,0 +1,165 @@ +#pragma once + +#include <stdint.h> +#include <stdbool.h> + +#include <osmocom/core/fsm.h> + +extern struct osmo_fsm trxcon_fsm_def; + +enum trxcon_fsm_states { + TRXCON_ST_RESET, + TRXCON_ST_FULL_POWER_SCAN, + TRXCON_ST_FBSB_SEARCH, + TRXCON_ST_BCCH_CCCH, + TRXCON_ST_DEDICATED, + TRXCON_ST_PACKET_DATA, +}; + +enum trxcon_fsm_events { + TRXCON_EV_PHYIF_FAILURE, + TRXCON_EV_L2IF_FAILURE, + TRXCON_EV_RESET_FULL_REQ, + TRXCON_EV_RESET_SCHED_REQ, + TRXCON_EV_FULL_POWER_SCAN_REQ, + TRXCON_EV_FULL_POWER_SCAN_RES, + TRXCON_EV_FBSB_SEARCH_REQ, + TRXCON_EV_FBSB_SEARCH_RES, + TRXCON_EV_SET_CCCH_MODE_REQ, + TRXCON_EV_SET_TCH_MODE_REQ, + TRXCON_EV_SET_PHY_CONFIG_REQ, + TRXCON_EV_TX_ACCESS_BURST_REQ, + TRXCON_EV_TX_ACCESS_BURST_CNF, + TRXCON_EV_UPDATE_SACCH_CACHE_REQ, + TRXCON_EV_DEDICATED_ESTABLISH_REQ, + TRXCON_EV_DEDICATED_RELEASE_REQ, + TRXCON_EV_TX_DATA_REQ, + TRXCON_EV_TX_DATA_CNF, + TRXCON_EV_RX_DATA_IND, + TRXCON_EV_CRYPTO_REQ, +}; + +/* param of TRXCON_EV_FULL_POWER_SCAN_REQ */ +struct trxcon_param_full_power_scan_req { + uint16_t band_arfcn_start; + uint16_t band_arfcn_stop; +}; + +/* param of TRXCON_EV_FULL_POWER_SCAN_RES */ +struct trxcon_param_full_power_scan_res { + bool last_result; + uint16_t band_arfcn; + int dbm; +}; + +/* param of TRXCON_EV_FBSB_SEARCH_REQ */ +struct trxcon_param_fbsb_search_req { + uint16_t band_arfcn; + uint16_t timeout_ms; + uint8_t pchan_config; +}; + +/* param of TRXCON_EV_SET_{CCCH,TCH}_MODE_REQ */ +struct trxcon_param_set_ccch_tch_mode_req { + uint8_t mode; + struct { + uint8_t start_codec; + uint8_t codecs_bitmask; + } amr; + bool applied; +}; + +/* param of TRXCON_EV_SET_PHY_CONFIG_REQ */ +struct trxcon_param_set_phy_config_req { + enum { + TRXCON_PHY_CFGT_PCHAN_COMB, + TRXCON_PHY_CFGT_TX_PARAMS, + } type; + union { + struct { + uint8_t tn; + uint8_t pchan; + } pchan_comb; + struct { + uint8_t timing_advance; + uint8_t tx_power; + } tx_params; + }; +}; + +/* param of TRXCON_EV_TX_DATA_REQ */ +struct trxcon_param_tx_data_req { + bool traffic; + uint8_t chan_nr; + uint8_t link_id; + size_t data_len; + const uint8_t *data; +}; + +/* param of TRXCON_EV_TX_DATA_CNF */ +struct trxcon_param_tx_data_cnf { + bool traffic; + uint8_t chan_nr; + uint8_t link_id; + uint16_t band_arfcn; + uint32_t frame_nr; +}; + +/* param of TRXCON_EV_RX_DATA_IND */ +struct trxcon_param_rx_data_ind { + bool traffic; + uint8_t chan_nr; + uint8_t link_id; + uint16_t band_arfcn; + uint32_t frame_nr; + int16_t toa256; + int8_t rssi; + int n_errors; + int n_bits_total; + size_t data_len; + const uint8_t *data; +}; + +/* param of TRXCON_EV_TX_ACCESS_BURST_REQ */ +struct trxcon_param_tx_access_burst_req { + uint8_t chan_nr; + uint8_t link_id; + uint8_t offset; + uint8_t synch_seq; + uint16_t ra; + bool is_11bit; +}; + +/* param of TRXCON_EV_TX_ACCESS_BURST_CNF */ +struct trxcon_param_tx_access_burst_cnf { + uint16_t band_arfcn; + uint32_t frame_nr; +}; + +/* param of TRXCON_EV_DEDICATED_ESTABLISH_REQ */ +struct trxcon_param_dedicated_establish_req { + uint8_t chan_nr; + uint8_t tch_mode; + uint8_t tsc; + + bool hopping; + union { + struct { /* hopping=false */ + uint16_t band_arfcn; + } h0; + struct { /* hopping=true */ + uint8_t hsn; + uint8_t maio; + uint8_t n; + uint16_t ma[64]; + } h1; + }; +}; + +/* param of TRXCON_EV_CRYPTO_REQ */ +struct trxcon_param_crypto_req { + uint8_t chan_nr; + uint8_t a5_algo; /* 0 is A5/0 */ + uint8_t key_len; + const uint8_t *key; +}; diff --git a/src/host/trxcon/src/l1ctl.c b/src/host/trxcon/src/l1ctl.c index 890e4d2..a483bbb 100644 --- a/src/host/trxcon/src/l1ctl.c +++ b/src/host/trxcon/src/l1ctl.c @@ -41,6 +41,7 @@ #include <osmocom/bb/trxcon/l1ctl_server.h> #include <osmocom/bb/trxcon/l1ctl_proto.h> #include <osmocom/bb/trxcon/trxcon.h> +#include <osmocom/bb/trxcon/trxcon_fsm.h> static const char *arfcn2band_name(uint16_t arfcn) { diff --git a/src/host/trxcon/src/trxcon.c b/src/host/trxcon/src/trxcon.c index 306a8fe..4eea55a 100644 --- a/src/host/trxcon/src/trxcon.c +++ b/src/host/trxcon/src/trxcon.c @@ -42,6 +42,7 @@ #include <osmocom/gsm/gsm_utils.h> #include <osmocom/bb/trxcon/trxcon.h> +#include <osmocom/bb/trxcon/trxcon_fsm.h> #include <osmocom/bb/trxcon/phyif.h> #include <osmocom/bb/trxcon/trx_if.h> #include <osmocom/bb/trxcon/logging.h> diff --git a/src/host/trxcon/src/trxcon_fsm.c b/src/host/trxcon/src/trxcon_fsm.c index f936449..5268bc6 100644 --- a/src/host/trxcon/src/trxcon_fsm.c +++ b/src/host/trxcon/src/trxcon_fsm.c @@ -28,6 +28,7 @@ #include <osmocom/core/talloc.h> #include <osmocom/bb/trxcon/trxcon.h> +#include <osmocom/bb/trxcon/trxcon_fsm.h> #include <osmocom/bb/trxcon/phyif.h> #include <osmocom/bb/trxcon/logging.h> #include <osmocom/bb/trxcon/l1ctl.h> -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30030 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I32097b27f8de8d2b765a4399ad5fd3a1bdba85f4 Gerrit-Change-Number: 30030 Gerrit-PatchSet: 2 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
Change in osmocom-bb[master]: trxcon: add handle_full_power_scan_req(), reduce code duplication
by fixeria 10 Nov '22

10 Nov '22
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30053 ) Change subject: trxcon: add handle_full_power_scan_req(), reduce code duplication ...................................................................... trxcon: add handle_full_power_scan_req(), reduce code duplication Allow TRXCON_ST_{FULL_POWER_SCAN->FULL_POWER_SCAN} state transition so that we can call osmo_fsm_inst_state_chg() unconditionally. Change-Id: I1ea69561a2d3cf73009c6244b1d0f090d744d7b2 Related: OS#5599 --- M src/host/trxcon/src/trxcon_fsm.c 1 file changed, 20 insertions(+), 26 deletions(-) Approvals: Jenkins Builder: Verified laforge: Looks good to me, but someone else must approve osmith: Looks good to me, but someone else must approve fixeria: Looks good to me, approved diff --git a/src/host/trxcon/src/trxcon_fsm.c b/src/host/trxcon/src/trxcon_fsm.c index 5268bc6..38b95ec 100644 --- a/src/host/trxcon/src/trxcon_fsm.c +++ b/src/host/trxcon/src/trxcon_fsm.c @@ -121,6 +121,22 @@ } } +static void handle_full_power_scan_req(struct osmo_fsm_inst *fi, + const struct trxcon_param_full_power_scan_req *req) +{ + struct trxcon_inst *trxcon = fi->priv; + const struct phyif_cmd phycmd = { + .type = PHYIF_CMDT_MEASURE, + .param.measure = { + .band_arfcn_start = req->band_arfcn_start, + .band_arfcn_stop = req->band_arfcn_stop, + }, + }; + + osmo_fsm_inst_state_chg(fi, TRXCON_ST_FULL_POWER_SCAN, 0, 0); /* TODO: timeout */ + phyif_handle_cmd(trxcon->phyif, &phycmd); +} + static void trxcon_st_reset_action(struct osmo_fsm_inst *fi, uint32_t event, void *data) { @@ -156,20 +172,8 @@ break; } case TRXCON_EV_FULL_POWER_SCAN_REQ: - { - const struct trxcon_param_full_power_scan_req *req = data; - const struct phyif_cmd phycmd = { - .type = PHYIF_CMDT_MEASURE, - .param.measure = { - .band_arfcn_start = req->band_arfcn_start, - .band_arfcn_stop = req->band_arfcn_stop, - }, - }; - - osmo_fsm_inst_state_chg(fi, TRXCON_ST_FULL_POWER_SCAN, 0, 0); /* TODO: timeout */ - phyif_handle_cmd(trxcon->phyif, &phycmd); + handle_full_power_scan_req(fi, (const struct trxcon_param_full_power_scan_req *)data); break; - } default: OSMO_ASSERT(0); } @@ -189,19 +193,8 @@ break; } case TRXCON_EV_FULL_POWER_SCAN_REQ: - { - const struct trxcon_param_full_power_scan_req *req = data; - const struct phyif_cmd phycmd = { - .type = PHYIF_CMDT_MEASURE, - .param.measure = { - .band_arfcn_start = req->band_arfcn_start, - .band_arfcn_stop = req->band_arfcn_stop, - }, - }; - - phyif_handle_cmd(trxcon->phyif, &phycmd); + handle_full_power_scan_req(fi, (const struct trxcon_param_full_power_scan_req *)data); break; - } default: OSMO_ASSERT(0); } @@ -528,7 +521,8 @@ }, [TRXCON_ST_FULL_POWER_SCAN] = { .name = "FULL_POWER_SCAN", - .out_state_mask = S(TRXCON_ST_RESET), + .out_state_mask = S(TRXCON_ST_RESET) + | S(TRXCON_ST_FULL_POWER_SCAN), .in_event_mask = S(TRXCON_EV_FULL_POWER_SCAN_RES) | S(TRXCON_EV_FULL_POWER_SCAN_REQ), .action = &trxcon_st_full_power_scan_action, -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30053 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I1ea69561a2d3cf73009c6244b1d0f090d744d7b2 Gerrit-Change-Number: 30053 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-MessageType: merged
1 0
0 0
Change in osmocom-bb[master]: trxcon: add missing imports to trxcon.h
by fixeria 10 Nov '22

10 Nov '22
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30052 ) Change subject: trxcon: add missing imports to trxcon.h ...................................................................... trxcon: add missing imports to trxcon.h Change-Id: I0fa507e80a638ca7ed2ff421303e9722b33e20ea Related: OS#5599 --- M src/host/trxcon/include/osmocom/bb/trxcon/trxcon.h 1 file changed, 5 insertions(+), 0 deletions(-) Approvals: Jenkins Builder: Verified laforge: Looks good to me, approved diff --git a/src/host/trxcon/include/osmocom/bb/trxcon/trxcon.h b/src/host/trxcon/include/osmocom/bb/trxcon/trxcon.h index 117f3fd..b553fe4 100644 --- a/src/host/trxcon/include/osmocom/bb/trxcon/trxcon.h +++ b/src/host/trxcon/include/osmocom/bb/trxcon/trxcon.h @@ -1,5 +1,10 @@ #pragma once +#include <stdint.h> +#include <stdbool.h> + +#include <osmocom/core/fsm.h> + struct l1sched_state; extern struct osmo_fsm trxcon_fsm_def; -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30052 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I0fa507e80a638ca7ed2ff421303e9722b33e20ea Gerrit-Change-Number: 30052 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-MessageType: merged
1 0
0 0
Change in osmocom-bb[master]: trxcon: add handle_full_power_scan_req(), reduce code duplication
by fixeria 10 Nov '22

10 Nov '22
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/30053 ) Change subject: trxcon: add handle_full_power_scan_req(), reduce code duplication ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/30053 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I1ea69561a2d3cf73009c6244b1d0f090d744d7b2 Gerrit-Change-Number: 30053 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Comment-Date: Thu, 10 Nov 2022 16:07:43 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 173
  • 174
  • 175
  • 176
  • 177
  • 178
  • 179
  • ...
  • 251
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.