[AMD Official Use Only - Internal Distribution Only] Thank you David, Ferruh, I pushed v4 of the patch with changes.
Thanks and Regards Selwin Sebastian -----Original Message----- From: Ferruh Yigit <ferruh.yi...@intel.com> Sent: Tuesday, January 14, 2020 6:48 PM To: David Marchand <david.march...@redhat.com>; Sebastian, Selwin <selwin.sebast...@amd.com> Cc: dev <dev@dpdk.org>; Thomas Monjalon <tho...@monjalon.net> Subject: Re: [PATCH v3] drivers: add a HW quirk for register definitions [CAUTION: External Email] On 1/14/2020 12:35 PM, David Marchand wrote: > On Tue, Jan 14, 2020 at 12:58 PM Selwin Sebastian > <selwin.sebast...@amd.com> wrote: >> >> V1000/R1000 processors are using the same PCI ids for the network >> device as SNOWYOWL processor but has altered register definitions for >> determining the window settings for the indirect PCS access. >> Add support to check for this hardware and if found use the new >> register values. >> >> Added a new routine rte_pci_search_device to pci driver to search for >> a device. > > You can already iterate on a bus devices. > > struct rte_bus *pci_bus = rte_bus_find_by_name("pci"); return pci_bus > != NULL && pci_bus->find_device(NULL, callback, args) != NULL; > > See: > https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgit. > dpdk.org%2Fdpdk%2Ftree%2Fdrivers%2Fbus%2Fpci%2Fpci_params.c%23n38& > data=02%7C01%7CSelwin.Sebastian%40amd.com%7C35db24f051c546e2d13b08d798 > f438b5%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637146047002796925 > &sdata=6wBRIab3588iwCsgBV7JJ%2FjcXU5no1mKQtHxbFxJJlc%3D&reserv > ed=0 > Nice, this looks better approach.