[dpdk-stable] [dpdk-dev] [PATCH v3] examples/rxtx_callbacks: fix port ID format specifier

Thomas Monjalon thomas at monjalon.net
Wed May 12 21:37:15 CEST 2021


06/05/2021 04:56, Stephen Hemminger:
> On Thu,  6 May 2021 00:54:35 +0300
> Dmitry Kozlyuk <dmitry.kozliuk at gmail.com> wrote:
> 
> > This fixes -Wformat warning with clang 10.0.0 on Windows.
> > 
> > Fixes: f8244c6399d9 ("ethdev: increase port id range")
> > Cc: stable at dpdk.org
> > 
> > Signed-off-by: Dmitry Kozlyuk <dmitry.kozliuk at gmail.com>
> > Acked-by: Tyler Retzlaff <roretzla at linux.microsoft.com>
> > ---
> > v3: PRIx16 -> PRIu16
> > v2: u% and a cast -> PRIx16 (Tyler, Thomas)
> >  examples/rxtx_callbacks/main.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/examples/rxtx_callbacks/main.c b/examples/rxtx_callbacks/main.c
> > index b57b2fc6bc..192521c3c6 100644
> > --- a/examples/rxtx_callbacks/main.c
> > +++ b/examples/rxtx_callbacks/main.c
> > @@ -329,7 +329,7 @@ main(int argc, char *argv[])
> >  	/* initialize all ports */
> >  	RTE_ETH_FOREACH_DEV(portid)
> >  		if (port_init(portid, mbuf_pool) != 0)
> > -			rte_exit(EXIT_FAILURE, "Cannot init port %"PRIu8"\n",
> > +			rte_exit(EXIT_FAILURE, "Cannot init port %"PRIu16"\n",
> >  					portid)
> 
> Ok, that matches what is used in rte_ethdev.h
> 
> Acked-by: Stephen Hemminger <stephen at networkplumber.org>

Applied, thanks




More information about the stable mailing list