Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp2199889ybz; Thu, 30 Apr 2020 12:39:50 -0700 (PDT) X-Google-Smtp-Source: APiQypIA1xO0JEE+TuixLpqrcYE2Oq8ZpKCxKbilyF4zSdLCiL1+kCA7HpyGwRUARKI2kzDexon/ X-Received: by 2002:a17:907:41b6:: with SMTP id na6mr15199ejb.119.1588275590727; Thu, 30 Apr 2020 12:39:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588275590; cv=none; d=google.com; s=arc-20160816; b=b7W5aNZKUm9A/n44Puf0GRaNWTU8CDviky/9U/eXTDHwm0E2NY7DB8yDReMC4UnEXV ZR26ewrRAs4ulQQ/DRYgcad92RVlq2BM8q/vzdLjmc3SCa36rGhoW/J2TtfFyNiWPDyj 5gItbrCT4LLQ7xaqXNjLvJULDIFiHqIpvP3H+e2za1ei95lZeQpOq7L/ezeNHCqlNyvI 6YVRhx7kFa3fs8RPzZt8HxDN7qhHTCxhzaxh4Jzle7rOBcJ1RjioMdLIPFntuvyiWnyf MoCoO5iUYLk9QXrkgUvMnGFE+y6710TI9Dut/JXxQ/nrbIMwRM0ii7GHDwREZRVLGVmp qLhA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=lzP4zsyL3G+ZA+zKIb8zsIyDO20yNMH6PqtntomA9xg=; b=09A97cGoHoHpyJTBahYltEvaxdg43gJJnPieB1hghqKGtFYScTAulU+s0LGbUSJTjD IEpkVp4zNeAqKxc9cKzuvgw+XYu3ChzwI6Secq65LCFJuO6x4nplW82Y5KD6AUa6LZy3 vvZ8FuaF0GSJA4sANFLcHo7vEk0xzRRpvdzXbNh8DJ8xT/843xP6xep42Ax0gtx+2h+0 UJ+L83ZWpNAcn8CTQlieGBrVqoMtUK5ExDRt6Gd0grrokCj4qbdK5g5uMtY8QHr3qhnW eoBPh/IBUY1YZV/xkBmcsbbQz4k/Z+BCrFjuggl3JdPV7wm/ijPwLs3c/b26ItNe4eT0 VYGw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=fCDX2FSY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l22si385845ejg.362.2020.04.30.12.39.27; Thu, 30 Apr 2020 12:39:50 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=fCDX2FSY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726574AbgD3Tfd (ORCPT + 99 others); Thu, 30 Apr 2020 15:35:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52670 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726366AbgD3Tfd (ORCPT ); Thu, 30 Apr 2020 15:35:33 -0400 Received: from mail-pg1-x541.google.com (mail-pg1-x541.google.com [IPv6:2607:f8b0:4864:20::541]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DC6DBC035495 for ; Thu, 30 Apr 2020 12:35:32 -0700 (PDT) Received: by mail-pg1-x541.google.com with SMTP id l25so998800pgc.5 for ; Thu, 30 Apr 2020 12:35:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=lzP4zsyL3G+ZA+zKIb8zsIyDO20yNMH6PqtntomA9xg=; b=fCDX2FSYSHD6JwsDTIokxh79bkmofe+tsGFm74Iobii0E29IYHlVELmsNu1y3Zd9DX 3SiyzTAcxxfmEgukA74XFh9neFt8TE9YXbrVuw0Qu4QeLM1/bHQ371Imwq4rwgDxrRoV MSKkO2yEiEyB9D3RaBCnLjWvj8xw6mFDgXpcbnDkMCBDrtWFun0JDa0x/PwC/YjNjIty tNe4gCsh9j8dFZmEu2zm1zh3E/UMsEXs8VDS6Rd+RdyWcucpsf+89ToFPjkjNYwWzbwd EbCyFqS0k5GccLlxf9of9GNVM3pAAf4AeKOutadC4y4zTq8aYkM/7clDPhhxgf9Pjvrv pZMw== 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; bh=lzP4zsyL3G+ZA+zKIb8zsIyDO20yNMH6PqtntomA9xg=; b=FgMbQaksnqgDJe3wIUXU5ye+B+/+EvtiOwzq8pXeYiSKu6RxN5LRoVaNkosq8tqnEe MMCYBtrWpymxJUUZopiEQxTQGv4h94CXQayiBO9nSTdOz+6hbByXL5AgqU7B9bsduAq8 M23AdwFMpSmhzsitaBKVTMiQKqTN7uXH6OeruYrYPTg1p3WH98BYgsV4QapWvIX0bseo LHX7Lnb6009kGQy0eiGr+A1VUOXxi5pcXR2+Wp4d4cgbAP8yQUGZTOYw9vsY6pNfS7eX Eg8WIvPdrXx3K5XO/JxSym3Da7zQAJGsKYYhlVRktGatxCSCskEOY74y/eL4CgrbxqSo vS0w== X-Gm-Message-State: AGi0PuYznT3qXrutDHMJJAQOYSzkXQkdPof6cQoiYoHVQ3MrG1fU2CSw bZDxVo+ys9Rniv0XbydX77b50A== X-Received: by 2002:a65:6083:: with SMTP id t3mr479523pgu.398.1588275332220; Thu, 30 Apr 2020 12:35:32 -0700 (PDT) Received: from builder.lan (104-188-17-28.lightspeed.sndgca.sbcglobal.net. [104.188.17.28]) by smtp.gmail.com with ESMTPSA id j23sm493396pjz.13.2020.04.30.12.35.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 30 Apr 2020 12:35:31 -0700 (PDT) Date: Thu, 30 Apr 2020 12:36:09 -0700 From: Bjorn Andersson To: Manivannan Sadhasivam Cc: agross@kernel.org, robh+dt@kernel.org, jassisinghbrar@gmail.com, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/2] dt-bindings: soc: qcom: Add devicetree binding for Qcom IPCC Message-ID: <20200430193609.GA20625@builder.lan> References: <20200430063054.18879-1-manivannan.sadhasivam@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200430063054.18879-1-manivannan.sadhasivam@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed 29 Apr 23:30 PDT 2020, Manivannan Sadhasivam wrote: > Add devicetree YAML binding for Qualcomm Inter-Processor Communication > Controller (IPCC) block. > > Signed-off-by: Manivannan Sadhasivam > --- > .../bindings/soc/qcom/qcom,ipcc.yaml | 85 +++++++++++++++++++ How about putting this in either interrupt-controller/ or mailbox/ instead? > include/dt-bindings/soc/qcom,ipcc.h | 38 +++++++++ > 2 files changed, 123 insertions(+) > create mode 100644 Documentation/devicetree/bindings/soc/qcom/qcom,ipcc.yaml > create mode 100644 include/dt-bindings/soc/qcom,ipcc.h > > diff --git a/Documentation/devicetree/bindings/soc/qcom/qcom,ipcc.yaml b/Documentation/devicetree/bindings/soc/qcom/qcom,ipcc.yaml > new file mode 100644 > index 000000000000..48b281181401 > --- /dev/null > +++ b/Documentation/devicetree/bindings/soc/qcom/qcom,ipcc.yaml > @@ -0,0 +1,85 @@ > +# SPDX-License-Identifier: GPL-2.0 OR BSD-2-Clause > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/soc/qcom/qcom,ipcc.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Qualcomm Technologies, Inc. Inter-Processor Communication Controller > + > +maintainers: > + - Manivannan Sadhasivam > + > +description: > + The Inter-Processor Communication Controller (IPCC) is a centralized hardware > + to route the interrupts across various subsystems. It involves a three-level s/the// > + addressing scheme called protocol, client and signal. For example, consider an > + entity on the Application Processor Subsystem (APSS) that wants to listen to > + Modem's interrupts via Shared Memory Point to Point (SMP2P) interface. In such > + a case, the client would be Modem (client-id is 2) and the signal would be > + SMP2P (signal-id is 2). The SMP2P itself falls under the Multiprocessor (MPROC) > + protocol (protocol-id is 0). Refer include/dt-bindings/soc/qcom/qcom,ipcc.h > + for the list of such IDs. > + > + One of the duties of this interrupt controller driver is to forward the > + interrupts to the correct entities on the APSS. The children inheriting the Clients using the... > + interrupt-controller would be mentioning the client-id and signal-id it's s/would be mentioning/should specify/ > + interested in. > + > + On the other hand, sending an interrupt to a subsystem is done through the "In the other direction," and add clarify subsystem by making it "remote subsystem". > + mailbox interface, which again requires client-id and signal-id. > + > +properties: > + compatible: It's uncertain how new vers > + const: "qcom,ipcc" > + > + reg: > + maxItems: 1 > + > + interrupts: > + maxItems: 1 > + > + interrupt-controller: true > + > + "#interrupt-cells": > + const: 3 > + description: > + The first cell is the client-id, the second cell is the signal-id and the > + third cell is the interrupt type. > + > + "#mbox-cells": > + const: 2 > + description: > + The first cell is the client-id, and the second cell is the signal-id. > + > +required: > + - compatible > + - reg > + - interrupts > + - interrupt-controller > + - "#interrupt-cells" > + - "#mbox-cells" > + > +additionalProperties: false > + > +examples: > + - | > + #include > + #include > + > + ipcc_mproc: qcom,ipcc@408000 { interrupt-controller@ Regards, Bjorn > + compatible = "qcom,ipcc"; > + reg = <0x408000 0x1000>; > + interrupts = ; > + interrupt-controller; > + #interrupt-cells = <3>; > + #mbox-cells = <2>; > + }; > + > + smp2p-modem { > + compatible = "qcom,smp2p"; > + interrupts-extended = <&ipcc_mproc IPCC_CLIENT_MPSS > + IPCC_MPROC_SIGNAL_SMP2P IRQ_TYPE_EDGE_RISING>; > + mboxes = <&ipcc_mproc IPCC_CLIENT_MPSS IPCC_MPROC_SIGNAL_SMP2P>; > + > + /* Other SMP2P fields */ > + }; > diff --git a/include/dt-bindings/soc/qcom,ipcc.h b/include/dt-bindings/soc/qcom,ipcc.h > new file mode 100644 > index 000000000000..2926cdb4cb48 > --- /dev/null > +++ b/include/dt-bindings/soc/qcom,ipcc.h > @@ -0,0 +1,38 @@ > +/* SPDX-License-Identifier: GPL-2.0-only */ > +/* > + * Copyright (c) 2018-2019, The Linux Foundation. All rights reserved. > + */ > + > +#ifndef __DT_BINDINGS_QCOM_IPCC_H > +#define __DT_BINDINGS_QCOM_IPCC_H > + > +/* Signal IDs for MPROC protocol */ > +#define IPCC_MPROC_SIGNAL_GLINK_QMP 0 > +#define IPCC_MPROC_SIGNAL_SMP2P 2 > +#define IPCC_MPROC_SIGNAL_PING 3 > +#define IPCC_MPROC_SIGNAL_MAX 4 /* Used by driver only */ > + > +#define IPCC_COMPUTE_L0_SIGNAL_MAX 32 /* Used by driver only */ > +#define IPCC_COMPUTE_L1_SIGNAL_MAX 32 /* Used by driver only */ > + > +/* Client IDs */ > +#define IPCC_CLIENT_AOP 0 > +#define IPCC_CLIENT_TZ 1 > +#define IPCC_CLIENT_MPSS 2 > +#define IPCC_CLIENT_LPASS 3 > +#define IPCC_CLIENT_SLPI 4 > +#define IPCC_CLIENT_SDC 5 > +#define IPCC_CLIENT_CDSP 6 > +#define IPCC_CLIENT_NPU 7 > +#define IPCC_CLIENT_APSS 8 > +#define IPCC_CLIENT_GPU 9 > +#define IPCC_CLIENT_CVP 10 > +#define IPCC_CLIENT_CAM 11 > +#define IPCC_CLIENT_VPU 12 > +#define IPCC_CLIENT_PCIE0 13 > +#define IPCC_CLIENT_PCIE1 14 > +#define IPCC_CLIENT_PCIE2 15 > +#define IPCC_CLIENT_SPSS 16 > +#define IPCC_CLIENT_MAX 17 /* Used by driver only */ > + > +#endif > -- > 2.17.1 >