From patchwork Mon Sep 28 01:05:33 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kunihiko Hayashi X-Patchwork-Id: 313608 Delivered-To: patch@linaro.org Received: by 2002:a92:5ad1:0:0:0:0:0 with SMTP id b78csp2908992ilg; Sun, 27 Sep 2020 18:06:02 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwT6ydSFkqkzT24lLRZwEPWs+kpy8WB1AfAg7a3GjRzJtVEp8IM5o7IXPcKu4+uRMMB19qg X-Received: by 2002:a17:906:fb97:: with SMTP id lr23mr13654988ejb.257.1601255162206; Sun, 27 Sep 2020 18:06:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601255162; cv=none; d=google.com; s=arc-20160816; b=u29Kfd2C245ZOH8Bd/stLoPgW7Chia7vehS3oiiZGSxvoIODIp3fR1k7F+5bByidhE DdJ5ZK5VhzG6H58M9+vUHzHAa4um1cTXKoW+HBsoKz9/C8MozeCxhMjS2NsLWixfd9iC J7WtzNSDvmc6+gfilXlbU057VqlKZoto3eGEXz2j0EKqO4614ITbBkUdUk+OBQzFoKBS gPg1W2uHrU5+L+9QSrgCnvZuQ/qf+bsiPjlgknlOQA4Q1INAlCUwjXc2rud/hlNvxG+k y5Pp7+jjMJvxuVc/vjYl/ZKAQK51j9m+u72/tzpR2YcRB7y/RECnc4Lqcs+6UgngL1zc AKGw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:in-reply-to:message-id:date:subject :cc:to:from; bh=MjgpR+8h5BSnvv413pasOZjVJZaCAYRQuI/SGPztFiY=; b=QB1fnmgF0ussoZuxpS7TDG3+HBIflcK87IZJ6t1ViUw144NccnE/BhjyIEtOKkY629 Z0x+q0akIj8AbKlcC6MXGaTmHsukOAKGBVV4eQft5jB4hT/AK4w+l1IpKDizyqh01TiX tljLAFcwYecXoWBFOCh08Lsbtpo48gDQxJrgXbUtf5E0oRaoQ+imroSqkrwwT+g7g2Wj k/gVknuBlgkUsTqs6SEIVJob1PitUWmzt9u5mWa0sBygy2OFXeQV28gFspp2agWMxLh5 lIDpNvwzTNZYin5h2D4RMIIb90Xb8Y9UsRhOoCeswqRtmZzEKtbBMqMPccUEvq4R0VQQ YVBA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u16si6740492edr.507.2020.09.27.18.06.02; Sun, 27 Sep 2020 18:06:02 -0700 (PDT) Received-SPF: pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726601AbgI1BF5 (ORCPT + 6 others); Sun, 27 Sep 2020 21:05:57 -0400 Received: from mx.socionext.com ([202.248.49.38]:27549 "EHLO mx.socionext.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726559AbgI1BFt (ORCPT ); Sun, 27 Sep 2020 21:05:49 -0400 Received: from unknown (HELO kinkan-ex.css.socionext.com) ([172.31.9.52]) by mx.socionext.com with ESMTP; 28 Sep 2020 10:05:45 +0900 Received: from mail.mfilter.local (m-filter-2 [10.213.24.62]) by kinkan-ex.css.socionext.com (Postfix) with ESMTP id B0BED180BE1; Mon, 28 Sep 2020 10:05:45 +0900 (JST) Received: from 172.31.9.51 (172.31.9.51) by m-FILTER with ESMTP; Mon, 28 Sep 2020 10:05:45 +0900 Received: from plum.e01.socionext.com (unknown [10.213.132.32]) by kinkan.css.socionext.com (Postfix) with ESMTP id 6F0251A0507; Mon, 28 Sep 2020 10:05:45 +0900 (JST) From: Kunihiko Hayashi To: Rob Herring , Bjorn Helgaas , Lorenzo Pieralisi , Jingoo Han , Gustavo Pimentel , Murali Karicheri Cc: linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Masami Hiramatsu , Jassi Brar , Kunihiko Hayashi Subject: [PATCH v2 4/4] PCI: keystone: Remove iATU register mapping Date: Mon, 28 Sep 2020 10:05:33 +0900 Message-Id: <1601255133-17715-5-git-send-email-hayashi.kunihiko@socionext.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1601255133-17715-1-git-send-email-hayashi.kunihiko@socionext.com> References: <1601255133-17715-1-git-send-email-hayashi.kunihiko@socionext.com> Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org After applying "PCI: dwc: Add common iATU register support", there is no need to set own iATU in the Keystone driver itself. Cc: Murali Karicheri Cc: Jingoo Han Cc: Gustavo Pimentel Suggested-by: Rob Herring Signed-off-by: Kunihiko Hayashi Reviewed-by: Rob Herring --- drivers/pci/controller/dwc/pci-keystone.c | 20 ++++---------------- 1 file changed, 4 insertions(+), 16 deletions(-) -- 2.7.4 diff --git a/drivers/pci/controller/dwc/pci-keystone.c b/drivers/pci/controller/dwc/pci-keystone.c index b554812..a222728 100644 --- a/drivers/pci/controller/dwc/pci-keystone.c +++ b/drivers/pci/controller/dwc/pci-keystone.c @@ -1154,7 +1154,6 @@ static int __init ks_pcie_probe(struct platform_device *pdev) struct keystone_pcie *ks_pcie; struct device_link **link; struct gpio_desc *gpiod; - void __iomem *atu_base; struct resource *res; unsigned int version; void __iomem *base; @@ -1275,23 +1274,12 @@ static int __init ks_pcie_probe(struct platform_device *pdev) goto err_get_sync; } - if (pci->version >= 0x480A) { - atu_base = devm_platform_ioremap_resource_byname(pdev, "atu"); - if (IS_ERR(atu_base)) { - ret = PTR_ERR(atu_base); - goto err_get_sync; - } - - pci->atu_base = atu_base; - + if (pci->version >= 0x480A) ret = ks_pcie_am654_set_mode(dev, mode); - if (ret < 0) - goto err_get_sync; - } else { + else ret = ks_pcie_set_mode(dev); - if (ret < 0) - goto err_get_sync; - } + if (ret < 0) + goto err_get_sync; switch (mode) { case DW_PCIE_RC_TYPE: