Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp6399790ybp; Tue, 15 Oct 2019 14:28:29 -0700 (PDT) X-Google-Smtp-Source: APXvYqygaF3bj/kTEc2nUjuOLg1femn405Yhu0GpEf61UqMY0MrBrBMOKM2rA/MUCc6FSVMGPKTz X-Received: by 2002:a05:6402:296:: with SMTP id l22mr35967843edv.86.1571174909172; Tue, 15 Oct 2019 14:28:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1571174909; cv=none; d=google.com; s=arc-20160816; b=d5ohKXsmb0+93iQKfYFwtNsdKVbhCq3NIyQypG/5ydpHW8LNJ1jpN8FCznSuBPDiXE FstFm2r9Tr5wzcOO4JRNkvTaw5569feoEeRSRMQTLV/XX3yVa+LmY1WoLu2CIjLPWR38 E2Iga2JTvJzGwFGvwGKoN/q5m3L1muIS6tk292p+ManHg71kNM6RbyKiE/v+iwSMgo53 E/5qzrOzDVizG8SX7WBybqxHH2b9gXzQtFKTHZGvnEfqoYaNZidCofR5UoIvgl+wVgtJ XcCPJGBJJgJ4WwABEzk48Vd8qBSrzeQSeYCCHhRXQHYB02SnmY5BmDoillDuoRf8HxLF nl0A== 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; bh=GAHrLiAFlazwlF31Anvci8d6QY+LhAJg86S630nwFns=; b=CmmgppLpTSwj5TH0XBSk/9KEIX267JZIics6suyTrOkC4NZKKe2qXygQz45373UQlZ 46crkQ9nFyf8OD9oSDv5z2ta8H5Fvl/iv+mq2k/PURRMgEdwI7FDker7v9UuKdjNzOap Jnr1ikIXURfy9G954JDMuY5SVYUNcjPyVA/nhV08dhPTG4X+EneKlUcBQSQbvoMpJtKP ZvwB6ACnmhk3PRVAf2FFTXn1jXIhT+MsG64yhOSS+wD8XyZ2e+Bfe8QN7WkvnY6/ZPmq MdwVXynoJusw0nlnwAihTdNoYaB+4rh/3AyENFwexVoEm/6YHosLf4FcslB5Zfh2lRMy nUzA== 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b58si15724620edc.97.2019.10.15.14.28.06; Tue, 15 Oct 2019 14:28:29 -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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389210AbfJOSmr (ORCPT + 99 others); Tue, 15 Oct 2019 14:42:47 -0400 Received: from mail-oi1-f194.google.com ([209.85.167.194]:33399 "EHLO mail-oi1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726144AbfJOSmr (ORCPT ); Tue, 15 Oct 2019 14:42:47 -0400 Received: by mail-oi1-f194.google.com with SMTP id a15so17765334oic.0; Tue, 15 Oct 2019 11:42:45 -0700 (PDT) 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=GAHrLiAFlazwlF31Anvci8d6QY+LhAJg86S630nwFns=; b=hL/tauRjah5rVImtp8vS/9VeejEN8woHZBR1hPjhrKQ7TwzXztTrmmEVVKlknoNf/i kvPVPD3gaHqG1flXSvriGWutrhu/ERuOVLohVtHNgrev3J3/kc34Tr6t2/c+sotV6ere bEVpCowUoHcNZxd6mtgaVRMb1D/c3kpNt7P4CbtoG2qsF8XvJMR6Z77W45oQ/C8rO4ex DeIUnrb7WxbiPSvUVOlHWn/QI0wmUka4S6i6ueKFzxRPD5RDWqinZ18ecct/NuWeWoUD LxUKqMK6c6410By2aO4zQm4t2BGahgf6xgEPc90jWqlrSUcVXR66LxHiG158FV/3S6VP eM4w== X-Gm-Message-State: APjAAAXcIsazgYCnw4QNhQ/Nfy6uYfvpCX746PmGfDnzFN2LJ2bvbitR Hwi9bSQQgEhVzPpSBt4k4Q== X-Received: by 2002:aca:d19:: with SMTP id 25mr15150oin.64.1571164964933; Tue, 15 Oct 2019 11:42:44 -0700 (PDT) Received: from localhost (24-155-109-49.dyn.grandenetworks.net. [24.155.109.49]) by smtp.gmail.com with ESMTPSA id l19sm6293550oie.22.2019.10.15.11.42.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Oct 2019 11:42:44 -0700 (PDT) Date: Tue, 15 Oct 2019 13:42:43 -0500 From: Rob Herring To: Kishon Vijay Abraham I Cc: Bjorn Helgaas , Jonathan Corbet , Jon Mason , Dave Jiang , Allen Hubbe , Lorenzo Pieralisi , Mark Rutland , linux-pci@vger.kernel.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-ntb@googlegroups.com Subject: Re: [RFC PATCH 02/21] dt-bindings: PCI: Endpoint: Add DT bindings for PCI EPF Device Message-ID: <20191015184243.GA10228@bogus> References: <20190926112933.8922-1-kishon@ti.com> <20190926112933.8922-3-kishon@ti.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190926112933.8922-3-kishon@ti.com> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Sep 26, 2019 at 04:59:14PM +0530, Kishon Vijay Abraham I wrote: > Add device tree bindings for PCI endpoint function device. The > nodes for PCI endpoint function device should be attached to > PCI endpoint function bus. > > Signed-off-by: Kishon Vijay Abraham I > --- > .../bindings/pci/endpoint/pci-epf.txt | 28 +++++++++++++++++++ > 1 file changed, 28 insertions(+) > create mode 100644 Documentation/devicetree/bindings/pci/endpoint/pci-epf.txt This and the previous patch for the bus should be combined and please convert to a schema. > > diff --git a/Documentation/devicetree/bindings/pci/endpoint/pci-epf.txt b/Documentation/devicetree/bindings/pci/endpoint/pci-epf.txt > new file mode 100644 > index 000000000000..f006395fd526 > --- /dev/null > +++ b/Documentation/devicetree/bindings/pci/endpoint/pci-epf.txt > @@ -0,0 +1,28 @@ > +PCI Endpoint Function Device > + > +This describes the generic bindings to be used when a device has to be > +exposed to the remote host over PCIe. The device could be an actual > +peripheral in the platform or a virtual device created by the software. > + > +epcs : phandle to the endpoint controller device > +epc-names : the names of the endpoint controller device corresponding > + to the EPCs present in the *epcs* phandle Other than the NTB case, I'd expect the parent device to be the controller. Let's make NTB the exception... > +vendor-id: used to identify device manufacturer > +device-id: used to identify a particular device > +baseclass-code: used to classify the type of function the device performs > +subclass-code: used to identify more specifically the function of the device Are these codes standard? Powerpc has "class-code" already... > +subsys-vendor-id: used to identify vendor of the add-in card or subsystem Powerpc has "subsystem-vendor-id" already... > +subsys-id: used to specify an id that is specific to a vendor > + > +Example: > +Following is an example of NTB device exposed to the remote host. > + > +ntb { This is going to need some sort of addressing (which implies 'reg')? If not, I don't understand why you have 2 levels. > + compatible = "pci-epf-ntb"; > + epcs = <&pcie0_ep>, <&pcie1_ep>; > + epc-names = "primary", "secondary"; > + vendor-id = /bits/ 16 <0x104c>; > + device-id = /bits/ 16 <0xb00d>; These have a long history in OF and should be 32-bits (yes, we've let some cases of 16-bit creep in). > + num-mws = <4>; Doesn't this apply to more than NTB? Can't you just get the length of 'mws-size'? > + mws-size = <0x100000>, <0x100000>, <0x100000>, <0x100000>; Need to support 64-bit sizes? > +}; > -- > 2.17.1 >