openbsc[master]: rm dup: use channel type names from libosmocore

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Harald Welte gerrit-no-reply at lists.osmocom.org
Thu Jun 16 17:51:42 UTC 2016


Patch Set 3:

> I recall someone (Harald?) recommended me to use get_value_string()
 > directly. Having 1-line wrappers doesn't seem to bring much value
 > anyway.

Yes, it was most likely me.  The dedicated get_*_name() functions come from a time when we didn't have struct value_string yet, but dedicated array and hand-coded conversion functions.  That's long gone.

calling get_value_string() with the name of the array leads in a lot more typing on the other hand.  Introducing new symbols menas the .map files need to be updated...

What could be a reasonable compromise is to have a static inline function declared in the .h file.  This way we don't intrduce new symbols but still have shorter-to-type convenience wrappers around get_value_string() without any performance impact, as they will be in-lined (as opposed to the extra function call of a non-inline function).  so let's go this way.

-- 
To view, visit https://gerrit.osmocom.org/267
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: If65ee7c0619cbc0acb0a15045bd5a969442c93cc
Gerrit-PatchSet: 3
Gerrit-Project: openbsc
Gerrit-Branch: master
Gerrit-Owner: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-HasComments: No



More information about the gerrit-log mailing list