From patchwork Thu Jul 7 21:02:37 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frank Li X-Patchwork-Id: 12910239 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7B50CC43334 for ; Thu, 7 Jul 2022 21:04:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=iPzhcsX28B713a5fUCe3Y/s5YnhvTBMrq41IF/uYD7w=; b=YBK3SfVLL+e/R/ V7fzC9JMowHY9dO+6LtuRzLN0yKuJuNYoQul77I78YgFos1ftbSbqcgrDTYNppFMtGlNziwXnqU/S yN1j2hBTFl0ulQpZRnIit9j63uIMJQZc92ndGAzaUxOVOtSMcL/RbvZaPNpI7JVGlhiZmwqPbbaLf WqJhGaieAgrXLFEc0Gj2y7u1rWlu2uuhTEyc/sNqin7gcSuBhyxTgtA7QRm58qcIIIbeqccTuwsLX 2L+2Vx5QcVH0YrcU6kqYLpuYAe9qYGT/S1bCYNPhjZtdS3uvC8j5S3821raj9eqFJ5JJ6i9eDnR+Q f0Bm4tzJ7FLK8pWP8GPw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1o9Yep-000EGV-9u; Thu, 07 Jul 2022 21:03:31 +0000 Received: from mail-eopbgr130058.outbound.protection.outlook.com ([40.107.13.58] helo=EUR01-HE1-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1o9Yef-000EBw-0Z for linux-arm-kernel@lists.infradead.org; Thu, 07 Jul 2022 21:03:22 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=OSfHtV2zoXF55EEGUGf4eVUNYEHJ8/6ywufzVZ4anmMUZE/MH9uVf9soxVPGWGWbhVS08WlK9Lka1GQJNuoa+bUAq2f6YKPkoDAbf/KxOQcCdWWd5lBFInSXy1NZqPccDj06KjFKWCsEhyqaGSH9WbZYrwEtlWYr/zfZsUu00hEO4lH9m+9xaNExlmrpK8jzNCQCKL2hEMcbvMukce6hiDuPN78SNhNHIabrdV8iQsVdk+B7R7weYQqTZRfGMygez/HXuecIrfn6KVECDmIZNMqEqTpejqSbMNJDp5EuSQPOyX+88/dCgOxClE9Dd9ieJ5h0xIHv6mIqG1Y0C5ZrEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=EA+n7rUp/El5drWCneXxuuoPmuM92glV8PTouRgokqk=; b=cYUILDvpmqDf8JTYUHO47Nvl7LuHQ2B35zxKKo/2HBBEg7gI8UtJB1NlDiuZkKwxefT8jpqfnO30YD2PBR7koJjsOs8/sY8A8KQow5WKaflk2fDUrUHMu9G9FJmMBaPO79qMC+Wmn3QboHBqcA8qg7WQFHHILbUcqEy2EedACI8hCU9KsiLHSSgCbBVEDoapdQth7Rw0/XBfwrSwRoR6CpeMZyhkPynnk8/v+5mLQz4LgJckTTFHlkDeeS1VPpgBX4LU4sQlDUyG6nOQ/cJSrKyzmbKF7ifGHHMxwEFaXlZuMm+gvCgJngyr+18NsKyOLmOSJVraW2+2VWZS6XogKQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=EA+n7rUp/El5drWCneXxuuoPmuM92glV8PTouRgokqk=; b=iMWhwP2Bb+sF+gq/Q+imtMD//1epNzsPBlCn/rhJXBP6VlYBSsCF70Vno5c7jkPLO9+65RtamcTHRLpa4pUpfWVj9gPIkGHX+Zp9ZV230WbHuM3eXgODXlqqP4SYxWp2M0h3VwjjrCo8CMKMb5wVjoxvsgPn/dglB2zDwiIAU44= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from PAXPR04MB9186.eurprd04.prod.outlook.com (2603:10a6:102:232::18) by DBBPR04MB7817.eurprd04.prod.outlook.com (2603:10a6:10:1ef::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5417.16; Thu, 7 Jul 2022 21:03:15 +0000 Received: from PAXPR04MB9186.eurprd04.prod.outlook.com ([fe80::e945:8bde:54e5:d83e]) by PAXPR04MB9186.eurprd04.prod.outlook.com ([fe80::e945:8bde:54e5:d83e%6]) with mapi id 15.20.5395.020; Thu, 7 Jul 2022 21:03:15 +0000 From: Frank Li To: tglx@linutronix.de, maz@kernel.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, shawnguo@kernel.org, s.hauer@pengutronix.de, kw@linux.com, bhelgaas@google.com, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-pci@vger.kernel.org, peng.fan@nxp.com, aisheng.dong@nxp.com, jdmason@kudzu.us Cc: kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, kishon@ti.com, lorenzo.pieralisi@arm.com, ntb@lists.linux.dev Subject: [PATCH 2/3] dt-bindings: irqchip: imx mu work as msi controller Date: Thu, 7 Jul 2022 16:02:37 -0500 Message-Id: <20220707210238.917477-2-Frank.Li@nxp.com> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220707210238.917477-1-Frank.Li@nxp.com> References: <20220707210238.917477-1-Frank.Li@nxp.com> X-ClientProxiedBy: SJ0PR03CA0219.namprd03.prod.outlook.com (2603:10b6:a03:39f::14) To PAXPR04MB9186.eurprd04.prod.outlook.com (2603:10a6:102:232::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 4907db8c-5e64-45d1-19bf-08da605c1c1a X-MS-TrafficTypeDiagnostic: DBBPR04MB7817:EE_ X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: D60+Qxiy9EtV/Dc/PIz4nyKaHoUjufguYfWdpC9PERV7KnTZvC0bg4tJD31btyiws/jj2lDmiXcQWNR+0kkyTTIAeleE4X3ZBJbPRYU9yNLILI9zHpSyEe1SlkH0eaBqIA6QumKTnxESbOTO2wvP2Iq75T6nHFaqEfwRUFXgcNzQH3RGjFYuD/r1vD3EvFO/qphVHOOUFIVZcnxbA+HYq5c6edfLhVtmHifO9JuyolO/EXwnIud9qFY4glEV0EEYwy1AF8d78E+x+waiOZmc/pjhw/COfkjdJK1RF9EaUhXo5JMEFgx9O+MXGzXm2TbX6+iIMBTbARZnkZvdh8K/YY44cfnX2gDI65kpvuvUMrHWUMJZH2urpEV0UY+x9NqFMhoY+xFZ8YN95pLHOe46YJktMAJVxWpOcC365VS8jLx3Bu/LaewRkn/ncZMlcucFOdAiFBjClrCns7oPYjwmFbbg/K6IUkKa5KHk0UtiRYAt1lu0NgAyTaKcJYYb6vLn7w1zMKbNmcup5w8wbvjltOPGSLL2CjyOSUW1Upz9OWly67+uv4UZ3He4+MqfiAprNaslzuRFyz0nSzEVf+84cURiq5QugxZ7w2sqAr00tPgGJGKpHf1C05NAj7IHmto+UmVspp5FpHR/0UegE3z0bgFynwAPh9JIhsyFwApWnAcVdI5w+wobw0MQNquJiNAnSblei/TMD/Ji5AMY0w5wYPYW8+/W4Ndn8fKrVxUV3iJNHmUq5zgRmrDZ+Wj3Pus2vm11k/UtojQ83COCXZ75StqfVVo3v/nXb0S98cApXPSvu+L6USbmNpFfgZWiMrP5zvjCbkFm+xla+OEFSwTnJL4QW49Fcp+mBGRIGetg3ulXU7BUzBFHFwovZyjdeV1pvx+80t5myXeukq/rZCjusA== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PAXPR04MB9186.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230016)(4636009)(346002)(396003)(136003)(376002)(366004)(39860400002)(38100700002)(6512007)(38350700002)(186003)(66946007)(66476007)(66556008)(4326008)(8676002)(5660300002)(316002)(921005)(83380400001)(36756003)(2906002)(2616005)(6486002)(8936002)(966005)(478600001)(41300700001)(6506007)(86362001)(6666004)(52116002)(26005)(1076003)(7416002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: ATvPVpyZxyy0NtoAQUjFmNead7YXG0dySPN9+CtAkUnM56FIM2Pi7j1+sbdVed7IvC+CSgE5iKQjrGmkLUnVVVhZZa2VnWjUTZqNlM0VTRahB87Vs1op0ZP9+yczF/h1hTRdb6UkmTgwkL6WdLENMgtGJ+LdTXIH8sfUsIv6wGND3JpA4aDHezrESdCfnbu/OZejCS/O+7AEVdZz6PlU4am+eh97GcAOeIvXsBzYhbXqVjBa1pvZrUn4IVpHNlPimgzIoONsSzpIWJnh0O2JLRUC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f8CTsRIuBF6L5x8tHrna9R1eqYaNXJVJ7u6Fe7pSH+CYInFGQnkXTyIBhXNRTjKHxLmf4CaDxhNbeiHC5yCSP0pRmpQj+95gTzFt3DHyqNooBQp+7gzzDDa5Cpx1CUOeYeiXIa7+Xe7m6gkZOj8gnCb84gUzNRjYPc+sbCfDVflPzs10oX+XAPBiCoNReVmJDx4FdZHUywMmwL6y8N8iASiEg/xNflRjfPq12CRxyzyWpaU7rEorDflnW X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4907db8c-5e64-45d1-19bf-08da605c1c1a X-MS-Exchange-CrossTenant-AuthSource: PAXPR04MB9186.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Jul 2022 21:03:15.3732 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: d/91LlErXqWCTNXJKBAvWuFjPfbo76SzceLhucyNO7X5qRdQF307X9fiatldpNmhoDxTFJVgjBCbqijNKBGzjA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DBBPR04MB7817 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220707_140321_085402_DE47D042 X-CRM114-Status: GOOD ( 13.68 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org imx mu support generate irq by write a register. provide msi controller support so other driver can use it by standard msi interface. Signed-off-by: Frank Li --- .../interrupt-controller/fsl,mu-msi.yaml | 94 +++++++++++++++++++ 1 file changed, 94 insertions(+) create mode 100644 Documentation/devicetree/bindings/interrupt-controller/fsl,mu-msi.yaml diff --git a/Documentation/devicetree/bindings/interrupt-controller/fsl,mu-msi.yaml b/Documentation/devicetree/bindings/interrupt-controller/fsl,mu-msi.yaml new file mode 100644 index 0000000000000..b4ac583f60227 --- /dev/null +++ b/Documentation/devicetree/bindings/interrupt-controller/fsl,mu-msi.yaml @@ -0,0 +1,94 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/interrupt-controller/fsl,mu-msi.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: NXP i.MX Messaging Unit (MU) + +maintainers: + - Frank Li + +description: | + The Messaging Unit module enables two processors within the SoC to + communicate and coordinate by passing messages (e.g. data, status + and control) through the MU interface. The MU also provides the ability + for one processor to signal the other processor using interrupts. + + Because the MU manages the messaging between processors, the MU uses + different clocks (from each side of the different peripheral buses). + Therefore, the MU must synchronize the accesses from one side to the + other. The MU accomplishes synchronization using two sets of matching + registers (Processor A-facing, Processor B-facing). + + MU can work as msi interrupt controller to do doorbell + +properties: + compatible: + oneOf: + - const: fsl,imx6sx-mu-msi + - const: fsl,imx7ulp-mu-msi + - const: fsl,imx8ulp-mu-msi + - const: fsl,imx8-mu-msi + - const: fsl,imx8ulp-mu-msi-s4 + - items: + - const: fsl,imx8ulp-mu-msi + - items: + - enum: + - fsl,imx7s-mu-msi + - fsl,imx8mq-mu-msi + - fsl,imx8mm-mu-msi + - fsl,imx8mn-mu-msi + - fsl,imx8mp-mu-msi + - fsl,imx8qm-mu-msi + - fsl,imx8qxp-mu-msi + - const: fsl,imx6sx-mu-msi + - description: MU work as msi controller + items: + - enum: + - fsl,imx8qm-mu-msi + - fsl,imx8qxp-mu-msi + - const: fsl,imx6sx-mu-msi + reg: + maxItems: 2 + + interrupts: + minItems: 1 + maxItems: 2 + + interrupt-names: + minItems: 1 + items: + - const: tx + - const: rx + + clocks: + maxItems: 1 + + power-domains: + maxItems: 1 + +required: + - compatible + - reg + - interrupts + - msi-controller + +additionalProperties: false + +examples: + - | + #include + + lsio_mu12: msi@5d270000 { + compatible = "fsl,imx6sx-mu-msi-db"; + msi-controller; + interrupt-controller; + reg = <0x5d270000 0x10000>, /* A side */ + <0x5d300000 0x10000>; /* B side */ + reg-names = "a", "b"; + interrupts = ; + power-domains = <&pd IMX_SC_R_MU_12A>, + <&pd IMX_SC_R_MU_12B>; + power-domain-names = "a", "b"; + };