From patchwork Tue Dec 1 07:24:31 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Horman X-Patchwork-Id: 7733531 X-Patchwork-Delegate: horms@verge.net.au Return-Path: X-Original-To: patchwork-linux-sh@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 8944E9F30B for ; Tue, 1 Dec 2015 07:25:16 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id B025C200DE for ; Tue, 1 Dec 2015 07:25:15 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DC8F6206AC for ; Tue, 1 Dec 2015 07:25:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755405AbbLAHZK (ORCPT ); Tue, 1 Dec 2015 02:25:10 -0500 Received: from kirsty.vergenet.net ([202.4.237.240]:42978 "EHLO kirsty.vergenet.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755157AbbLAHZI (ORCPT ); Tue, 1 Dec 2015 02:25:08 -0500 Received: from reginn.isobedori.kobe.vergenet.net (p5254-ipbfp1403kobeminato.hyogo.ocn.ne.jp [114.152.48.254]) by kirsty.vergenet.net (Postfix) with ESMTPA id CC06625BE5B; Tue, 1 Dec 2015 18:24:59 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=verge.net.au; s=mail; t=1448954699; bh=Jdwi+Tkh1m6ygOibG6oeddBW5PCbK1fchkgKcL83GkM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Ku7uUCYl10nhxV2zfAeySvK5P3s7udU+N84eJ3LzwMvHptyJbTd9P5latzxklw/xK BAx65vEuLChZOq8lNzZ7L/LcXO+yhtXmTe04OUSOQvdnOWB+bXKGDtHlpvpX9c4BBT Lzz4yrKUCWpl2yLWQIMWQYVphJkngWA0U6CRTVdQ= Received: by reginn.isobedori.kobe.vergenet.net (Postfix, from userid 7100) id CDF27940924; Tue, 1 Dec 2015 16:24:58 +0900 (JST) From: Simon Horman To: Bjorn Helgaas Cc: Magnus Damm , linux-pci@vger.kernel.org, linux-sh@vger.kernel.org, devicetree@vger.kernel.org, Simon Horman Subject: [PATCH 3/4] PCI: rcar: Add Gen2 fallback compatibility string Date: Tue, 1 Dec 2015 16:24:31 +0900 Message-Id: <1448954672-27236-4-git-send-email-horms+renesas@verge.net.au> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1448954672-27236-1-git-send-email-horms+renesas@verge.net.au> References: <1448954672-27236-1-git-send-email-horms+renesas@verge.net.au> Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID,T_RP_MATCHES_RCVD,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add fallback compatibility string for R-Car Gen 2 Family. This is in keeping with the fallback scheme being adopted wherever appropriate for drivers for Renesas SoCs. Signed-off-by: Simon Horman Acked-by: Bjorn Helgaas --- Documentation/devicetree/bindings/pci/rcar-pci.txt | 13 ++++++++++--- drivers/pci/host/pcie-rcar.c | 1 + 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/Documentation/devicetree/bindings/pci/rcar-pci.txt b/Documentation/devicetree/bindings/pci/rcar-pci.txt index 29d3b989d3b0..872cea085be8 100644 --- a/Documentation/devicetree/bindings/pci/rcar-pci.txt +++ b/Documentation/devicetree/bindings/pci/rcar-pci.txt @@ -1,8 +1,15 @@ * Renesas RCar PCIe interface Required properties: -- compatible: should contain one of the following - "renesas,pcie-r8a7779", "renesas,pcie-r8a7790", "renesas,pcie-r8a7791" +compatible: "renesas,pcie-r8a7779" for the R8A7779 SoC; + "renesas,pcie-r8a7790" for the R8A7790 SoC; + "renesas,pcie-r8a7791" for the R8A7791 SoC; + "renesas,pcie-gen2" for a generic R-Car Gen2 compatible device. + + When compatible with the generic version, nodes must list the + SoC-specific version corresponding to the platform first + followed by the generic version. + - reg: base address and length of the pcie controller registers. - #address-cells: set to <3> - #size-cells: set to <2> @@ -25,7 +32,7 @@ Example: SoC specific DT Entry: pcie: pcie@fe000000 { - compatible = "renesas,pcie-r8a7791"; + compatible = "renesas,pcie-r8a7791", "renesas,pcie-gen2"; reg = <0 0xfe000000 0 0x80000>; #address-cells = <3>; #size-cells = <2>; diff --git a/drivers/pci/host/pcie-rcar.c b/drivers/pci/host/pcie-rcar.c index f4fa6c537448..17ee0422ddb1 100644 --- a/drivers/pci/host/pcie-rcar.c +++ b/drivers/pci/host/pcie-rcar.c @@ -917,6 +917,7 @@ static int rcar_pcie_parse_map_dma_ranges(struct rcar_pcie *pcie, static const struct of_device_id rcar_pcie_of_match[] = { { .compatible = "renesas,pcie-r8a7779", .data = rcar_pcie_hw_init_h1 }, + { .compatible = "renesas,pcie-gen2", .data = rcar_pcie_hw_init }, { .compatible = "renesas,pcie-r8a7790", .data = rcar_pcie_hw_init }, { .compatible = "renesas,pcie-r8a7791", .data = rcar_pcie_hw_init }, {},