Change in osmo-bts[master]: l1sap: radio_link_timeout(): clarify logging messages
Hoernchen has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bts/+/19533 ) Change subject: l1sap: radio_link_timeout(): clarify logging messages .. l1sap: radio_link_timeout(): clarify logging messages Change-Id: Iafb190454c65cebe3de3c212fa8b10a86ec7eb67 --- M src/common/l1sap.c 1 file changed, 12 insertions(+), 12 deletions(-) Approvals: laforge: Looks good to me, but someone else must approve Hoernchen: Looks good to me, approved Jenkins Builder: Verified diff --git a/src/common/l1sap.c b/src/common/l1sap.c index e05ec78..dc236aa 100644 --- a/src/common/l1sap.c +++ b/src/common/l1sap.c @@ -1178,20 +1178,19 @@ /* if link loss criterion already reached */ if (lchan->s == 0) { - DEBUGP(DMEAS, "%s radio link counter S already 0.\n", + DEBUGP(DMEAS, "%s radio link timeout counter S is already 0\n", gsm_lchan_name(lchan)); return; } if (bad_frame) { - /* count down radio link counter S */ - lchan->s--; - DEBUGP(DMEAS, "%s counting down radio link counter S=%d\n", - gsm_lchan_name(lchan), lchan->s); + DEBUGP(DMEAS, "%s decreasing radio link timeout counter S=%d -> %d\n", + gsm_lchan_name(lchan), lchan->s, lchan->s - 1); + lchan->s--; /* count down radio link counter S */ if (lchan->s == 0) { LOGPLCHAN(lchan, DMEAS, LOGL_NOTICE, - "radio link counter timeout S=%d, dropping conn\n", - lchan->s); + "radio link timeout counter S reached zero, " + "dropping connection\n"); rsl_tx_conn_fail(lchan, RSL_ERR_RADIO_LINK_FAIL); } return; @@ -1199,11 +1198,12 @@ if (lchan->s < bts->radio_link_timeout) { /* count up radio link counter S */ - lchan->s += 2; - if (lchan->s > bts->radio_link_timeout) - lchan->s = bts->radio_link_timeout; - DEBUGP(DMEAS, "%s counting up radio link counter S=%d\n", - gsm_lchan_name(lchan), lchan->s); + int s = lchan->s + 2; + if (s > bts->radio_link_timeout) + s = bts->radio_link_timeout; + DEBUGP(DMEAS, "%s increasing radio link timeout counter S=%d -> %d\n", + gsm_lchan_name(lchan), lchan->s, s); + lchan->s = s; } } -- To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/19533 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Change-Id: Iafb190454c65cebe3de3c212fa8b10a86ec7eb67 Gerrit-Change-Number: 19533 Gerrit-PatchSet: 2 Gerrit-Owner: fixeria Gerrit-Reviewer: Hoernchen Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge Gerrit-MessageType: merged
Change in osmo-bts[master]: l1sap: radio_link_timeout(): clarify logging messages
Hoernchen has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bts/+/19533 ) Change subject: l1sap: radio_link_timeout(): clarify logging messages .. Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/19533 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Change-Id: Iafb190454c65cebe3de3c212fa8b10a86ec7eb67 Gerrit-Change-Number: 19533 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria Gerrit-Reviewer: Hoernchen Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge Gerrit-Comment-Date: Fri, 07 Aug 2020 18:26:39 + Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
Change in osmo-bts[master]: l1sap: radio_link_timeout(): clarify logging messages
laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bts/+/19533 ) Change subject: l1sap: radio_link_timeout(): clarify logging messages .. Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/19533 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Change-Id: Iafb190454c65cebe3de3c212fa8b10a86ec7eb67 Gerrit-Change-Number: 19533 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge Gerrit-Comment-Date: Thu, 06 Aug 2020 15:53:23 + Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
Change in osmo-bts[master]: l1sap: radio_link_timeout(): clarify logging messages
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bts/+/19533 ) Change subject: l1sap: radio_link_timeout(): clarify logging messages .. l1sap: radio_link_timeout(): clarify logging messages Change-Id: Iafb190454c65cebe3de3c212fa8b10a86ec7eb67 --- M src/common/l1sap.c 1 file changed, 12 insertions(+), 12 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/33/19533/1 diff --git a/src/common/l1sap.c b/src/common/l1sap.c index e05ec78..dc236aa 100644 --- a/src/common/l1sap.c +++ b/src/common/l1sap.c @@ -1178,20 +1178,19 @@ /* if link loss criterion already reached */ if (lchan->s == 0) { - DEBUGP(DMEAS, "%s radio link counter S already 0.\n", + DEBUGP(DMEAS, "%s radio link timeout counter S is already 0\n", gsm_lchan_name(lchan)); return; } if (bad_frame) { - /* count down radio link counter S */ - lchan->s--; - DEBUGP(DMEAS, "%s counting down radio link counter S=%d\n", - gsm_lchan_name(lchan), lchan->s); + DEBUGP(DMEAS, "%s decreasing radio link timeout counter S=%d -> %d\n", + gsm_lchan_name(lchan), lchan->s, lchan->s - 1); + lchan->s--; /* count down radio link counter S */ if (lchan->s == 0) { LOGPLCHAN(lchan, DMEAS, LOGL_NOTICE, - "radio link counter timeout S=%d, dropping conn\n", - lchan->s); + "radio link timeout counter S reached zero, " + "dropping connection\n"); rsl_tx_conn_fail(lchan, RSL_ERR_RADIO_LINK_FAIL); } return; @@ -1199,11 +1198,12 @@ if (lchan->s < bts->radio_link_timeout) { /* count up radio link counter S */ - lchan->s += 2; - if (lchan->s > bts->radio_link_timeout) - lchan->s = bts->radio_link_timeout; - DEBUGP(DMEAS, "%s counting up radio link counter S=%d\n", - gsm_lchan_name(lchan), lchan->s); + int s = lchan->s + 2; + if (s > bts->radio_link_timeout) + s = bts->radio_link_timeout; + DEBUGP(DMEAS, "%s increasing radio link timeout counter S=%d -> %d\n", + gsm_lchan_name(lchan), lchan->s, s); + lchan->s = s; } } -- To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/19533 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Change-Id: Iafb190454c65cebe3de3c212fa8b10a86ec7eb67 Gerrit-Change-Number: 19533 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria Gerrit-MessageType: newchange