Message ID | 20230227195423.1307900-1-i.maximets@ovn.org |
---|---|
State | Accepted |
Headers | show |
Series | [ovs-dev] ovn-util: Remove unused ovn_parse_internal_version_minor. | expand |
Context | Check | Description |
---|---|---|
ovsrobot/apply-robot | success | apply and check: success |
ovsrobot/github-robot-_Build_and_Test | fail | github build: failed |
ovsrobot/github-robot-_ovn-kubernetes | fail | github build: failed |
On Mon, Feb 27, 2023 at 08:54:23PM +0100, Ilya Maximets wrote: > The only user of this function was removed in a cited commit. And > it is unlikely to be used in the future, since we have feature flags > in the database instead. > > Fixes: 3013c2869696 ("northd: ovn-controller: Use ct_mark.natted only when ct_lb_mark is used.") > Signed-off-by: Ilya Maximets <i.maximets@ovn.org> Reviewed-by: Simon Horman <simon.horman@corigine.com>
On 2/28/23 11:01, Simon Horman wrote: > On Mon, Feb 27, 2023 at 08:54:23PM +0100, Ilya Maximets wrote: >> The only user of this function was removed in a cited commit. And >> it is unlikely to be used in the future, since we have feature flags >> in the database instead. >> >> Fixes: 3013c2869696 ("northd: ovn-controller: Use ct_mark.natted only when ct_lb_mark is used.") >> Signed-off-by: Ilya Maximets <i.maximets@ovn.org> > > Reviewed-by: Simon Horman <simon.horman@corigine.com> > Thanks, Ilya and Simon! I applied this to the main branch and backported it all the way down to 22.03. Regards, Dumitru
diff --git a/lib/ovn-util.c b/lib/ovn-util.c index b12c027b9..5cd38c9c4 100644 --- a/lib/ovn-util.c +++ b/lib/ovn-util.c @@ -825,24 +825,6 @@ ovn_get_internal_version(void) N_OVNACTS, OVN_INTERNAL_MINOR_VER); } -unsigned int -ovn_parse_internal_version_minor(const char *ver) -{ - const char *p = ver + strlen(ver); - for (int i = 0; i < strlen(ver); i++) { - if (*p == '.') { - break; - } - p--; - } - - unsigned int minor; - if (ovs_scan(p, ".%u", &minor)) { - return minor; - } - return 0; -} - #ifdef DDLOG /* Callbacks used by the ddlog northd code to print warnings and errors. */ void diff --git a/lib/ovn-util.h b/lib/ovn-util.h index cda1fde48..a1a418a24 100644 --- a/lib/ovn-util.h +++ b/lib/ovn-util.h @@ -266,11 +266,6 @@ bool ip_address_and_port_from_lb_key(const char *key, char **ip_address, * value. */ char *ovn_get_internal_version(void); -/* Parse the provided internal version string and return the "minor" part which - * is expected to be an unsigned integer followed by the last "." in the - * string. Returns 0 if the string can't be parsed. */ -unsigned int ovn_parse_internal_version_minor(const char *ver); - /* OVN Packet definitions. These may eventually find a home in OVS's * packets.h file. For the time being, they live here because OVN uses them * and OVS does not.
The only user of this function was removed in a cited commit. And it is unlikely to be used in the future, since we have feature flags in the database instead. Fixes: 3013c2869696 ("northd: ovn-controller: Use ct_mark.natted only when ct_lb_mark is used.") Signed-off-by: Ilya Maximets <i.maximets@ovn.org> --- lib/ovn-util.c | 18 ------------------ lib/ovn-util.h | 5 ----- 2 files changed, 23 deletions(-)