aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMax <msuraev@sysmocom.de>2019-01-08 15:08:59 +0100
committerMax <msuraev@sysmocom.de>2019-01-21 10:12:47 +0000
commit09273b7f196b0b688552229f1b70c2b6e0806bf2 (patch)
tree1918e2689bd91ef7a300e1073893bcf286b10c2c
parent117fa9d92d0da3d94a51cbfc1cbeb0d5bdcd3767 (diff)
LCLS: constify helper parameters
-rw-r--r--include/osmocom/bsc/osmo_bsc_lcls.h2
-rw-r--r--src/osmo-bsc/osmo_bsc_lcls.c8
2 files changed, 5 insertions, 5 deletions
diff --git a/include/osmocom/bsc/osmo_bsc_lcls.h b/include/osmocom/bsc/osmo_bsc_lcls.h
index 3eaa589..c8b0ebd 100644
--- a/include/osmocom/bsc/osmo_bsc_lcls.h
+++ b/include/osmocom/bsc/osmo_bsc_lcls.h
@@ -29,7 +29,7 @@ enum lcls_event {
LCLS_EV_OTHER_DEAD,
};
-enum gsm0808_lcls_status lcls_get_status(struct gsm_subscriber_connection *conn);
+enum gsm0808_lcls_status lcls_get_status(const struct gsm_subscriber_connection *conn);
void lcls_update_config(struct gsm_subscriber_connection *conn,
const uint8_t *config, const uint8_t *control);
diff --git a/src/osmo-bsc/osmo_bsc_lcls.c b/src/osmo-bsc/osmo_bsc_lcls.c
index 2d5a077..e4459da 100644
--- a/src/osmo-bsc/osmo_bsc_lcls.c
+++ b/src/osmo-bsc/osmo_bsc_lcls.c
@@ -47,7 +47,7 @@ struct value_string lcls_event_names[] = {
* Utility functions
***********************************************************************/
-enum gsm0808_lcls_status lcls_get_status(struct gsm_subscriber_connection *conn)
+enum gsm0808_lcls_status lcls_get_status(const struct gsm_subscriber_connection *conn)
{
if (!conn->lcls.fi)
return GSM0808_LCLS_STS_NA;
@@ -86,7 +86,7 @@ static void lcls_send_notify(struct gsm_subscriber_connection *conn)
}
static struct gsm_subscriber_connection *
-find_conn_with_same_gcr(struct gsm_subscriber_connection *conn_local)
+find_conn_with_same_gcr(const struct gsm_subscriber_connection *conn_local)
{
struct gsm_network *net = conn_local->network;
struct gsm_subscriber_connection *conn_other;
@@ -159,7 +159,7 @@ static int lcls_perform_correlation(struct gsm_subscriber_connection *conn_local
/* Update the connections LCLS configuration and return old/previous configuration.
* \returns (staticallly allocated) old configuration; NULL if new config not supported */
static struct osmo_lcls *update_lcls_cfg_csc(struct gsm_subscriber_connection *conn,
- struct osmo_lcls *new_cfg_csc)
+ const struct osmo_lcls *new_cfg_csc)
{
static struct osmo_lcls old_cfg_csc = { 0 };
old_cfg_csc.config = conn->lcls.config;
@@ -303,7 +303,7 @@ static void lcls_break_local_switching(struct gsm_subscriber_connection *conn)
}
}
-static bool lcls_enable_possible(struct gsm_subscriber_connection *conn)
+static bool lcls_enable_possible(const struct gsm_subscriber_connection *conn)
{
struct gsm_subscriber_connection *other_conn = conn->lcls.other;
OSMO_ASSERT(other_conn);