[dpdk-dev] [PATCH v9 1/6] eal: replace usage of blacklist/whitelist in enum

Luca Boccassi bluca at debian.org
Tue Nov 10 17:46:52 CET 2020


On Tue, 2020-11-10 at 08:40 -0800, Stephen Hemminger wrote:
> On Tue, 10 Nov 2020 12:33:48 +0000
> Luca Boccassi <bluca at debian.org> wrote:
> 
> > On Thu, 2020-11-05 at 14:35 -0800, Stephen Hemminger wrote:
> > > This patch renames the enum values in the EAL include files.
> > > As a backward compatible temporary migration tool, define
> > > a replacement mapping for old values.
> > > 
> > > The old names relating to blacklist and whitelist are replaced
> > > by block list and allow list, but applications may be using the
> > > older compatibility macros. To help with conversion to new names
> > > cause a message when the compatibility names are used.
> > > 
> > > Signed-off-by: Stephen Hemminger <stephen at networkplumber.org>
> > > Acked-by: Luca Boccassi <bluca at debian.org>
> > > Acked-by: Gaetan Rivet <grive at u256.net>
> > > ---
> > >  lib/librte_eal/common/eal_common_devargs.c | 14 +++++++-------
> > >  lib/librte_eal/include/rte_bus.h           | 10 ++++++++--
> > >  lib/librte_eal/include/rte_dev.h           | 10 ++++++++--
> > >  lib/librte_eal/include/rte_devargs.h       | 10 ++++++++--
> > >  4 files changed, 31 insertions(+), 13 deletions(-)  
> > 
> > <..>
> > 
> > > diff --git a/lib/librte_eal/include/rte_devargs.h b/lib/librte_eal/include/rte_devargs.h
> > > index 898efa0d667b..296f19324fae 100644
> > > --- a/lib/librte_eal/include/rte_devargs.h
> > > +++ b/lib/librte_eal/include/rte_devargs.h
> > > @@ -29,11 +29,17 @@ extern "C" {
> > >   * Type of generic device
> > >   */
> > >  enum rte_devtype {
> > > -	RTE_DEVTYPE_WHITELISTED_PCI,
> > > -	RTE_DEVTYPE_BLACKLISTED_PCI,
> > > +	RTE_DEVTYPE_ALLOWED,
> > > +	RTE_DEVTYPE_BLOCKED,
> > >  	RTE_DEVTYPE_VIRTUAL,  
> > 
> > Any particular reason to drop the _PCI suffix from the enums and
> > command line parameters? Does it apply to more than PCI devices
> > nowadays?
> 
> Yes, block/allow also works for VMBus devices and and I think other
> busses use it as well.

Ok, makes sense, thanks.

-- 
Kind regards,
Luca Boccassi


More information about the dev mailing list