Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp3172321ybi; Fri, 5 Jul 2019 03:08:07 -0700 (PDT) X-Google-Smtp-Source: APXvYqw9j02BqYCu347W0uHaogN2sjN7M9J7x2ocSFXf/57VCFuJ5wjRd4j9dvYq9prWZ9x8/tpx X-Received: by 2002:a65:4087:: with SMTP id t7mr4443978pgp.10.1562321287812; Fri, 05 Jul 2019 03:08:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562321287; cv=none; d=google.com; s=arc-20160816; b=kQcEz/0TSSJG0FdHlcCHtaAFOipkQQT2X9sFhMYtTvqd2sOECeGafIu/bbbTkDEYcP 758LJUN8asyyKzd8tutXRrSNBRrN8e85B+zA7tzpbhfawWkw1BHJtJxilYHsA49Lp46+ hBy+AKVoE1SV8o9+CY+Q+c2HGMiXVcrUhgHUExZ2Shb+Qi8FGM254OZlOb0JJCn9RyYA hubh/gD1A0OP4CjVK1JQDck39xtnsOgDS04M12npIcEop/uHuFccyWbtz8hnxOLaPj28 QCKT91IdmS0/+b5gAT7nS/3PiL5JjZRvS0U92xV8bhUAB+KeTBiBEcDT3kI2/TUl22U7 bBLg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=zzxzBl1tKIhqC/tIl+XgNG2GFDsYuIVmeww9JdDXP3Q=; b=F4l8i12+RA0kWSpFtOJDAfBVgTii85HprDG/4gtS+/PaqET1TjWuiKwsYJmfUAAX+a kSCqF77v7ZRapjy5P9YXlM/cZp5c0MV47U9mRhaf/l/sio8YXwNewDd5uhjDpMp2Rw3o N2sMSE3NomNnCu4j2zTUXZ+mGMN/Lsn/Uac2NXQFIKxOPynlrZxP7PGIArctC/6DfYb6 K0c6Ulbv4J+CXdNhr0NAS5b816r5TQ/dX+6UAdPmVxcHhpqt1gxrzqjIyjFwHVZa93W1 UjsVeTOiv+OPrY4prDbFGewdx95ble6viFoHugsYkngHkb+MSbxEHnQMMYzBVfjYBkBF a4eg== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o72si8291343pje.87.2019.07.05.03.07.52; Fri, 05 Jul 2019 03:08:07 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728102AbfGEKHS (ORCPT + 99 others); Fri, 5 Jul 2019 06:07:18 -0400 Received: from inva021.nxp.com ([92.121.34.21]:48008 "EHLO inva021.nxp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727667AbfGEKHO (ORCPT ); Fri, 5 Jul 2019 06:07:14 -0400 Received: from inva021.nxp.com (localhost [127.0.0.1]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id 9F80420070A; Fri, 5 Jul 2019 12:07:12 +0200 (CEST) Received: from invc005.ap-rdc01.nxp.com (invc005.ap-rdc01.nxp.com [165.114.16.14]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id 209B3200044; Fri, 5 Jul 2019 12:07:04 +0200 (CEST) Received: from titan.ap.freescale.net (TITAN.ap.freescale.net [10.192.208.233]) by invc005.ap-rdc01.nxp.com (Postfix) with ESMTP id 0D3114030E; Fri, 5 Jul 2019 18:06:51 +0800 (SGT) From: Hou Zhiqiang To: linux-pci@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, bhelgaas@google.com, robh+dt@kernel.org, mark.rutland@arm.com, l.subrahmanya@mobiveil.co.in, shawnguo@kernel.org, leoyang.li@nxp.com, lorenzo.pieralisi@arm.com, catalin.marinas@arm.com, will.deacon@arm.com Cc: Mingkai.Hu@nxp.com, Minghuan.Lian@nxp.com, Xiaowei.Bao@nxp.com, Hou Zhiqiang Subject: [PATCHv6 05/28] PCI: mobiveil: Use WIN_NUM_0 explicitly for CFG outbound window Date: Fri, 5 Jul 2019 17:56:33 +0800 Message-Id: <20190705095656.19191-6-Zhiqiang.Hou@nxp.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20190705095656.19191-1-Zhiqiang.Hou@nxp.com> References: <20190705095656.19191-1-Zhiqiang.Hou@nxp.com> X-Virus-Scanned: ClamAV using ClamSMTP Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org As the .map_bus() use the WIN_NUM_0 for CFG transactions, it is appropriate to pass WIN_NUM_0 explicitly when initializing the CFG outbound window rather than implicitly relying on the ob_wins_configure counter. Signed-off-by: Hou Zhiqiang Signed-off-by: Lorenzo Pieralisi Reviewed-by: Minghuan Lian Reviewed-by: Subrahmanya Lingappa --- V6: - Rebased the patch, no functional change. drivers/pci/controller/pcie-mobiveil.c | 5 ++--- 1 files changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/pci/controller/pcie-mobiveil.c b/drivers/pci/controller/pcie-mobiveil.c index c359654..0f41c23 100644 --- a/drivers/pci/controller/pcie-mobiveil.c +++ b/drivers/pci/controller/pcie-mobiveil.c @@ -604,9 +604,8 @@ static int mobiveil_host_init(struct mobiveil_pcie *pcie) */ /* config outbound translation window */ - program_ob_windows(pcie, pcie->ob_wins_configured, - pcie->ob_io_res->start, 0, CFG_WINDOW_TYPE, - resource_size(pcie->ob_io_res)); + program_ob_windows(pcie, WIN_NUM_0, pcie->ob_io_res->start, 0, + CFG_WINDOW_TYPE, resource_size(pcie->ob_io_res)); /* memory inbound translation window */ program_ib_windows(pcie, WIN_NUM_1, 0, MEM_WINDOW_TYPE, IB_WIN_SIZE); -- 1.7.1