aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Sperling <ssperling@sysmocom.de>2018-02-06 14:44:54 +0100
committerStefan Sperling <ssperling@sysmocom.de>2018-02-06 14:44:54 +0100
commit6eb96ddde4b3b5bd7f42543a2ec4c8fc9f70a063 (patch)
tree6aadeb27c564efc95930df0169ac9e3054869b2b
parent81dc9e74558ac9c62ce9a17c415963cdcaf1ecec (diff)
Add data structure definitions for Access Control Class ramping.
-rw-r--r--include/osmocom/bsc/gsm_data_shared.h53
1 files changed, 53 insertions, 0 deletions
diff --git a/include/osmocom/bsc/gsm_data_shared.h b/include/osmocom/bsc/gsm_data_shared.h
index e3e138957..aa532cec3 100644
--- a/include/osmocom/bsc/gsm_data_shared.h
+++ b/include/osmocom/bsc/gsm_data_shared.h
@@ -578,6 +578,56 @@ struct load_counter {
unsigned int used;
};
+
+/*
+ * Access control class (ACC) ramping is used to slowly make the cell available to
+ * an increasing number of MS. This avoids overload at startup time in cases where
+ * a lot of MS would discover the new cell and try to connect to it all at once.
+ */
+
+enum bts_acc_ramp_step_size {
+ BTS_ACC_RAMP_STEP_SIZE_MIN = 1, /* allow at most 1 new ACC per ramp step */
+ BTS_ACC_RAMP_STEP_SIZE_DEFAULT = BTS_ACC_RAMP_STEP_SIZE_MIN,
+ BTS_ACC_RAMP_STEP_SIZE_MAX = 10, /* allow all ACC in one step (disables ramping) */
+};
+
+enum bts_acc_ramp_step_interval {
+ BTS_ACC_RAMP_STEP_INTERVAL_MIN = 1, /* 1 second */
+ BTS_ACC_RAMP_STEP_INTERVAL_DEFAULT = 60, /* 1 minute */
+ BTS_ACC_RAMP_STEP_INTERVAL_MAX = 300, /* 5 minutes */
+};
+
+struct bts_acc_ramp {
+ /*
+ * Bitmasks which keep track of access control classes that are currently
+ * denied access to this BTS. These masks modulate bits from octets 2 and 3
+ * of the RACH Control Parameters (see 3GPP 44.018 10.5.2.29).
+ * While a bit in these masks is set, the corresponding ACC is barred.
+ * Note that t2 contains bits for classes 11-15 which should always be allowed,
+ * and a bit which denies emergency calls for all ACCs from 0-9 inclusive.
+ * Ramping is only concerned with those bits which control access for ACCs 0-9.
+ */
+ uint8_t barred_t2;
+ uint8_t barred_t3;
+
+ /*
+ * This controls the maximum number of ACCs to allow per ramping step (1 - 10).
+ * The compile-time default value is BTS_ACC_RAMP_STEP_SIZE_DEFAULT.
+ * This value can be changed by VTY configuration.
+ * A value of BTS_ACC_RAMP_STEP_SIZE_MAX effectively disables ramping.
+ */
+ enum bts_acc_ramp_step_size step_size;
+
+ /*
+ * Ramping step interval in seconds.
+ * This value depends on the current BTS channel load average, unless
+ * it has been overriden by VTY configuration.
+ */
+ unsigned int step_interval_sec;
+ bool step_interval_is_fixed;
+ struct osmo_timer_list step_timer;
+};
+
/* One BTS */
struct gsm_bts {
/* list header in net->bts_list */
@@ -787,6 +837,9 @@ struct gsm_bts {
/* do we use static (user-defined) system information messages? (bitmask) */
uint32_t si_mode_static;
+ /* access control class ramping */
+ struct bts_acc_ramp acc_ramp;
+
/* exclude the BTS from the global RF Lock handling */
int excl_from_rf_lock;