From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f47.google.com (mail-wm0-f47.google.com [74.125.82.47]) by dpdk.org (Postfix) with ESMTP id EB1FE58F3 for ; Thu, 12 May 2016 18:10:09 +0200 (CEST) Received: by mail-wm0-f47.google.com with SMTP id g17so144392849wme.1 for ; Thu, 12 May 2016 09:10:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:user-agent:in-reply-to :references:mime-version:content-transfer-encoding; bh=cN1oc3lllIylht1q/GyUbQAT6KkrWLF+MJiJ4xCmfX8=; b=d4lGKaxHrnhNUzjZOTinBE5w8pDf9EtestUYR6p6V5da4FBE/u1EZndgHKgmHe0lIN u8N7/H7GJvVohAah36PoiZzn8Pu2cHL+usa2djSivbkzES6vQf1kViKDZb6FWZkBMWyz goNxaIuQFqPtajHB7AWcQhaBfQneXK0lmJTr1rI2ub7hHQT07QRofQ+7rJ8jzu/XhpoZ mvKZzYaLl9pNefD9yp169qyamhNddq4T+xsE4SCH4LzvYcwpcisHyTYXiQzFlzGIIK1V vcr89fceRyN5UON/d9VAgA+FipYXwSvijaE3OHHEm/b2zsSR91mgDCfshuCLGx80/+hE BowQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:user-agent :in-reply-to:references:mime-version:content-transfer-encoding; bh=cN1oc3lllIylht1q/GyUbQAT6KkrWLF+MJiJ4xCmfX8=; b=LNRCw+I3qQ5Inmdg4ABwne4/TAkVtwqjU8AmbrvGAMcSGH4pN0WVu2QVN0RnGlfwdq YK7hdEgSQ3qHL4IUO7tCAYeNGHbhO9JdPgpm7S80PvvZoKEzrBmFYc+sJ2wcul5mjXE9 ojtiefv7wsF8p7o5JNljArE1GkZSqw4l2v8lo8XWpJKlZ6ESczbTqtAJaXrsUXwFHLUv 4a1vkRklK/RXTsUxhoZtRsTTbLwaYgJ48Zb80eAlJBG5zHqH9N+kUi+Vc9vosCpZH0L5 c9ueTWmwcatHcwXARWGN7BS0zSTi8j9F5bDBtoR8Zu22ywUzHmqkVbPSlB+35OJjGpna htsA== X-Gm-Message-State: AOPr4FWoFU2mHemyOgashG+6V7CkHM59YAi4cuKNU0PO3JB/WNUMoYhG9p1yqK9dALLjRxaY X-Received: by 10.195.11.106 with SMTP id eh10mr12223625wjd.130.1463069409765; Thu, 12 May 2016 09:10:09 -0700 (PDT) Received: from xps13.localnet (184.203.134.77.rev.sfr.net. [77.134.203.184]) by smtp.gmail.com with ESMTPSA id a207sm14591894wma.8.2016.05.12.09.10.08 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 12 May 2016 09:10:09 -0700 (PDT) From: Thomas Monjalon To: Jan Viktorin Cc: dev@dpdk.org, David Marchand , Bruce Richardson Date: Thu, 12 May 2016 18:10:07 +0200 Message-ID: <1676568.i7hclo24i5@xps13> User-Agent: KMail/4.14.10 (Linux/4.1.6-1-ARCH; KDE/4.14.11; x86_64; ; ) In-Reply-To: <20160512174636.3312061d@pcviktorin.fit.vutbr.cz> References: <1462904011-29838-1-git-send-email-viktorin@rehivetech.com> <9394515.aZP2i1zDQW@xps13> <20160512174636.3312061d@pcviktorin.fit.vutbr.cz> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" 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: Thu, 12 May 2016 16:10:10 -0000 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.