Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp3068946imm; Fri, 20 Jul 2018 09:35:03 -0700 (PDT) X-Google-Smtp-Source: AAOMgper6f6b64midwuHVp+rApZTOLcbAHlTEv8IyQ/EfXqM49qfOa8yzbrrfwLaXq/pZxHfQkaR X-Received: by 2002:a62:15c8:: with SMTP id 191-v6mr2872981pfv.194.1532104503781; Fri, 20 Jul 2018 09:35:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532104503; cv=none; d=google.com; s=arc-20160816; b=dfmmz+8jqkufg7XBva/lw45vRrG2fuCAoJJCu/XkcJpGy4amgWsn5HfH3TLVXWEUZL eNYHeCtIFKBHhao1zYjQGdkLhFB439jEtOCGNdH2Z1NDjkk6hznCBfa5KVRW9PoH4Jdo ZVommk3T8A6I/Bchs4giEiNRXKjI/wQxLN3wVWSU8DA5HXJUuoN/5mRdw0b49aEFLA/I n0Crl7rALM24hATBIzJ/YmnSJ2zJgIS1OJBhv8umGHW4/tr1pv57EHGAvPnXWTnxgr23 hNljBiHCULKzlnubkM9iFPkgMPrhMlmneiutOs26cp8noEWXe5u3iSwXRoTkR1rpu9xE hwdQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:subject:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:arc-authentication-results; bh=CP/F4A8wgudIdblP44JufUVGDy0DPRkr5vj2CLK0jyk=; b=yDu0gS1qkS5MbKf5K00AhST+gZKGs8wM17Hkh2OYUpbtdfEcdfLJruJwRonFIY+Ggc xfYJCnsKsyMqOQ80003IxLSgigObyJdY0P5jAcRGzCdnYrvA8r6PusWAhDFldVAnZaqo FDxiueygU1sEjM6nNnTUOXkKRWpTygxpdLJQRdCGili5YyEQ5SIoQqAY5ccxZuJ2wP8O 9WsJkfieHC0HtNbtlskDOJl4ZS8WEkBvILbR8kYkmw9nCo7MOSmPIfLfUjXXLE+eWCIq 4hVUorWfb3IIKN8DDPE+Ge1K2p/YuLzAQsyP1rfF3D4X3x5n+6L7JHLPeq8HvscZ7hux jXow== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t16-v6si1955323pgu.487.2018.07.20.09.34.45; Fri, 20 Jul 2018 09:35:03 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388108AbeGTRWz (ORCPT + 99 others); Fri, 20 Jul 2018 13:22:55 -0400 Received: from ale.deltatee.com ([207.54.116.67]:37778 "EHLO ale.deltatee.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387858AbeGTRWz (ORCPT ); Fri, 20 Jul 2018 13:22:55 -0400 Received: from guinness.priv.deltatee.com ([172.16.1.162]) by ale.deltatee.com with esmtp (Exim 4.89) (envelope-from ) id 1fgYLd-0007He-FL; Fri, 20 Jul 2018 10:33:42 -0600 To: Serge Semin Cc: linux-kernel@vger.kernel.org, linux-ntb@googlegroups.com, Jon Mason , Dave Jiang , Allen Hubbe , Shyam Sundar S K , Shuah Khan References: <20180609000819.13883-1-logang@deltatee.com> <20180609000819.13883-10-logang@deltatee.com> <20180615195152.GA25605@mobilestation> From: Logan Gunthorpe Message-ID: <641e5245-9e77-7e8e-aa70-6c7e73636a22@deltatee.com> Date: Fri, 20 Jul 2018 10:33:36 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20180615195152.GA25605@mobilestation> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-SA-Exim-Connect-IP: 172.16.1.162 X-SA-Exim-Rcpt-To: shuah@kernel.org, Shyam-sundar.S-k@amd.com, allenbh@gmail.com, dave.jiang@intel.com, jdmason@kudzu.us, linux-ntb@googlegroups.com, linux-kernel@vger.kernel.org, fancer.lancer@gmail.com X-SA-Exim-Mail-From: logang@deltatee.com X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on ale.deltatee.com X-Spam-Level: X-Spam-Status: No, score=-8.9 required=5.0 tests=ALL_TRUSTED,BAYES_00, GREYLIST_ISWHITE autolearn=ham autolearn_force=no version=3.4.1 Subject: Re: [PATCH 8/8] NTB: ntb_test: Fix bug when counting remote files X-SA-Exim-Version: 4.2.1 (built Tue, 02 Aug 2016 21:08:31 +0000) X-SA-Exim-Scanned: Yes (on ale.deltatee.com) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 15/06/18 01:51 PM, Serge Semin wrote: > I also tested this script in the looped-back setup. It is the case when two > NTB-device ports are available at the same RootComplex. So the NTB can be > configured from the single executional context. In this case the REMOTE_HOST is left > empty, so the colon is left prepended to the corresponding paths and causes multiple > errors including the one fixed by this patch. In order to fix it, we need to discard > the colon for remote-less case, for instance, by the next patch: > > @@ -482,7 +495,11 @@ function perf_test() > function ntb_tool_tests() > { > LOCAL_TOOL="$DEBUGFS/ntb_tool/$LOCAL_DEV" > - REMOTE_TOOL="$REMOTE_HOST:$DEBUGFS/ntb_tool/$REMOTE_DEV" > + if [[ "${REMOTE_HOST}" != "" ]]; then > + REMOTE_TOOL="$REMOTE_HOST:$DEBUGFS/ntb_tool/$REMOTE_DEV" > + else > + REMOTE_TOOL="$DEBUGFS/ntb_tool/$REMOTE_DEV" > + fi > > echo "Starting ntb_tool tests..." > > And so on for REMOTE_PP and REMOTE_PERF. It is necessary for NTB devices, which ports > are looped-back to the same Root-Port. Would you be amenable if you resent this patch > together with the fix I suggested? I took a closer look at this and it's not necessary. (Note: I do the majority of my testing in a looped-back setup). What you didn't notice is that split_remote() separates the colon whether there is a host or not. It's not passed to ssh or cat (or whatever) directly. So the change you propose will actually break the how it was designed. Logan