Change in libosmocore[master]: GSUP: rename E_ROUTING_ERROR to ROUTING_ERROR

2019-11-24 Thread neels
neels has submitted this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/16161 )

Change subject: GSUP: rename E_ROUTING_ERROR to ROUTING_ERROR
..

GSUP: rename E_ROUTING_ERROR to ROUTING_ERROR

GSUP routing was introduced when adding the E interface. Hence that was the
first realm where routing errors could occur. I did notice back then that this
message type was special: it does not convey a response to a particular message
kind -- it does not make sense, for example, to return an Updating Location
Error cause, and do that for all conceivable message types. Instead, this tells
the sender that a deeper error exists, i.e. that the desired peer is completely
gone and unreachable.

I did not foresee though that for D-GSM, there would also be arbitrary GSUP
proxy routing, and that this error is not limited to E interface semantics.
>From today's point of view, adding the "_E_" in the name was a mistake.

Remove that "_E_" to yield OSMO_GSUP_MSGT_ROUTING_ERROR (with unchanged message
type discriminator), but provide a #define linking the old name
OSMO_GSUP_MSGT_E_ROUTING_ERROR to the new one.

The only visible change should be that osmo_gsup_message_type_names[] now
returns the new name without "_E_". I am not aware of any regression test
fallout from that.

Change-Id: Ic8e8bd11522d6c51ac7aaf946516cbce26bc6e1e
---
M include/osmocom/gsm/gsup.h
M src/gsm/gsup.c
2 files changed, 4 insertions(+), 2 deletions(-)

Approvals:
  Jenkins Builder: Verified
  fixeria: Looks good to me, but someone else must approve
  laforge: Looks good to me, approved



diff --git a/include/osmocom/gsm/gsup.h b/include/osmocom/gsm/gsup.h
index 49ddb74..c883dfb 100644
--- a/include/osmocom/gsm/gsup.h
+++ b/include/osmocom/gsm/gsup.h
@@ -196,9 +196,11 @@
OSMO_GSUP_MSGT_E_CLOSE  = 0b01000111,
OSMO_GSUP_MSGT_E_ABORT  = 0b01001011,

-   OSMO_GSUP_MSGT_E_ROUTING_ERROR  = 0b01001110,
+   OSMO_GSUP_MSGT_ROUTING_ERROR= 0b01001110,
 };

+#define OSMO_GSUP_MSGT_E_ROUTING_ERROR OSMO_GSUP_MSGT_ROUTING_ERROR
+
 #define OSMO_GSUP_IS_MSGT_REQUEST(msgt) (((msgt) & 0b0011) == 0b00)
 #define OSMO_GSUP_IS_MSGT_ERROR(msgt)   (((msgt) & 0b0011) == 0b01)
 #define OSMO_GSUP_TO_MSGT_ERROR(msgt)   (((msgt) & 0b1100) | 0b01)
diff --git a/src/gsm/gsup.c b/src/gsm/gsup.c
index 2f9d85d..ad7a2a4 100644
--- a/src/gsm/gsup.c
+++ b/src/gsm/gsup.c
@@ -101,7 +101,7 @@
OSMO_VALUE_STRING(OSMO_GSUP_MSGT_E_CLOSE),
OSMO_VALUE_STRING(OSMO_GSUP_MSGT_E_ABORT),

-   OSMO_VALUE_STRING(OSMO_GSUP_MSGT_E_ROUTING_ERROR),
+   OSMO_VALUE_STRING(OSMO_GSUP_MSGT_ROUTING_ERROR),

{ 0, NULL }
 };

--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/16161
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Ic8e8bd11522d6c51ac7aaf946516cbce26bc6e1e
Gerrit-Change-Number: 16161
Gerrit-PatchSet: 4
Gerrit-Owner: neels 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: neels 
Gerrit-MessageType: merged


Change in libosmocore[master]: GSUP: rename E_ROUTING_ERROR to ROUTING_ERROR

2019-11-22 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/16161 )

Change subject: GSUP: rename E_ROUTING_ERROR to ROUTING_ERROR
..


Patch Set 3: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/16161
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Ic8e8bd11522d6c51ac7aaf946516cbce26bc6e1e
Gerrit-Change-Number: 16161
Gerrit-PatchSet: 3
Gerrit-Owner: neels 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria 
Gerrit-Reviewer: laforge 
Gerrit-Comment-Date: Fri, 22 Nov 2019 10:47:13 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in libosmocore[master]: GSUP: rename E_ROUTING_ERROR to ROUTING_ERROR

2019-11-22 Thread fixeria
fixeria has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/16161 )

Change subject: GSUP: rename E_ROUTING_ERROR to ROUTING_ERROR
..


Patch Set 3: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/16161
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Ic8e8bd11522d6c51ac7aaf946516cbce26bc6e1e
Gerrit-Change-Number: 16161
Gerrit-PatchSet: 3
Gerrit-Owner: neels 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria 
Gerrit-Comment-Date: Fri, 22 Nov 2019 09:20:27 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in libosmocore[master]: GSUP: rename E_ROUTING_ERROR to ROUTING_ERROR

2019-11-21 Thread neels
neels has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/libosmocore/+/16161 )


Change subject: GSUP: rename E_ROUTING_ERROR to ROUTING_ERROR
..

GSUP: rename E_ROUTING_ERROR to ROUTING_ERROR

GSUP routing was introduced when adding the E interface. Hence that was the
first realm where routing errors could occur. I did notice back then that this
message type was special: it does not convey a response to a particular message
kind -- it does not make sense, for example, to return an Updating Location
Error cause, and do that for all conceivable message types. Instead, this tells
the sender that a deeper error exists, i.e. that the desired peer is completely
gone and unreachable.

I did not foresee though that for D-GSM, there would also be arbitrary GSUP
proxy routing, and that this error is not limited to E interface semantics.
>From today's point of view, adding the "_E_" in the name was a mistake.

Remove that "_E_" to yield OSMO_GSUP_MSGT_ROUTING_ERROR (with unchanged message
type discriminator), but provide a #define linking the old name
OSMO_GSUP_MSGT_E_ROUTING_ERROR to the new one.

The only visible change should be that osmo_gsup_message_type_names[] now
returns the new name without "_E_". I am not aware of any regression test
fallout from that.

Change-Id: Ic8e8bd11522d6c51ac7aaf946516cbce26bc6e1e
---
M include/osmocom/gsm/gsup.h
M src/gsm/gsup.c
2 files changed, 4 insertions(+), 2 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/61/16161/1

diff --git a/include/osmocom/gsm/gsup.h b/include/osmocom/gsm/gsup.h
index 49ddb74..c883dfb 100644
--- a/include/osmocom/gsm/gsup.h
+++ b/include/osmocom/gsm/gsup.h
@@ -196,9 +196,11 @@
OSMO_GSUP_MSGT_E_CLOSE  = 0b01000111,
OSMO_GSUP_MSGT_E_ABORT  = 0b01001011,

-   OSMO_GSUP_MSGT_E_ROUTING_ERROR  = 0b01001110,
+   OSMO_GSUP_MSGT_ROUTING_ERROR= 0b01001110,
 };

+#define OSMO_GSUP_MSGT_E_ROUTING_ERROR OSMO_GSUP_MSGT_ROUTING_ERROR
+
 #define OSMO_GSUP_IS_MSGT_REQUEST(msgt) (((msgt) & 0b0011) == 0b00)
 #define OSMO_GSUP_IS_MSGT_ERROR(msgt)   (((msgt) & 0b0011) == 0b01)
 #define OSMO_GSUP_TO_MSGT_ERROR(msgt)   (((msgt) & 0b1100) | 0b01)
diff --git a/src/gsm/gsup.c b/src/gsm/gsup.c
index 2f9d85d..ad7a2a4 100644
--- a/src/gsm/gsup.c
+++ b/src/gsm/gsup.c
@@ -101,7 +101,7 @@
OSMO_VALUE_STRING(OSMO_GSUP_MSGT_E_CLOSE),
OSMO_VALUE_STRING(OSMO_GSUP_MSGT_E_ABORT),

-   OSMO_VALUE_STRING(OSMO_GSUP_MSGT_E_ROUTING_ERROR),
+   OSMO_VALUE_STRING(OSMO_GSUP_MSGT_ROUTING_ERROR),

{ 0, NULL }
 };

--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/16161
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Ic8e8bd11522d6c51ac7aaf946516cbce26bc6e1e
Gerrit-Change-Number: 16161
Gerrit-PatchSet: 1
Gerrit-Owner: neels 
Gerrit-MessageType: newchange