[dpdk-dev] [PATCH] vhost: fix remove macro name conflict
Tan, Jianfeng
jianfeng.tan at intel.com
Sun Feb 11 05:03:52 CET 2018
> -----Original Message-----
> From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Tomasz Kulasek
> Sent: Saturday, February 10, 2018 1:24 AM
> To: yliu at fridaylinux.org
> Cc: dev at dpdk.org; Xie, Huawei; stable at dpdk.org; Walker, Benjamin
> Subject: [dpdk-dev] [PATCH] vhost: fix remove macro name conflict
>
> LOG_DEBUG is a symbol defined by POSIX, so if sys/log.h is
> included the symbols conflict.
>
> This patch changes LOG_DEBUG to VHOST_LOG_DEBUG.
>
> Fixes: 1c01d52392d5 ("vhost: add debug print")
> Cc: huawei.xie at intel.com
> Cc: stable at dpdk.org
>
> Signed-off-by: Ben Walker <benjamin.walker at intel.com>
> Signed-off-by: Tomasz Kulasek <tomaszx.kulasek at intel.com>
Reviewed-by: Jianfeng Tan <jianfeng.tan at intel.com>
> ---
> lib/librte_vhost/vhost.h | 13 +++++++------
> lib/librte_vhost/vhost_user.c | 10 +++++-----
> lib/librte_vhost/virtio_net.c | 16 ++++++++--------
> 3 files changed, 20 insertions(+), 19 deletions(-)
>
> diff --git a/lib/librte_vhost/vhost.h b/lib/librte_vhost/vhost.h
> index d947bc9e3..319cc6620 100644
> --- a/lib/librte_vhost/vhost.h
> +++ b/lib/librte_vhost/vhost.h
> @@ -296,8 +296,9 @@ vhost_log_used_vring(struct virtio_net *dev, struct
> vhost_virtqueue *vq,
>
> #ifdef RTE_LIBRTE_VHOST_DEBUG
> #define VHOST_MAX_PRINT_BUFF 6072
> -#define LOG_LEVEL RTE_LOG_DEBUG
> -#define LOG_DEBUG(log_type, fmt, args...) RTE_LOG(DEBUG, log_type, fmt,
> ##args)
> +#define VHOST_LOG_LEVEL RTE_LOG_DEBUG
Seems that we can remove LOG_LEVEL definition. But it's another issue.
Thanks,
Jianfeng
More information about the dev
mailing list