2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-31 14:25:26 +00:00

odp-execute: Avoid unnecessary logging for action implementations.

There is no need to log if the implementation didn't change.
Scalar one is default, any change will be logged.  And availability
is not really important to log at INFO level.  Moving these logs
to DBG level to avoid littering the log file and confusing users.
We do the same for miniflow_extract and datapath interface
implementations.

Additionally text of the log message made more readable and uniform
with the one used for miniflow_extract.

Fixes: 95e4a35b0a ("odp-execute: Add function pointers to odp-execute for different action implementations.")
Acked-by: Emma Finn <emma.finn@intel.com>
Acked-by: Eelco Chaudron <echaudro@redhat.com>
Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
This commit is contained in:
Ilya Maximets
2022-07-20 20:00:38 +02:00
parent ad026f40da
commit 2f4eb2d8c8

View File

@@ -97,9 +97,10 @@ odp_execute_action_set(const char *name)
for (int i = 0; i < ACTION_IMPL_MAX; i++) {
/* String compare, and set ptrs atomically. */
if (!strcmp(action_impls[i].name, name)) {
active_action_impl_index = i;
VLOG_INFO("Action implementation set to %s", name);
if (i != active_action_impl_index) {
active_action_impl_index = i;
VLOG_INFO("Action implementation set to %s", name);
}
return &action_impls[i];
}
}
@@ -142,8 +143,8 @@ odp_execute_action_init(void)
action_impls[i].available = avail;
VLOG_INFO("Action implementation %s (available: %s)",
action_impls[i].name, avail ? "Yes" : "No");
VLOG_DBG("Actions implementation '%s' %s available.",
action_impls[i].name, avail ? "is" : "is not");
/* The following is a run-time check to make sure a scalar
* implementation exists for the given ISA implementation. This is to