Add channel_allocator cfg attr to bts resources

Change-Id: I682809d4aeb91a36e3a35fc481e8d40d0b084fa0
This commit is contained in:
Pau Espin 2018-08-22 11:01:32 +02:00
parent 568228701c
commit 722e94e833
4 changed files with 10 additions and 1 deletions

View File

@ -28,6 +28,7 @@ bsc_bts:
base_station_id_code: 63
stream_id: 255
osmobsc_bts_type: sysmobts
channel_allocator: ascending
num_trx: 1
max_trx: 1
trx_list:

View File

@ -58,6 +58,7 @@ RESOURCES_SCHEMA = {
'bts[].launch_trx': schema.BOOL_STR,
'bts[].direct_pcu': schema.BOOL_STR,
'bts[].ciphers[]': schema.CIPHER,
'bts[].channel_allocator': schema.CHAN_ALLOCATOR,
'bts[].num_trx': schema.UINT,
'bts[].max_trx': schema.UINT,
'bts[].trx_list[].addr': schema.IPV4,

View File

@ -105,6 +105,11 @@ def phy_channel_config(val):
return
raise ValueError('Unknown Physical channel config: %r' % val)
def channel_allocator(val):
if val in ('ascending', 'descending'):
return
raise ValueError('Unknown Channel Allocator Policy %r' % val)
INT = 'int'
STR = 'str'
UINT = 'uint'
@ -120,6 +125,7 @@ TIMES='times'
CIPHER = 'cipher'
MODEM_FEATURE = 'modem_feature'
PHY_CHAN = 'chan'
CHAN_ALLOCATOR = 'chan_allocator'
SCHEMA_TYPES = {
INT: int,
@ -137,6 +143,7 @@ SCHEMA_TYPES = {
CIPHER: cipher,
MODEM_FEATURE: modem_feature,
PHY_CHAN: phy_channel_config,
CHAN_ALLOCATOR: channel_allocator,
}
def validate(config, schema):

View File

@ -49,7 +49,7 @@ network
ms max power 33
cell reselection hysteresis 4
rxlev access min 0
channel allocator ascending
channel allocator ${bts.channel_allocator}
rach tx integer 9
rach max transmission 7
% if bsc.net.get('rsl_ip', False):