Hi Chenbo, Thanks for your reply. I will send V3 patch to address your 2 comments.
> -----Original Message----- > From: Xia, Chenbo <chenbo....@intel.com> > Sent: Friday, September 9, 2022 8:29 AM > To: Pei, Andy <andy....@intel.com>; dev@dpdk.org > Cc: Xu, Rosen <rosen...@intel.com>; Huang, Wei <wei.hu...@intel.com>; Cao, > Gang <gang....@intel.com>; maxime.coque...@redhat.com; Huang Wei > <wei_hu...@intel.com> > Subject: RE: [PATCH v2 1/8] vdpa/ifc: add new device ID > > Hi Andy, > > > -----Original Message----- > > From: Pei, Andy <andy....@intel.com> > > Sent: Thursday, September 8, 2022 1:54 PM > > To: dev@dpdk.org > > Cc: Xia, Chenbo <chenbo....@intel.com>; Xu, Rosen > > <rosen...@intel.com>; Huang, Wei <wei.hu...@intel.com>; Cao, Gang > > <gang....@intel.com>; maxime.coque...@redhat.com; Huang Wei > > <wei_hu...@intel.com> > > Subject: [PATCH v2 1/8] vdpa/ifc: add new device ID > > Title could be: add new device ID for legacy network device > > > > > From: Huang Wei <wei_hu...@intel.com> > > > > Add new device id to support IFCVF_NET_TRANSITIONAL_DEVICE_ID (0x1000). > > > > Signed-off-by: Huang Wei <wei_hu...@intel.com> > > Signed-off-by: Andy Pei <andy....@intel.com> > > --- > > drivers/vdpa/ifc/base/ifcvf.h | 4 +++- drivers/vdpa/ifc/ifcvf_vdpa.c > > | 9 ++++++++- > > 2 files changed, 11 insertions(+), 2 deletions(-) > > > > diff --git a/drivers/vdpa/ifc/base/ifcvf.h > > b/drivers/vdpa/ifc/base/ifcvf.h index 9d95aac..7ede738 100644 > > --- a/drivers/vdpa/ifc/base/ifcvf.h > > +++ b/drivers/vdpa/ifc/base/ifcvf.h > > @@ -12,11 +12,13 @@ > > #define IFCVF_BLK 1 > > > > #define IFCVF_VENDOR_ID 0x1AF4 > > -#define IFCVF_NET_DEVICE_ID 0x1041 > > +#define IFCVF_NET_MODERN_DEVICE_ID 0x1041 > > #define IFCVF_BLK_MODERN_DEVICE_ID 0x1042 > > +#define IFCVF_NET_TRANSITIONAL_DEVICE_ID 0x1000 > > #define IFCVF_BLK_TRANSITIONAL_DEVICE_ID 0x1001 > > #define IFCVF_SUBSYS_VENDOR_ID 0x8086 > > #define IFCVF_SUBSYS_DEVICE_ID 0x001A > > +#define IFCVF_NET_DEVICE_ID 0x0001 > > For subsystem device ID, I suggest to add _SUBSYS_, please check all Subsystem > device ID and make all the names well-defined. > > Thanks, > Chenbo > > > #define IFCVF_BLK_DEVICE_ID 0x0002 > > > > #define IFCVF_MAX_QUEUES 1 > > diff --git a/drivers/vdpa/ifc/ifcvf_vdpa.c > > b/drivers/vdpa/ifc/ifcvf_vdpa.c index ac42de9..61d0250 100644 > > --- a/drivers/vdpa/ifc/ifcvf_vdpa.c > > +++ b/drivers/vdpa/ifc/ifcvf_vdpa.c > > @@ -1684,13 +1684,20 @@ struct rte_vdpa_dev_info dev_info[] = { > > static const struct rte_pci_id pci_id_ifcvf_map[] = { > > { .class_id = RTE_CLASS_ANY_ID, > > .vendor_id = IFCVF_VENDOR_ID, > > - .device_id = IFCVF_NET_DEVICE_ID, > > + .device_id = IFCVF_NET_MODERN_DEVICE_ID, > > .subsystem_vendor_id = IFCVF_SUBSYS_VENDOR_ID, > > .subsystem_device_id = IFCVF_SUBSYS_DEVICE_ID, > > }, > > > > { .class_id = RTE_CLASS_ANY_ID, > > .vendor_id = IFCVF_VENDOR_ID, > > + .device_id = IFCVF_NET_TRANSITIONAL_DEVICE_ID, > > + .subsystem_vendor_id = IFCVF_SUBSYS_VENDOR_ID, > > + .subsystem_device_id = IFCVF_NET_DEVICE_ID, > > + }, > > + > > + { .class_id = RTE_CLASS_ANY_ID, > > + .vendor_id = IFCVF_VENDOR_ID, > > .device_id = IFCVF_BLK_TRANSITIONAL_DEVICE_ID, > > .subsystem_vendor_id = IFCVF_SUBSYS_VENDOR_ID, > > .subsystem_device_id = IFCVF_BLK_DEVICE_ID, > > -- > > 1.8.3.1