jolly has uploaded this change for review. (
https://gerrit.osmocom.org/c/osmo-bsc/+/33600
)
Change subject: ASCI: Add selection reason for VGCS/VBS channels
......................................................................
ASCI: Add selection reason for VGCS/VBS channels
"enum lchan_select_reason" gets a new selection reason:
"SELECT_FOR_VGCS"
The selection "direction" can also be changed via VTY.
Change-Id: I6b96d0a1df68efa5858b98297ebe0944b1473aaf
Related: OS#4852
---
M include/osmocom/bsc/bts.h
M include/osmocom/bsc/lchan_select.h
M src/osmo-bsc/bts_vty.c
M src/osmo-bsc/lchan_select.c
4 files changed, 28 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/00/33600/1
diff --git a/include/osmocom/bsc/bts.h b/include/osmocom/bsc/bts.h
index a2b84c6..3f7958c 100644
--- a/include/osmocom/bsc/bts.h
+++ b/include/osmocom/bsc/bts.h
@@ -523,6 +523,7 @@
bool chan_alloc_chan_req_reverse;
bool chan_alloc_assignment_reverse;
bool chan_alloc_handover_reverse;
+ bool chan_alloc_vgcs_reverse;
/* Whether to use dynamic allocation mode for assignment */
bool chan_alloc_assignment_dynamic;
diff --git a/include/osmocom/bsc/lchan_select.h b/include/osmocom/bsc/lchan_select.h
index 8f1dc62..d6a1b20 100644
--- a/include/osmocom/bsc/lchan_select.h
+++ b/include/osmocom/bsc/lchan_select.h
@@ -5,6 +5,7 @@
SELECT_FOR_MS_CHAN_REQ,
SELECT_FOR_ASSIGNMENT,
SELECT_FOR_HANDOVER,
+ SELECT_FOR_VGCS,
};
extern const struct value_string lchan_select_reason_names[];
diff --git a/src/osmo-bsc/bts_vty.c b/src/osmo-bsc/bts_vty.c
index 657d03e..8a34d9f 100644
--- a/src/osmo-bsc/bts_vty.c
+++ b/src/osmo-bsc/bts_vty.c
@@ -549,6 +549,7 @@
bts->chan_alloc_chan_req_reverse = reverse;
bts->chan_alloc_assignment_reverse = reverse;
bts->chan_alloc_handover_reverse = reverse;
+ bts->chan_alloc_vgcs_reverse = reverse;
bts->chan_alloc_assignment_dynamic = false;
return CMD_SUCCESS;
@@ -557,7 +558,7 @@
DEFUN_ATTR(cfg_bts_challoc_mode,
cfg_bts_challoc_mode_cmd,
CHAN_ALLOC_CMD
- " mode (set-all|chan-req|assignment|handover) "
+ " mode (set-all|chan-req|assignment|handover|vgcs-vbs) "
CHAN_ALLOC_ASC_DSC,
CHAN_ALLOC_DESC
"Channel allocation mode\n"
@@ -565,6 +566,7 @@
"Channel allocation for CHANNEL REQUEST (RACH)\n"
"Channel allocation for assignment\n"
"Channel allocation for handover\n"
+ "Channel allocation for VGCS/VBS\n"
CHAN_ALLOC_ASC_DSC_DESC,
CMD_ATTR_IMMEDIATE)
{
@@ -580,6 +582,8 @@
}
if (set_all || !strcmp(argv[0], "handover"))
bts->chan_alloc_handover_reverse = reverse;
+ if (set_all || !strcmp(argv[0], "vgcs-vbs"))
+ bts->chan_alloc_vgcs_reverse = reverse;
return CMD_SUCCESS;
}
@@ -4424,6 +4428,9 @@
vty_out(vty, " channel allocator mode handover %s%s",
bts->chan_alloc_handover_reverse ? "descending" : "ascending",
VTY_NEWLINE);
+ vty_out(vty, " channel allocator mode vgcs-vbs %s%s",
+ bts->chan_alloc_vgcs_reverse ? "descending" : "ascending",
+ VTY_NEWLINE);
if (bts->chan_alloc_avoid_interf)
vty_out(vty, " channel allocator avoid-interference 1%s", VTY_NEWLINE);
if (bts->chan_alloc_tch_signalling_policy == BTS_TCH_SIGNALLING_NEVER)
diff --git a/src/osmo-bsc/lchan_select.c b/src/osmo-bsc/lchan_select.c
index 1e12d96..b4bc664 100644
--- a/src/osmo-bsc/lchan_select.c
+++ b/src/osmo-bsc/lchan_select.c
@@ -41,6 +41,7 @@
OSMO_VALUE_STRING(SELECT_FOR_MS_CHAN_REQ),
OSMO_VALUE_STRING(SELECT_FOR_ASSIGNMENT),
OSMO_VALUE_STRING(SELECT_FOR_HANDOVER),
+ OSMO_VALUE_STRING(SELECT_FOR_VGCS),
{0, NULL}
};
@@ -349,6 +350,9 @@
case SELECT_FOR_HANDOVER:
chan_alloc_reverse = bts->chan_alloc_handover_reverse;
break;
+ case SELECT_FOR_VGCS:
+ chan_alloc_reverse = bts->chan_alloc_vgcs_reverse;
+ break;
}
/* Allocate an array with pointers to all timeslots of a BTS */
--
To view, visit
https://gerrit.osmocom.org/c/osmo-bsc/+/33600
To unsubscribe, or for help writing mail filters, visit
https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I6b96d0a1df68efa5858b98297ebe0944b1473aaf
Gerrit-Change-Number: 33600
Gerrit-PatchSet: 1
Gerrit-Owner: jolly <andreas(a)eversberg.eu>
Gerrit-MessageType: newchange