pespin has uploaded a new patch set (#2). ( https://gerrit.osmocom.org/c/osmo-bsc/+/38082?usp=email )
Change subject: bts: Make sure bts_location entries in bts->loc_list are freed
......................................................................
bts: Make sure bts_location entries in bts->loc_list are freed
This went unnoticed because so far there's not clear way to free a BTS,
eg. through VTY.
Change-Id: I4de3d56a4f1f6bd1fe880b72cdd384c2398dabc9
---
M include/osmocom/bsc/bts.h
M src/osmo-bsc/bts.c
M src/osmo-bsc/bts_ctrl.c
3 files changed, 4 insertions(+), 2 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/82/38082/2
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38082?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I4de3d56a4f1f6bd1fe880b72cdd384c2398dabc9
Gerrit-Change-Number: 38082
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-CC: Jenkins Builder
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bsc/+/38082?usp=email )
Change subject: bts: Make sure bts_location entries in bts->loc_list are freed
......................................................................
bts: Make sure bts_location entries in bts->loc_list are freed
This went unnoticed because so far there's not clear way to free a BTS,
eg. through VTY.
Change-Id: I4de3d56a4f1f6bd1fe880b72cdd384c2398dabc9
---
M include/osmocom/bsc/bts.h
M src/osmo-bsc/bts.c
M src/osmo-bsc/bts_ctrl.c
3 files changed, 5 insertions(+), 2 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/82/38082/1
diff --git a/include/osmocom/bsc/bts.h b/include/osmocom/bsc/bts.h
index a8680d8..38e675a 100644
--- a/include/osmocom/bsc/bts.h
+++ b/include/osmocom/bsc/bts.h
@@ -337,7 +337,7 @@
/* list header in net->bts_list */
struct llist_head list;
- /* Geographical location of the BTS */
+ /* Geographical location of the BTS, head list of "struct bts_location" */
struct llist_head loc_list;
/* number of this BTS in network */
diff --git a/src/osmo-bsc/bts.c b/src/osmo-bsc/bts.c
index 260e24e..e3d909f 100644
--- a/src/osmo-bsc/bts.c
+++ b/src/osmo-bsc/bts.c
@@ -156,6 +156,9 @@
static int gsm_bts_talloc_destructor(struct gsm_bts *bts)
{
+
+ /* Entries in bts->loc_list are freed by talloc recursively, no need to free them here. */
+
paging_destructor(bts);
bts_setup_ramp_remove(bts);
diff --git a/src/osmo-bsc/bts_ctrl.c b/src/osmo-bsc/bts_ctrl.c
index 48b1b8a..76806f4 100644
--- a/src/osmo-bsc/bts_ctrl.c
+++ b/src/osmo-bsc/bts_ctrl.c
@@ -169,7 +169,7 @@
return CTRL_CMD_ERROR;
}
- curloc = talloc_zero(tall_bsc_ctx, struct bts_location);
+ curloc = talloc_zero(bts, struct bts_location);
if (!curloc) {
talloc_free(tmp);
goto oom;
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38082?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newchange
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I4de3d56a4f1f6bd1fe880b72cdd384c2398dabc9
Gerrit-Change-Number: 38082
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Attention is currently required from: dexter, fixeria.
pespin has posted comments on this change by pespin. ( https://gerrit.osmocom.org/c/osmo-bsc/+/38076?usp=email )
Change subject: pcu_tx_rach_ind(): Avoid forwarding chan_rqd to PCU if not expected
......................................................................
Patch Set 1:
(1 comment)
File src/osmo-bsc/pcu_sock.c:
https://gerrit.osmocom.org/c/osmo-bsc/+/38076/comment/084ba99a_5758962d?usp… :
PS1, Line 426: bsc_co_located_pcu
> Shouldn't this check be done in a common place like `pcu_sock_send()`?
That's too late, since you don't have bts information there, only the uint8_t bts_nr which is already malfunctioning.
I think in here it's fine.
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38076?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: Ic12aa9842227b2d815bb91f8587c8b258d07f169
Gerrit-Change-Number: 38076
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Tue, 10 Sep 2024 15:43:15 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de>
Attention is currently required from: dexter, pespin.
fixeria has posted comments on this change by pespin. ( https://gerrit.osmocom.org/c/osmo-bsc/+/38076?usp=email )
Change subject: pcu_tx_rach_ind(): Avoid forwarding chan_rqd to PCU if not expected
......................................................................
Patch Set 1: Code-Review+1
(1 comment)
File src/osmo-bsc/pcu_sock.c:
https://gerrit.osmocom.org/c/osmo-bsc/+/38076/comment/a8c73166_bd160d76?usp… :
PS1, Line 426: bsc_co_located_pcu
Shouldn't this check be done in a common place like `pcu_sock_send()`?
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/38076?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: Ic12aa9842227b2d815bb91f8587c8b258d07f169
Gerrit-Change-Number: 38076
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Tue, 10 Sep 2024 15:24:43 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes