@@ -639,6 +639,24 @@ out_stats:
return ret;
}
+int odp_override_log(odp_log_level_e level, const char *fmt, ...)
+{
+ va_list args;
+ enum vlog_level ovs_level;
+ if (level == ODP_LOG_DBG)
+ ovs_level = VLL_DBG;
+ else if (level == ODP_LOG_PRINT)
+ ovs_level = VLL_INFO;
+ else
+ ovs_level = VLL_ERR;
+
+ va_start(args, fmt);
+ vlog_rate_limit_valist(THIS_MODULE, ovs_level, &rl, fmt, args);
+ va_end(args);
+
+ return 0;
+}
+
static struct netdev_class netdev_odp_class = {
"odp",
odp_class_init, /* init */
ODP logs now end up in OVS logs. Signed-off-by: Zoltan Kiss <zoltan.kiss@linaro.org> --- lib/netdev-odp.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+)