All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ixgbe: fix build with bypass and debug enabled
@ 2014-12-01 17:40 Thomas Monjalon
       [not found] ` <1417455659-24854-1-git-send-email-thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Thomas Monjalon @ 2014-12-01 17:40 UTC (permalink / raw)
  To: dev-VfR2kkLFssw

Since commit aae1047905621 ("use the right debug macro"),
DEBUGOUT was replaced by PMD_DRV_LOG which requires at least
2 arguments. But the level argument was missing.

Commit 7a10de5e27 fixed the logs but not the macros FUNC_PTR_OR_*
which are not preprocessed if RTE_LIBRTE_IXGBE_DEBUG_DRIVER is disabled.

Signed-off-by: Thomas Monjalon <thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
---
 lib/librte_pmd_ixgbe/ixgbe_bypass.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/librte_pmd_ixgbe/ixgbe_bypass.c b/lib/librte_pmd_ixgbe/ixgbe_bypass.c
index 15203a4..832f415 100644
--- a/lib/librte_pmd_ixgbe/ixgbe_bypass.c
+++ b/lib/librte_pmd_ixgbe/ixgbe_bypass.c
@@ -42,7 +42,7 @@
 /* Macros to check for invlaid function pointers. */
 #define	FUNC_PTR_OR_ERR_RET(func, retval) do {              \
 	if ((func) == NULL) {                               \
-		PMD_DRV_LOG("%s:%d function not supported", \
+		PMD_DRV_LOG(ERR, "%s:%d function not supported", \
 			    __func__, __LINE__);            \
 		return retval;                            \
 	}                                                   \
@@ -50,7 +50,7 @@
 
 #define	FUNC_PTR_OR_RET(func) do {                          \
 	if ((func) == NULL) {                               \
-		PMD_DRV_LOG("%s:%d function not supported", \
+		PMD_DRV_LOG(ERR, "%s:%d function not supported", \
 			    __func__, __LINE__);            \
 		return;                                     \
 	}                                                   \
-- 
2.1.3

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] ixgbe: fix build with bypass and debug enabled
       [not found] ` <1417455659-24854-1-git-send-email-thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
@ 2014-12-01 20:07   ` David Marchand
       [not found]     ` <CALwxeUu3w1nJbKedtwSbqZzDvfG8kO5xEEUkSd0Rk13pSjdmWA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: David Marchand @ 2014-12-01 20:07 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: dev-VfR2kkLFssw

On Mon, Dec 1, 2014 at 6:40 PM, Thomas Monjalon <thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
wrote:

> Since commit aae1047905621 ("use the right debug macro"),
> DEBUGOUT was replaced by PMD_DRV_LOG which requires at least
> 2 arguments. But the level argument was missing.
>
> Commit 7a10de5e27 fixed the logs but not the macros FUNC_PTR_OR_*
> which are not preprocessed if RTE_LIBRTE_IXGBE_DEBUG_DRIVER is disabled.
>
> Signed-off-by: Thomas Monjalon <thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
> ---
>  lib/librte_pmd_ixgbe/ixgbe_bypass.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/lib/librte_pmd_ixgbe/ixgbe_bypass.c
> b/lib/librte_pmd_ixgbe/ixgbe_bypass.c
> index 15203a4..832f415 100644
> --- a/lib/librte_pmd_ixgbe/ixgbe_bypass.c
> +++ b/lib/librte_pmd_ixgbe/ixgbe_bypass.c
> @@ -42,7 +42,7 @@
>  /* Macros to check for invlaid function pointers. */
>  #define        FUNC_PTR_OR_ERR_RET(func, retval) do {              \
>         if ((func) == NULL) {                               \
> -               PMD_DRV_LOG("%s:%d function not supported", \
> +               PMD_DRV_LOG(ERR, "%s:%d function not supported", \
>                             __func__, __LINE__);            \
>                 return retval;                            \
>         }                                                   \
> @@ -50,7 +50,7 @@
>
>  #define        FUNC_PTR_OR_RET(func) do {                          \
>         if ((func) == NULL) {                               \
> -               PMD_DRV_LOG("%s:%d function not supported", \
> +               PMD_DRV_LOG(ERR, "%s:%d function not supported", \
>                             __func__, __LINE__);            \
>                 return;                                     \
>         }                                                   \
>
>
>
Argh ... good catch.
Looks like these were the only places with this error (I did some grep and
only found those).
And ok with the ERR level, it looks fine to me.

Ack.
Thanks Thomas.

-- 
David Marchand

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] ixgbe: fix build with bypass and debug enabled
       [not found]     ` <CALwxeUu3w1nJbKedtwSbqZzDvfG8kO5xEEUkSd0Rk13pSjdmWA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2014-12-02 11:28       ` Thomas Monjalon
  0 siblings, 0 replies; 3+ messages in thread
From: Thomas Monjalon @ 2014-12-02 11:28 UTC (permalink / raw)
  To: David Marchand; +Cc: dev-VfR2kkLFssw

> > Since commit aae1047905621 ("use the right debug macro"),
> > DEBUGOUT was replaced by PMD_DRV_LOG which requires at least
> > 2 arguments. But the level argument was missing.
> >
> > Commit 7a10de5e27 fixed the logs but not the macros FUNC_PTR_OR_*
> > which are not preprocessed if RTE_LIBRTE_IXGBE_DEBUG_DRIVER is disabled.
> >
> > Signed-off-by: Thomas Monjalon <thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
> 
> Argh ... good catch.
> Looks like these were the only places with this error (I did some grep and
> only found those).
> And ok with the ERR level, it looks fine to me.
> 
> Ack.

Applied

-- 
Thomas

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-12-02 11:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-12-01 17:40 [PATCH] ixgbe: fix build with bypass and debug enabled Thomas Monjalon
     [not found] ` <1417455659-24854-1-git-send-email-thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
2014-12-01 20:07   ` David Marchand
     [not found]     ` <CALwxeUu3w1nJbKedtwSbqZzDvfG8kO5xEEUkSd0Rk13pSjdmWA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-12-02 11:28       ` Thomas Monjalon

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.