aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorVadim Yanitskiy <vyanitskiy@sysmocom.de>2021-05-07 03:28:04 +0200
committerVadim Yanitskiy <vyanitskiy@sysmocom.de>2021-05-09 02:05:48 +0200
commitb6d3e2c360cac5c73ad310f0049c22968f7b0385 (patch)
tree17fa3ebb6d1a05c809a4aa177e27314742255066 /tests
parent2dda5d835afc1ece6ec0b4b728911ca375f0d308 (diff)
[VAMOS] struct gsm_bts_trx: fix the PHY instance pointer
First of all, there is no reason to use a void pointer because it's always 'struct phy_instance'. Also, no need to encapsulate this pointer into 'role_bts' because there are no other roles in osmo-bts (we used to have shared headers years ago). This commit also fixes a bug in test_sysmobts_auto_band(), where a pointer to 'struct femtol1_hdl' was directly assigned to trx.pinst. Change-Id: I9bd6f0921e0c6bf824d38485486ad78864cbe17e
Diffstat (limited to 'tests')
-rw-r--r--tests/sysmobts/sysmobts_test.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/sysmobts/sysmobts_test.c b/tests/sysmobts/sysmobts_test.c
index 4b01ed7a..d1e9e69f 100644
--- a/tests/sysmobts/sysmobts_test.c
+++ b/tests/sysmobts/sysmobts_test.c
@@ -52,14 +52,17 @@ static void test_sysmobts_auto_band(void)
{
struct gsm_bts bts;
struct gsm_bts_trx trx;
+ struct phy_instance pinst;
struct femtol1_hdl hdl;
int i;
memset(&bts, 0, sizeof(bts));
memset(&trx, 0, sizeof(trx));
+ memset(&pinst, 0, sizeof(pinst));
memset(&hdl, 0, sizeof(hdl));
trx.bts = &bts;
- trx.role_bts.l1h = &hdl;
+ trx.pinst = &pinst;
+ trx.pinst->u.sysmobts.hdl = &hdl;
/* claim to support all hw_info's */
hdl.hw_info.band_support = GSM_BAND_850 | GSM_BAND_900 |