[dpdk-dev] [RFC v1 0/3] show the Rx/Tx burst description field

Stephen Hemminger stephen at networkplumber.org
Mon Aug 12 17:54:14 CEST 2019


On Mon, 12 Aug 2019 15:42:45 +0000
"Wang, Haiyue" <haiyue.wang at intel.com> wrote:

> > -----Original Message-----
> > From: Stephen Hemminger [mailto:stephen at networkplumber.org]
> > Sent: Monday, August 12, 2019 23:38
> > To: David Marchand <david.marchand at redhat.com>
> > Cc: Wang, Haiyue <haiyue.wang at intel.com>; dev <dev at dpdk.org>
> > Subject: Re: [dpdk-dev] [RFC v1 0/3] show the Rx/Tx burst description field
> > 
> > On Mon, 12 Aug 2019 16:27:11 +0200
> > David Marchand <david.marchand at redhat.com> wrote:
> >   
> > > On Mon, Aug 12, 2019 at 4:20 PM Haiyue Wang <haiyue.wang at intel.com> wrote:  
> > > >
> > > > Since some PMDs have multi-path for Rx/Tx, FD.io VPP will tell you in
> > > > the Debug CLI what rx/tx function is being used:
> > > >         #show hardware-interface
> > > >
> > > >          tx burst function: ice_xmit_pkts
> > > >          rx burst function: ice_recv_scattered_pkts
> > > >
> > > > But if the tx/rx is static, then 'dladdr' will return nil:
> > > >
> > > >          tx burst function: (nil) │······················
> > > >          rx burst function: (nil) │······················
> > > >
> > > > For making things consistent and gracefull, we introduce an new string
> > > > field to describe the Rx/Tx burst information. This is vendor-neutral,
> > > > it is used to identify the Rx/Tx burst selection if the PMD has more
> > > > than one.
> > > >
> > > > If a PMD supports this, then rxqinfo/txqinfo->burst_info[0] != '\0'.  
> > >
> > > The rx/tx handlers are the same for all queues of a ethdev port.
> > > What is the added value to put this in a per queue api ?  
> > 
> > With some symbol table lookup tools it is possible to do introspection
> > to find the symbol from the function pointer. Without breaking API/ABI.  
> 
> Sounds cool, any link can be reached ?
> 
> VPP uses as below, but will fail for static function.
> 
> static const char *
> ptr2sname (void *p)
> {
>   Dl_info info = { 0 };
> 
>   if (dladdr (p, &info) == 0)
>     return 0;
> 
>   return info.dli_sname;
> }

You need to link with -g and not strip the binary.


More information about the dev mailing list