pespin has submitted this change. (
https://gerrit.osmocom.org/c/osmo-hnbgw/+/40273?usp=email )
(
4 is the latest approved patch-set.
No files were changed between the latest approved patch-set and the submitted one.
)Change subject: context_map: Rename ps_rab(_ass) to denote it is a list
......................................................................
context_map: Rename ps_rab(_ass) to denote it is a list
This allows also easily grepping to figure out where it is used,
otherwise it was named like the struct, fsm, etc.
Change-Id: I6ac029e6a820a031a443dae8c83e44f6ae9fb5fa
---
M include/osmocom/hnbgw/context_map.h
M src/osmo-hnbgw/context_map.c
M src/osmo-hnbgw/ps_rab_ass_fsm.c
M src/osmo-hnbgw/ps_rab_fsm.c
4 files changed, 20 insertions(+), 20 deletions(-)
Approvals:
pespin: Looks good to me, approved
Jenkins Builder: Verified
osmith: Looks good to me, but someone else must approve
laforge: Looks good to me, but someone else must approve
diff --git a/include/osmocom/hnbgw/context_map.h b/include/osmocom/hnbgw/context_map.h
index a885f5b..55743ed 100644
--- a/include/osmocom/hnbgw/context_map.h
+++ b/include/osmocom/hnbgw/context_map.h
@@ -200,15 +200,15 @@
* and Request and Response don't necessarily match the RAB IDs contained. In
practice I only ever see a single
* RAB matching in Request and Response, but we cannot rely on that to always be true.
*
- * The state of each RAB's PFCP negotiation is kept separately in the list ps_rabs,
and as soon as all RABs
+ * The state of each RAB's PFCP negotiation is kept separately in the field
ps_rab_list, and as soon as all RABs
* appearing in a PS RAB Assignment message have completed their PFCP setup, we can
replace the GTP info for the
* RAB IDs and forward the RAB Assignment Request to HNB / the RAB Assignment Response
to CN.
*/
- struct llist_head ps_rab_ass;
+ struct llist_head ps_rab_ass_list;
/* All PS RABs and their GTP tunnel mappings. list of struct ps_rab. Each ps_rab FSM
handles the PFCP
* communication for one particular RAB ID. */
- struct llist_head ps_rabs;
+ struct llist_head ps_rab_list;
/* RAB state tracking. As RAB-ID is an 8-bit integer, we need 256 elements in the array
*/
uint8_t rab_state[256];
diff --git a/src/osmo-hnbgw/context_map.c b/src/osmo-hnbgw/context_map.c
index cc68ec6..a70905c 100644
--- a/src/osmo-hnbgw/context_map.c
+++ b/src/osmo-hnbgw/context_map.c
@@ -88,8 +88,8 @@
map->hnb_ctx = hnb;
map->rua_ctx_id = rua_ctx_id;
map->is_ps = is_ps;
- INIT_LLIST_HEAD(&map->ps_rab_ass);
- INIT_LLIST_HEAD(&map->ps_rabs);
+ INIT_LLIST_HEAD(&map->ps_rab_ass_list);
+ INIT_LLIST_HEAD(&map->ps_rab_list);
map_rua_fsm_alloc(map);
diff --git a/src/osmo-hnbgw/ps_rab_ass_fsm.c b/src/osmo-hnbgw/ps_rab_ass_fsm.c
index f5025a2..f76b1cf 100644
--- a/src/osmo-hnbgw/ps_rab_ass_fsm.c
+++ b/src/osmo-hnbgw/ps_rab_ass_fsm.c
@@ -81,10 +81,10 @@
* This structure manages the RAB Assignment procedures, and the currently set up RABs:
*
* - hnbgw_context_map
- * - .ps_rab_ass: list of PS RAB Assignment procedures
+ * - .ps_rab_ass_list: list of PS RAB Assignment procedures
* - ps_rab_ass_fsm: one RANAP PS RAB Assignment procedure
* - ...
- * - .ps_rabs: list of individual PS RABs
+ * - .ps_rab_list: list of individual PS RABs
* - ps_rab_fsm: one GTP mapping with PFCP session to the UPF, for a single RAB
* - ...
*
@@ -140,7 +140,7 @@
};
fi->priv = rab_ass;
- llist_add_tail(&rab_ass->entry, &map->ps_rab_ass);
+ llist_add_tail(&rab_ass->entry, &map->ps_rab_ass_list);
return rab_ass;
}
@@ -240,7 +240,7 @@
goto no_rab;
}
- /* Multiple RABs may be set up, assemble in list rab_ass->ps_rabs. */
+ /* Multiple RABs may be set up, assemble in list map->ps_rab_list. */
for (i = 0; i < ies->raB_SetupOrModifyList.list.count; i++) {
RANAP_ProtocolIE_ContainerPair_t *protocol_ie_container_pair;
RANAP_ProtocolIE_FieldPair_t *protocol_ie_field_pair;
@@ -256,7 +256,7 @@
goto no_rab;
}
- /* Got all RABs' state and their Core side GTP info in map->ps_rabs. For each, a
ps_rab_fsm has been started and
+ /* Got all RABs' state and their Core side GTP info in map->ps_rab_list. For
each, a ps_rab_fsm has been started and
* each will call back with PS_RAB_ASS_EV_LOCAL_F_TEIDS_RX or PS_RAB_ASS_EV_RAB_FAIL.
*/
fi = rab_ass->fi;
return ps_rab_ass_fsm_state_chg(PS_RAB_ASS_ST_WAIT_LOCAL_F_TEIDS);
@@ -443,7 +443,7 @@
LOG_PS_RAB_ASS(rab_ass, LOGL_INFO, "PS RAB-AssignmentResponse received, updating
RABs\n");
- /* Multiple RABs may be set up, bump matching FSMs in list rab_ass->ps_rabs. */
+ /* Multiple RABs may be set up, bump matching FSMs in list map->ps_rab_list. */
for (i = 0; i <
ies->raB_SetupOrModifiedList.raB_SetupOrModifiedList_ies.list.count; i++) {
RANAP_IE_t *list_ie;
RANAP_RAB_SetupOrModifiedItemIEs_t item_ies;
@@ -469,7 +469,7 @@
ASN_STRUCT_FREE_CONTENTS_ONLY(asn_DEF_RANAP_RAB_SetupOrModifiedItem, &item_ies);
}
- /* Got all RABs' state and updated their Access side GTP info in map->ps_rabs.
For each RAB ID, the matching
+ /* Got all RABs' state and updated their Access side GTP info in
map->ps_rab_list. For each RAB ID, the matching
* ps_rab_fsm has been instructed to tell the UPF about the Access Remote GTP F-TEID.
Each will call back with
* PS_RAB_ASS_EV_RAB_ESTABLISHED or PS_RAB_ASS_EV_RAB_FAIL. */
fi = rab_ass->fi;
@@ -618,14 +618,14 @@
struct ps_rab_ass *rab_ass = fi->priv;
struct ps_rab *rab;
- llist_for_each_entry(rab, &rab_ass->map->ps_rabs, entry) {
+ llist_for_each_entry(rab, &rab_ass->map->ps_rab_list, entry) {
if (rab->req_fi == fi)
rab->req_fi = NULL;
if (rab->resp_fi == fi)
rab->resp_fi = NULL;
}
- /* remove from map->ps_rab_ass */
+ /* remove from map->ps_rab_ass_list */
llist_del(&rab_ass->entry);
}
@@ -633,10 +633,10 @@
{
struct ps_rab_ass *rab_ass, *next;
struct ps_rab *rab, *next2;
- llist_for_each_entry_safe(rab, next2, &map->ps_rabs, entry) {
+ llist_for_each_entry_safe(rab, next2, &map->ps_rab_list, entry) {
ps_rab_release(rab);
}
- llist_for_each_entry_safe(rab_ass, next, &map->ps_rab_ass, entry) {
+ llist_for_each_entry_safe(rab_ass, next, &map->ps_rab_ass_list, entry) {
osmo_fsm_inst_term(rab_ass->fi, OSMO_FSM_TERM_REGULAR, NULL);
}
}
diff --git a/src/osmo-hnbgw/ps_rab_fsm.c b/src/osmo-hnbgw/ps_rab_fsm.c
index f6d113d..6c9c429 100644
--- a/src/osmo-hnbgw/ps_rab_fsm.c
+++ b/src/osmo-hnbgw/ps_rab_fsm.c
@@ -107,7 +107,7 @@
OSMO_ASSERT(osmo_use_count_get_put(&rab->use_count, PS_RAB_USE_ACTIVE, 1) == 0);
- llist_add_tail(&rab->entry, &map->ps_rabs);
+ llist_add_tail(&rab->entry, &map->ps_rab_list);
return rab;
}
@@ -121,7 +121,7 @@
struct hnbgw_context_map *map;
llist_for_each_entry(map, &hnb->map_list, hnb_list) {
struct ps_rab *rab;
- llist_for_each_entry(rab, &map->ps_rabs, entry) {
+ llist_for_each_entry(rab, &map->ps_rab_list, entry) {
uint64_t rab_seid = is_cp_seid ? rab->cp_seid : rab->up_f_seid.seid;
if (rab_seid == seid)
return rab;
@@ -154,7 +154,7 @@
struct ps_rab *ps_rab_get(struct hnbgw_context_map *map, uint8_t rab_id)
{
struct ps_rab *rab;
- llist_for_each_entry(rab, &map->ps_rabs, entry) {
+ llist_for_each_entry(rab, &map->ps_rab_list, entry) {
if (rab->rab_id != rab_id)
continue;
return rab;
@@ -692,7 +692,7 @@
static void ps_rab_forget_map(struct ps_rab *rab)
{
- /* remove from map->ps_rabs */
+ /* remove from map->ps_rab_list */
if (rab->map)
llist_del(&rab->entry);
rab->map = NULL;
--
To view, visit
https://gerrit.osmocom.org/c/osmo-hnbgw/+/40273?usp=email
To unsubscribe, or for help writing mail filters, visit
https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: merged
Gerrit-Project: osmo-hnbgw
Gerrit-Branch: master
Gerrit-Change-Id: I6ac029e6a820a031a443dae8c83e44f6ae9fb5fa
Gerrit-Change-Number: 40273
Gerrit-PatchSet: 5
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>