[PATCH] osmo-bts[master]: cosmetic: avoid direct state assignment

Max gerrit-no-reply at lists.osmocom.org
Wed Oct 11 16:24:59 UTC 2017


Review at  https://gerrit.osmocom.org/4226

cosmetic: avoid direct state assignment

Use oml_mo_state_init() for Abis reset instead of explicit state
assignment.

Change-Id: Idcfbf36746cf988afb2e55741b4a3e1eda70194b
---
M src/common/gsm_data_shared.c
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/26/4226/1

diff --git a/src/common/gsm_data_shared.c b/src/common/gsm_data_shared.c
index c2d196b..193ae97 100644
--- a/src/common/gsm_data_shared.c
+++ b/src/common/gsm_data_shared.c
@@ -33,11 +33,11 @@
 #include <osmocom/core/statistics.h>
 
 #include <osmo-bts/gsm_data.h>
+#include <osmo-bts/oml.h>
 
 void gsm_abis_mo_reset(struct gsm_abis_mo *mo)
 {
-	mo->nm_state.operational = NM_OPSTATE_NULL;
-	mo->nm_state.availability = NM_AVSTATE_POWER_OFF;
+	oml_mo_state_init(mo, NM_OPSTATE_NULL, NM_AVSTATE_POWER_OFF);
 }
 
 static void gsm_mo_init(struct gsm_abis_mo *mo, struct gsm_bts *bts,

-- 
To view, visit https://gerrit.osmocom.org/4226
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Idcfbf36746cf988afb2e55741b4a3e1eda70194b
Gerrit-PatchSet: 1
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Owner: Max <msuraev at sysmocom.de>


More information about the gerrit-log mailing list