From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from wes1-so2.wedos.net (wes1-so2.wedos.net [46.28.106.16]) by dpdk.org (Postfix) with ESMTP id 977449A9D for ; Fri, 13 May 2016 17:28:47 +0200 (CEST) Received: from pcviktorin.fit.vutbr.cz (pcviktorin.fit.vutbr.cz [147.229.13.147]) by wes1-so2.wedos.net (Postfix) with ESMTPSA id 3r5tzz336wz4xJ; Fri, 13 May 2016 17:28:47 +0200 (CEST) Date: Fri, 13 May 2016 17:26:59 +0200 From: Jan Viktorin To: Thomas Monjalon Cc: dev@dpdk.org, David Marchand , Bruce Richardson Message-ID: <20160513172659.527e3cb9@pcviktorin.fit.vutbr.cz> In-Reply-To: <1676568.i7hclo24i5@xps13> References: <1462904011-29838-1-git-send-email-viktorin@rehivetech.com> <9394515.aZP2i1zDQW@xps13> <20160512174636.3312061d@pcviktorin.fit.vutbr.cz> <1676568.i7hclo24i5@xps13> Organization: RehiveTech MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH v2 09/11] eal/pci: replace SYSFS_PCI_DEVICES with pci_get_sysfs_path() X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 13 May 2016 15:28:47 -0000 On Thu, 12 May 2016 18:10:07 +0200 Thomas Monjalon wrote: > 2016-05-12 17:46, Jan Viktorin: > > On Thu, 12 May 2016 17:41:22 +0200 > > Thomas Monjalon 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@RehiveTech.com System Architect Web: www.RehiveTech.com RehiveTech Brno, Czech Republic