Received: by 10.223.185.116 with SMTP id b49csp5595170wrg; Wed, 7 Mar 2018 14:42:16 -0800 (PST) X-Google-Smtp-Source: AG47ELsbjZ9hKxyYSnXumKCYtaSBDv25C68AD6Ffnz+CRTIM4jxYCcGgBNwNGCUtSW5AQBuoekUP X-Received: by 10.99.96.77 with SMTP id u74mr19656432pgb.453.1520462536407; Wed, 07 Mar 2018 14:42:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1520462536; cv=none; d=google.com; s=arc-20160816; b=ogRRV9YgDXi9FrqfHWVOVDQlWo/WlzUWxpH4kx9YBerbnRC6+gobUEiVhsKju24qEg ekLo/5+LentPKBahxl+iw/d+2Pj7XW7qF0e4LRjEyByfssL/3C9unLWgoEtgYWhFca0+ GhxK9lA2/9R5yWK5cJVZnm3dHc4sharNhQasMP+nskh40+CeOIzkMuDxpoujuZEP4eZt VSqAWX25jwD73/Tzlv01sCk9CrbSnxNlJ47S16NXIMZTjSEE/S9fH8I2QHfCwmFXmAcM CpPlqBFWLpEVh/pJAofMQHmFVVCIaHnIJVIbQ4XuMsiWO497NXVZrQRPzs8VYgIly/D6 SJ7g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=3pnOiW156ZRIkIuVH8T81LkPA6AcnfV6htJxIzOGlwA=; b=0AWlBE6XC4FFpFqSBiVuJMqoKj7VpmagQMe/swo9MP0X5/s6nFxnwxnwTmQonrNg/6 9aAxxLU4dGdjmnP1/Uv/OyFKSCC5Emlz/NyHqo47wql/vrtbMxcSUQAPtD2sunUhrkiQ qVzzmN5JoCn08PennxSgVTMypzi9/Fnj8hNYCHZe86smFnkUhGJVKhq//4wtcZnI+1iY Bs/6KuOIfuhlWj5DjWhKSsjC9SES8LJXrocB8gglJX8mD6ZWddJQWukJXLGr1GZEsq90 2llW2qXIoXAaieVtBbJzHn8m2/k4YRwcdOQkD6pgKWS7JTa8r3cDCEkAw4anrerIIdxM FdKA== 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 a1si9462177pfc.147.2018.03.07.14.42.01; Wed, 07 Mar 2018 14:42:16 -0800 (PST) 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 S934346AbeCGWkX (ORCPT + 99 others); Wed, 7 Mar 2018 17:40:23 -0500 Received: from mail-ot0-f196.google.com ([74.125.82.196]:44211 "EHLO mail-ot0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934240AbeCGWkV (ORCPT ); Wed, 7 Mar 2018 17:40:21 -0500 Received: by mail-ot0-f196.google.com with SMTP id 79so3646308oth.11; Wed, 07 Mar 2018 14:40:20 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=3pnOiW156ZRIkIuVH8T81LkPA6AcnfV6htJxIzOGlwA=; b=Moa/gR56qq1uuua3cC+2KCxF1OJEF3Ewx9YCXNB9jInWBJMLNUqklpSh29hmoxvJ8J XmTHxBu1cnhB23vAvfdMonCJ4CrP2lu1Ajp3EIHwgv1+7+b3B6sWV2PEN/RzurtDIGrt sGj8u3QxPYl7ye7fHqkAPSbjgZ1Ou00ipkQTLkqzP1bhI8/keO/OV/anRwbE/r/Q8HYk QD38hnKsxejMWxVUtT2xM749DRMoFfgTaty6S1PdQl9sAtV6uacD0+wHZnbRGdOiCCjT HJX/+msaoqbWH/BXeGdONfbqvZh3Is8sSZAP/hh7TWbFVSTWnStj65jdbMVPgi9WpivU FD6A== X-Gm-Message-State: AElRT7GtUbfaSmXYK03lZEzDcNFJhQRvDwfSecytMZJBVZpwaKmD5FJb RXK7zoqR/Gc537ExGZWeSA== X-Received: by 10.157.34.162 with SMTP id y31mr16002302ota.266.1520462420349; Wed, 07 Mar 2018 14:40:20 -0800 (PST) Received: from localhost (216-188-254-6.dyn.grandenetworks.net. [216.188.254.6]) by smtp.gmail.com with ESMTPSA id i25sm7232739otd.36.2018.03.07.14.40.19 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 07 Mar 2018 14:40:19 -0800 (PST) Date: Wed, 7 Mar 2018 16:40:19 -0600 From: Rob Herring To: Nipun Gupta Cc: will.deacon@arm.com, robin.murphy@arm.com, mark.rutland@arm.com, catalin.marinas@arm.com, devicetree@vger.kernel.org, stuyoder@gmail.com, bharat.bhushan@nxp.com, gregkh@linuxfoundation.org, joro@8bytes.org, linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org, leoyang.li@nxp.com, iommu@lists.linux-foundation.org, laurentiu.tudor@nxp.com, shawnguo@kernel.org, hch@lst.de, linux-arm-kernel@lists.infradead.org, m.szyprowski@samsung.com Subject: Re: [PATCH 1/6] Docs: dt: add fsl-mc iommu-parent device-tree binding Message-ID: <20180307224019.oowh74pkbi5izuft@rob-hp-laptop> References: <1520260166-29387-1-git-send-email-nipun.gupta@nxp.com> <1520260166-29387-2-git-send-email-nipun.gupta@nxp.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1520260166-29387-2-git-send-email-nipun.gupta@nxp.com> User-Agent: NeoMutt/20170609 (1.8.3) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 05, 2018 at 07:59:21PM +0530, Nipun Gupta wrote: > The existing IOMMU bindings cannot be used to specify the relationship > between fsl-mc devices and IOMMUs. This patch adds a binding for > mapping fsl-mc devices to IOMMUs, using a new iommu-parent property. > > Signed-off-by: Nipun Gupta > --- > .../devicetree/bindings/misc/fsl,qoriq-mc.txt | 31 ++++++++++++++++++++++ > 1 file changed, 31 insertions(+) > > diff --git a/Documentation/devicetree/bindings/misc/fsl,qoriq-mc.txt b/Documentation/devicetree/bindings/misc/fsl,qoriq-mc.txt > index 6611a7c..011c7d6 100644 > --- a/Documentation/devicetree/bindings/misc/fsl,qoriq-mc.txt > +++ b/Documentation/devicetree/bindings/misc/fsl,qoriq-mc.txt > @@ -9,6 +9,24 @@ blocks that can be used to create functional hardware objects/devices > such as network interfaces, crypto accelerator instances, L2 switches, > etc. > > +For an overview of the DPAA2 architecture and fsl-mc bus see: > +drivers/staging/fsl-mc/README.txt > + > +As described in the above overview, all DPAA2 objects in a DPRC share the > +same hardware "isolation context" and a 10-bit value called an ICID > +(isolation context id) is expressed by the hardware to identify > +the requester. > + > +The generic 'iommus' property is cannot be used to describe the relationship > +between fsl-mc and IOMMUs, so an iommu-parent property is used to define > +the same. Why not? It is just a link between 2 nodes. > + > +For generic IOMMU bindings, see > +Documentation/devicetree/bindings/iommu/iommu.txt. > + > +For arm-smmu binding, see: > +Documentation/devicetree/bindings/iommu/arm,smmu.txt. > + > Required properties: > > - compatible > @@ -88,14 +106,27 @@ Sub-nodes: > Value type: > Definition: Specifies the phandle to the PHY device node associated > with the this dpmac. > +Optional properties: > + > +- iommu-parent: Maps the devices on fsl-mc bus to an IOMMU. > + The property specifies the IOMMU behind which the devices on > + fsl-mc bus are residing. If you want a generic property, this should be documented in the common binding. Couldn't you have more than 1 IOMMU upstream of a MC? > > Example: > > + smmu: iommu@5000000 { > + compatible = "arm,mmu-500"; > + #iommu-cells = <1>; > + stream-match-mask = <0x7C00>; > + ... > + }; > + > fsl_mc: fsl-mc@80c000000 { > compatible = "fsl,qoriq-mc"; > reg = <0x00000008 0x0c000000 0 0x40>, /* MC portal base */ > <0x00000000 0x08340000 0 0x40000>; /* MC control reg */ > msi-parent = <&its>; > + iommu-parent = <&smmu>; > #address-cells = <3>; > #size-cells = <1>; > > -- > 1.9.1 > > > _______________________________________________ > linux-arm-kernel mailing list > linux-arm-kernel@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel