[dpdk-dev] [PATCH v2 09/11] eal/pci: replace SYSFS_PCI_DEVICES with pci_get_sysfs_path()
Jan Viktorin
viktorin at rehivetech.com
Fri May 13 17:26:59 CEST 2016
On Thu, 12 May 2016 18:10:07 +0200
Thomas Monjalon <thomas.monjalon at 6wind.com> wrote:
> 2016-05-12 17:46, Jan Viktorin:
> > On Thu, 12 May 2016 17:41:22 +0200
> > Thomas Monjalon <thomas.monjalon at 6wind.com> wrote:
> > > 2016-05-10 20:13, Jan Viktorin:
> > > > + orig = pci_get_sysfs_path();
> > > > + ret = setenv("SYSFS_PCI_DEVICES", "My Documents", 1);
> > >
> > > Oh no!
> >
> > Not sure about your reaction...
>
> MS reference... ;)
>
> > >
> > > > + TEST_ASSERT_SUCCESS(ret, "Failed setenv to My Documents");
> > > > +
> > > > + path = pci_get_sysfs_path();
> > > > + TEST_ASSERT(strcmp(orig, path),
> > > > + "orig must be different from path: "
> > >
> > > I missed something here. Why different?
> >
> > Because I've set it to "My Documents" and want to be sure that the
> > pci_get_sysfs_path() returns the new path instead of the default
> > one.
> >
> > Perhaps, !strcmp(path, "My Documents") would be better here...
>
> No, just rethink the variable names maybe.
Fixed for v3 as a combination of both.
--
Jan Viktorin E-mail: Viktorin at RehiveTech.com
System Architect Web: www.RehiveTech.com
RehiveTech
Brno, Czech Republic
More information about the dev
mailing list