From patchwork Fri Jul 12 06:19:57 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pankaj Gupta X-Patchwork-Id: 13731306 Received: from DB3PR0202CU003.outbound.protection.outlook.com (mail-northeuropeazon11011045.outbound.protection.outlook.com [52.101.65.45]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2BAD913D63A for ; Fri, 12 Jul 2024 06:23:25 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=52.101.65.45 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1720765408; cv=fail; b=eFc0smKVBx/3Pjx9GwpbC2/EvBnBkMD5N0V8y1Dqh9PxfUwWqvToavQ1zEoS9ZfGS2eGWp2VxhT21lSuk19sMg+NH6gOpIw0QoNAFccY5RwDJkhm8AQFplHChyinfpAener6wxZsXKNhzpupNKVMNwWS2jYQd3PH3ity9nEMnCs= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1720765408; c=relaxed/simple; bh=JtbBx0yQoAaTNbWkXdPsH4Vzzy2ZXxKhbLKP3eswoUE=; h=From:Date:Subject:Content-Type:Message-Id:References:In-Reply-To: To:Cc:MIME-Version; b=gah2auJ+wnD9SPrdN2BAPU1mP4+rLr6a4wVVbZ+C09B84Bz+t99y/Jsos8iWcsDySoiIk/FAtywiFyXucddhKIQsEH9qd1CN4gmdQvzgRG3F8k19AMsZs8zdqvc6e6omDnXkcoKu2ZxUCrY1aik2n00Z1uMKRZUGi96c8rIDEEw= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b=gTDvAOI+; arc=fail smtp.client-ip=52.101.65.45 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="gTDvAOI+" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=yA4ZX75EJ4ELq0d0F2z64m3sGZI9N/Qx/LUx8eJCyFR/7+UUnei9ixEf2FT2ClbgE3s0A+dLwxHNEtMXSnSUp89zfxt7+gi9SKjsWqlaLKooS+MRL3DwsJrlfvysqCOJsKBwQByQTVUZUTLb6SyezHUdSLaqsYCZoNRanG8/IfcYEf2/qTIiaTCud/T59xRuVBShTWKkmYHwmDwggE4wRvSPTazmtiFybqB7mS1Mvq0Da01kalX9RNsrfoNAe8ApsXr5yxZMCiCkVWJ5fEsFOpgFQ2oXbEnPS5UXhp3/pU6m4F/r954f9xp7q1nDf33XvpgPksZWaCCxlFqo6Dzqqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=ah1WwJJf1pD0+xwYmMkAwafT1y9D9eXkXOAlq7r/suI=; b=uSYHh0Pe1ENO7vPkHDysDLkgXj0dm6b0wXxmTu2e0aiAy6eaKPsHIPVV7YM96j8qHDXpZq3Zp5+fb9QFd3g0v7ud/KoR2MSp24fNtU1yvhp4OuzfjFyFKL4fa6cwU5p9+yG8RqQQkl+qXUZeAVflnzigkfBkR+Wq7Aj2UgOIRDHLzchDGOT4AryGZWUxmW8xamVLXBRtFqNAcD+CXFmfmvupgCGZFZevdM3wB1j660Dj/E/fcjURbrWWqMf17W29gDMgtpipx4QsbmCJxV6slshkdWd/h+oN8lscsrS/xvuzwdu1FOGPvA2yIuoAaTEYOcfTYMs1/hNXXOAkf/bSmQ== 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=ah1WwJJf1pD0+xwYmMkAwafT1y9D9eXkXOAlq7r/suI=; b=gTDvAOI+g64rg1D5ikKrYHOuHSp8ka2pa5r8A3J55y6R2BR/EwQgoDnn1IAswhUGrpmmlwyST2B/jFItCgMmhjpcgD//hE5ti5E+AfdnqJMZcogLwjeYs8p8rhqrqSvFztjkIn6joT/0R5Cg4e53SOXQQKeLjRGaZrUM08RTjnk= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AM9PR04MB8604.eurprd04.prod.outlook.com (2603:10a6:20b:43b::21) by DB8PR04MB7068.eurprd04.prod.outlook.com (2603:10a6:10:fe::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7762.22; Fri, 12 Jul 2024 06:23:23 +0000 Received: from AM9PR04MB8604.eurprd04.prod.outlook.com ([fe80::e751:223e:aa3d:5827]) by AM9PR04MB8604.eurprd04.prod.outlook.com ([fe80::e751:223e:aa3d:5827%3]) with mapi id 15.20.7762.020; Fri, 12 Jul 2024 06:23:23 +0000 From: Pankaj Gupta Date: Fri, 12 Jul 2024 11:49:57 +0530 Subject: [PATCH v5 2/5] dt-bindings: arm: fsl: add imx-se-fw binding doc Message-Id: <20240712-imx-se-if-v5-2-66a79903a872@nxp.com> References: <20240712-imx-se-if-v5-0-66a79903a872@nxp.com> In-Reply-To: <20240712-imx-se-if-v5-0-66a79903a872@nxp.com> To: Jonathan Corbet , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Pankaj Gupta , Rob Herring Cc: linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1720765211; l=3836; i=pankaj.gupta@nxp.com; s=20240523; h=from:subject:message-id; bh=JtbBx0yQoAaTNbWkXdPsH4Vzzy2ZXxKhbLKP3eswoUE=; b=FoPJl8139JYtMzDo57U2+jgE2gfklxXOgwI+g0WFJroaILiVrFerVBH+eBaiIPzfYrqZ8G/QT vHNMEK7caPaA76ctpfjCa3TtRMQXwULNlWsfdR4ZmqUrwFzmDmXuv85 X-Developer-Key: i=pankaj.gupta@nxp.com; a=ed25519; pk=OA0pBQoupy5lV0XfKzD8B0OOBVB6tpAoIf+0x1bYGRg= X-ClientProxiedBy: SI2P153CA0006.APCP153.PROD.OUTLOOK.COM (2603:1096:4:140::22) To AM9PR04MB8604.eurprd04.prod.outlook.com (2603:10a6:20b:43b::21) Precedence: bulk X-Mailing-List: imx@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AM9PR04MB8604:EE_|DB8PR04MB7068:EE_ X-MS-Office365-Filtering-Correlation-Id: b649143a-18e3-4a6d-f19a-08dca23b218f X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|7416014|376014|52116014|1800799024|366016|921020|38350700014; X-Microsoft-Antispam-Message-Info: =?utf-8?q?Ku/3v5M4x4G8dO0H444VcH1u3IR5jrO?= =?utf-8?q?iI0BKX0ioSw3fV/2Q5I/Ck6OnsElJmxbxIFX6vmGO3+rvneE35hXgp1FyJfhN24o5?= =?utf-8?q?jMocgRmwQwJ9O9fJRhWBg2xkGtS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vDk6GsrnLoWojxm5sH0gcosFXo1?= =?utf-8?q?8fgeOUvDZiuiOP1ZCg1brJRi5Y3noIW7f2dGzrmFozY7Q3BScPy84Q4Ci0huR7MZH?= =?utf-8?q?a3XrpK9n3NCSA7O8qvqLAuOf5jJuLe5AjZJYbTpdu4l/iZyqQoDF1HDrdEQLzTCEO?= =?utf-8?q?WC54ITdsTYTLTpBwg0atdN6PoqJYu6xHZqx/GwWT/xtJc7cL5P/Ohqa3RuiO0SK5g?= =?utf-8?q?dseYZVsg+9TnfrakB58qNqg5BjaQgHq+6Ip92sDUWoFCJqLoJbyubwW3KAI+3uZ/y?= =?utf-8?q?CaTTOn6wOvLQMLXdZJJApFiqVypZUlKkHkcwwueq/N/ISGmvaqV076Vw=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AM9PR04MB8604.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(7416014)(376014)(52116014)(1800799024)(366016)(921020)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?F0rKyRC5BfcSlrAkaBBEaql1Fklj?= =?utf-8?q?xYjnURmKonpKKGjV6XGadPBXv758d8el5KKg4fOpdlrugoulhSiWOMQGLkFVpcgmM?= =?utf-8?q?do/Xu3tuMg+uvHxbuiKsRFzeUcdOMnS3DiGAs0t/pmy1tj3c46JXUhTmi9i8BtOrM?= =?utf-8?q?NTTwNX0D771C+vWAQGRNS863dKax6e1Rd27Ebbv5ncSg98oeJmsScL7hfXQiNBmTJ?= =?utf-8?q?tvcrp651/bUdEiu3lXLootVn0Ty2lt6IVJqSceOlJbORiT8pG6tPFQtXxDbnFU4Db?= =?utf-8?q?w+r7smKCIoGEkOamxTRw/Fb5fEG5awrknJYDSD8ZlM3k5b0ux2fxGUCMmPMG+UfW0?= =?utf-8?q?ET8M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YffBrGTcqGQzvtdf90yCx6mJ5O9RTkvhDAMFIeU3o4LSt8bP8sFOsqG+H4DPg?= =?utf-8?q?YlsuPuJhDSc1IwX/quE0hVJma0HczomVBgtkpswygO4f69gW1RWVBGFSv2g5vzK7t?= =?utf-8?q?nZIVTG1dFLIcN9NB4lsMeLuHEpJ4DGXyF6iRkYPCw8AqZnACaNFUGQBMGxYAey/t2?= =?utf-8?q?4D8axFI34SQQczMT3+p4x4SGvPeiCWIqKWykQXlLemckvGaf/x/lXCCBZRLuLSIKe?= =?utf-8?q?SbTeHT8dIOuZteuKKylK3A9zfHK8LSGAwCiXuJ3RSKWiPhA58eFMg2rGMeyRBDue3?= =?utf-8?q?JOsTxytreVvl?= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: b649143a-18e3-4a6d-f19a-08dca23b218f X-MS-Exchange-CrossTenant-AuthSource: AM9PR04MB8604.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 Jul 2024 06:23:23.1304 (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: QxWGT7wbcoe5lG/qS+BfKD+KpvfouHBK55y0JBiooOlZYXqgg6ZaZE6nYNbTD0wDVtU64ZiRdRjr6ScwCqXRkw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB8PR04MB7068 The NXP security hardware IP(s) like: i.MX EdgeLock Enclave, V2X etc., creates an embedded secure enclave within the SoC boundary to enable features like: - HSM - SHE - V2X Secure-Enclave(s) communication interface are typically via message unit, i.e., based on mailbox linux kernel driver. This driver enables communication ensuring well defined message sequence protocol between Application Core and enclave's firmware. Driver configures multiple misc-device on the MU, for multiple user-space applications, to be able to communicate over single MU. It exists on some i.MX processors. e.g. i.MX8ULP, i.MX93 etc. Signed-off-by: Pankaj Gupta --- .../devicetree/bindings/firmware/fsl,imx-se.yaml | 111 +++++++++++++++++++++ 1 file changed, 111 insertions(+) diff --git a/Documentation/devicetree/bindings/firmware/fsl,imx-se.yaml b/Documentation/devicetree/bindings/firmware/fsl,imx-se.yaml new file mode 100644 index 000000000000..bd99505de6e6 --- /dev/null +++ b/Documentation/devicetree/bindings/firmware/fsl,imx-se.yaml @@ -0,0 +1,111 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/firmware/fsl,imx-se.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: NXP i.MX HW Secure Enclave(s) EdgeLock Enclave + +maintainers: + - Pankaj Gupta + +description: | + NXP's SoC may contain one or multiple embedded secure-enclave HW + IP(s) like i.MX EdgeLock Enclave, V2X etc. These NXP's HW IP(s) + enables features like + - Hardware Security Module (HSM), + - Security Hardware Extension (SHE), and + - Vehicular to Anything (V2X) + + Communication interface to the secure-enclaves is based on the + messaging unit(s). + +properties: + $nodename: + pattern: "firmware@[0-9a-f]+$" + + compatible: + enum: + - fsl,imx8ulp-se + - fsl,imx93-se + - fsl,imx95-se + + reg: + maxItems: 1 + description: Identifier of the communication interface to secure-enclave. + + mboxes: + items: + - description: mailbox phandle to send message to se firmware + - description: mailbox phandle to receive message from se firmware + + mbox-names: + description: two names are to be listed, one for rx and other one for tx. + The name can be any of the below list. + items: + - const: tx + - const: rx + + memory-region: + items: + - description: The phandle to the reserved external memory, the only + accessible memoryregion to secure enclave(SE) firmware. It is an + optional property based on compatible. + (see bindings/reserved-memory/reserved-memory.txt) + + sram: + items: + - description: It is an optional property based on compatible. + +required: + - compatible + - reg + - mboxes + - mbox-names + +allOf: + # memory-region + - if: + properties: + compatible: + contains: + enum: + - fsl,imx8ulp-se + - fsl,imx93-se + then: + required: + - memory-region + else: + properties: + memory-region: false + + # sram + - if: + properties: + compatible: + contains: + enum: + - fsl,imx8ulp-se + then: + required: + - sram + + else: + properties: + sram: false + +additionalProperties: false + +examples: + - | + firmware { + #address-cells = <1>; + #size-cells = <0>; + firmware@0 { + compatible = "fsl,imx95-se"; + reg = <0x0>; + mboxes = <&ele_mu0 0 0>, <&ele_mu0 1 0>; + mbox-names = "tx", "rx"; + }; + }; +...