[dpdk-dev] [PATCH v4 1/5] devargs: unify scratch buffer storage

Xueming(Steven) Li xuemingl at nvidia.com
Mon Apr 12 14:07:49 CEST 2021



> -----Original Message-----
> From: Tal Shnaiderman <talshn at nvidia.com>
> Sent: Sunday, April 11, 2021 4:00 AM
> To: Xueming(Steven) Li <xuemingl at nvidia.com>; NBU-Contact-Thomas Monjalon <thomas at monjalon.net>; Gaetan Rivet
> <gaetanr at nvidia.com>
> Cc: dev at dpdk.org; Xueming(Steven) Li <xuemingl at nvidia.com>; Asaf Penso <asafp at nvidia.com>; Wenzhuo Lu
> <wenzhuo.lu at intel.com>; Beilei Xing <beilei.xing at intel.com>; Bernard Iremonger <bernard.iremonger at intel.com>; Gaetan Rivet
> <grive at u256.net>; Anatoly Burakov <anatoly.burakov at intel.com>; Dmitry Kozlyuk <dmitry.kozliuk at gmail.com>; Narcisa Ana Maria
> Vasile <navasile at linux.microsoft.com>; Dmitry Malloy <dmitrym at microsoft.com>; Pallavi Kadam <pallavi.kadam at intel.com>; Ray
> Kinsella <mdr at ashroe.eu>; Neil Horman <nhorman at tuxdriver.com>; Ferruh Yigit <ferruh.yigit at intel.com>; Andrew Rybchenko
> <andrew.rybchenko at oktetlabs.ru>
> Subject: RE: [dpdk-dev] [PATCH v4 1/5] devargs: unify scratch buffer storage
> 
> > Subject: [dpdk-dev] [PATCH v4 1/5] devargs: unify scratch buffer
> > storage
> >
> > In current design, legacy parser rte_devargs_parse() saved scratch
> > buffer to devargs.args while new parser rte_devargs_layers_parse()
> > saved to devargs.data. Code using devargs had to know the difference
> > and cleaned up memory accordingly - error prone.
> >
> > This patch unifies scratch buffer to data field, introduces
> > rte_devargs_reset() function to wrap the memory clean up logic.
> >
> > Signed-off-by: Xueming Li <xuemingl at nvidia.com>
> > Acked-by: Ray Kinsella <mdr at ashroe.eu>
> > Reviewed-by: Gaetan Rivet <grive at u256.net>
> > ---
> >  app/test-pmd/config.c                        |  3 +-
> >  app/test-pmd/testpmd.c                       |  5 +--
> >  drivers/bus/vdev/vdev.c                      |  9 +++---
> >  drivers/net/failsafe/failsafe_args.c         |  3 +-
> >  drivers/net/failsafe/failsafe_eal.c          |  2 +-
> >  examples/multi_process/hotplug_mp/commands.c |  6 ++--
> >  lib/librte_eal/common/eal_common_dev.c       |  9 +++---
> >  lib/librte_eal/common/eal_common_devargs.c   | 34 +++++++++++---------
> >  lib/librte_eal/common/hotplug_mp.c           |  6 ++--
> >  lib/librte_eal/include/rte_devargs.h         | 18 ++++++++---
> >  lib/librte_eal/rte_eal_exports.def           |  1 +
> 
> rte_eal_exports.def was united with version.map and removed thus the modification above is unneeded.

Thanks, I'll rebase my code :)

> 
> >  lib/librte_eal/version.map                   |  1 +
> >  lib/librte_ethdev/rte_ethdev.c               |  8 ++---
> >  13 files changed, 59 insertions(+), 46 deletions(-)


More information about the dev mailing list