From patchwork Thu Sep 28 18:04:02 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Volodymyr Babchuk X-Patchwork-Id: 9976661 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id AE620603F2 for ; Thu, 28 Sep 2017 18:49:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9F63926E38 for ; Thu, 28 Sep 2017 18:49:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 940762847D; Thu, 28 Sep 2017 18:49:21 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAD_ENC_HEADER,BAYES_00, DKIM_SIGNED, DKIM_VALID, RCVD_IN_DNSWL_MED autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 29BFA26E38 for ; Thu, 28 Sep 2017 18:49:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=dPZ9p3JWxWuAodU971QhJSj9n7CinKawcNB+O7vQooA=; b=Nbnr+s008Y/iT+ bbOdkYOUWJthyx0uAJqFzqXHc1qmWDQxBhkRhKe8+CjnJy/c9LcZlXxXPcIgplQVbVUW2mw2m9EPo LYIkep4hKC/dtpy9SSLWIjY/0OI2whlj5e4A+UbSdrIhie3RzsGZuNHNd6irx4cUjxEOoevwjzZd9 Xtti+CRcXoz7G4yjtOAakFwiT/g7fMVFHZFLTw8Zr0F71KJI98rMPdPRELujCMQLhkRzlgMpEOl6X RdtVILgAch/DBU6jRGeV/Yp0FxArCqAh5Vs5oairzOQehhBaxuK9X/03QXeTWLLhY9Ko4wASA40og GFk51rFIZ8hLV0hUVc6A==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1dxds2-00022X-MJ; Thu, 28 Sep 2017 18:49:14 +0000 Received: from merlin.infradead.org ([2001:8b0:10b:1231::1]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1dxds0-000222-LY for linux-arm-kernel@bombadil.infradead.org; Thu, 28 Sep 2017 18:49:13 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=Content-Type:MIME-Version:References: In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=NmgjnR4yMdO20dk4ZPIEXf0f92tT46hQgT7VtJRJJuY=; b=ZD6dvRZ9LGeesXnouR6QzeREO DCMynBKAfLIbIiVfGXNrxCHx0GivovlkUWw0lh7ZsEP9xMXLkkFtcURCrQ583hD/6c4TpJxnPnDOc bI5uLd0TS/MzOPMQBEbhcPIMWXwd5VK8TSRq0nDCkB1WsxXJer9ffDSYQ2RUIadHPv7qj+OL09ip1 OTHqzV8ok//F6DzF/wFv8N/DXgF6WeOPr+4vwEM8zoRTwiP5P6KH7gHXG8217oFLMA/KSd2KIEat4 OcgN0o0Gl2BfKCENzBNWWFhHVr2usEZJBLjRaQo1m1htu8DwJZ06baXZZt6ZBijwxsPBnsgO0qN/6 TfM9NBX0A==; Received: from mail-eopbgr40041.outbound.protection.outlook.com ([40.107.4.41] helo=EUR03-DB5-obe.outbound.protection.outlook.com) by merlin.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1dxdBp-00041h-OL for linux-arm-kernel@lists.infradead.org; Thu, 28 Sep 2017 18:05:41 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=EPAM.onmicrosoft.com; s=selector1-epam-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=NmgjnR4yMdO20dk4ZPIEXf0f92tT46hQgT7VtJRJJuY=; b=Scj3GjJgMte07gA0qXHDnik8e6QofqQaurnNhjuMgjJL/rQMI3fRH0+DnSQ/n7Ow2osKWYdRMDLGJZELpPAUnc0BHXmk1ePDD75hbE7kZxEODj9NYGYM5Um+YC/xPbhRUoxqukDNI25jj3VnPk9BJFGcZB91BP6KT3Sv3dPjbGE= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Volodymyr_Babchuk@epam.com; Received: from EPUAKYIW2556.kyiv.epam.com (85.223.209.59) by DB6PR0301MB2135.eurprd03.prod.outlook.com (2603:10a6:4:46::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.77.7; Thu, 28 Sep 2017 18:05:08 +0000 Received: by EPUAKYIW2556.kyiv.epam.com (sSMTP sendmail emulation); Thu, 28 Sep 2017 21:05:03 +0300 From: Volodymyr Babchuk To: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, tee-dev@lists.linaro.org, Jens Wiklander Subject: [PATCH v1 05/14] tee: optee: Update protocol definitions Date: Thu, 28 Sep 2017 21:04:02 +0300 Message-Id: <1506621851-6929-6-git-send-email-volodymyr_babchuk@epam.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1506621851-6929-1-git-send-email-volodymyr_babchuk@epam.com> References: <1506621851-6929-1-git-send-email-volodymyr_babchuk@epam.com> MIME-Version: 1.0 X-Originating-IP: [85.223.209.59] X-ClientProxiedBy: VI1PR0102CA0016.eurprd01.prod.exchangelabs.com (2603:10a6:802::29) To DB6PR0301MB2135.eurprd03.prod.outlook.com (2603:10a6:4:46::17) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: b7e3fb82-c130-4326-8a34-08d5069b7490 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(2017030254152)(2017052603199)(201703131423075)(201703031133081)(201702281549075); SRVR:DB6PR0301MB2135; X-Microsoft-Exchange-Diagnostics: 1; DB6PR0301MB2135; 3:zIAheQBPoE8rrJBicVEmchNz7OjcfPNaey9vo/rqD4WO57X1gK4s0mLJGE9URZ05Pv3kr/7vb87saaFlIPCAqP1OR454KerlOjl4HPcYQxsFjs5LPJ3PpcoZfiIwWDZnB1495V3vKF2PESwF6LOPgxwnfIvgRGmFwxuasddw1PT0A8ypyyc6sU7YfFqaU3hy73favfo+e/p4PMzobuw+FGOWS96xzJ2RzHO7u2wq6ORjPRD7D6L2kCIDwDXgGDr/; 25:qTC783RhsBe2jXrU0phqNwCcxoYq+YOsls0ZWNKe9rtHra0KX0OTtCy2YS2IKUZnocv4JtpRuhUbLPitQR7XiceUN1v9TlQh78NokzDKvVMqpEpndLCQqezqbqJE+Gw0tb7bBrCw4UQfnmKgIKYBnOiy3MNJWbr8zYC1WA3QMljskUJzOB5iM6jOyInWkoFSIWH+ixfiX+x9fEcid5e3bWGPQN9cztlDgOsmtII/b2kHC3aSq73EJ77w0Q6wbTRhrRbwu+NV+gkYf6PF23HFMzS3KZPr9MetPtGTnk5GL4If+e3kVBK+zQtnuRmlXvcAAvRYb3G2NvKYWwwVO+dx4A==; 31:4jtf1YZAu4k49n0OYg0dyo3m8WoLPsRakqYuvRt7LPPEPWGDVYbYVliv3CImexHzmhw6wYJLvVk2EdzP35mVCIVznCwa25y0L0tvRVKnXt1j6P3EWx8AToIEcYhGjiFgsVmFPqVmRArLp8xZWN5XSN+dggkasW+9EJ0Veg8ENzTxEKBrxWq9+0CfHl7UT7HPwzjiNts6mWONMG6BOtTd77XdWHKfc56YT5Blw4PcIkA= X-MS-TrafficTypeDiagnostic: DB6PR0301MB2135: X-Microsoft-Exchange-Diagnostics: 1; DB6PR0301MB2135; 20:ris+1roPBwC6qrXWf6CFO/QdBEi0uCGVhtmlu2HvyTDLFFxBpAegBxbDJKqmdcH3uu6sWNydNPazfLg21VY60/g4bd+sWWsGF7M6UD5d2KEmuS/U5J1U2mxmZVsbT6U8W9m6CQns41BydZ8enutAFDuswceZy6KQ4Iw40r7BCUQnMZpTtRVP0ktr1ha8Qd2a62c0YNgVZ6db0q6RQQKOvvSIpivtNGdKFU4tC9UZCbJXJ0g8fdi0nCqfvF0AHsJvcD/AjTk9t/DHz/5JKc2XP5gQ9FunSgM9qOdOR0kAwroBAEdT5Rn+X42lLHHc36znreVIY8Qz20QiXQtUlBRFwENRL1+SVbA+2fE6L5LVkFx+dcHE0nrN/4QuYcelINj078HD0Qlv78vcGEAKb7EjZjvbS8Lnj8uz6K9fooasMJxXBDG5QJAqRNpaU4BFfXN26NwUFqnGYrRigmU1D7mtL+9w9tpZoIzSrxqHAV3VuT3FmxQzkFntky/9CvGiiymU; 4:v/b9DzA3p7ZokAdbGRxnZ+h5jEJmhmFU6IFg8DudyQnlcIqSErGXQKn3afA35fYvzdBIiBp2/ILlc9SbGqKwV8Q+hr66hxDieVc4koijBApyS+CjgOQfeMnDDSmEjSCialYhueQn7oOePBUSsqLJIr1Ghv5x4o8SAiFdKCsE4OveBFCoDBZM5QrVZNdKoijJiEZi03vWU6NTCPnSGIiAY7NIDu4+4rzXndiBMxFKx+a7yqC8ysxsA6wXZ6+aFwle X-Exchange-Antispam-Report-Test: UriScan:; X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(2401047)(5005006)(8121501046)(100000703101)(100105400095)(93006095)(93001095)(10201501046)(3002001)(6041248)(20161123562025)(20161123560025)(20161123564025)(20161123558100)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123555025)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:DB6PR0301MB2135; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:DB6PR0301MB2135; X-Forefront-PRVS: 0444EB1997 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6009001)(346002)(376002)(199003)(189002)(8936002)(97736004)(81166006)(81156014)(50466002)(5660300001)(5003940100001)(66066001)(8676002)(316002)(86362001)(50226002)(16586007)(42186006)(105586002)(106356001)(68736007)(122856001)(2906002)(80792005)(189998001)(33646002)(3846002)(6116002)(4326008)(50986999)(7736002)(36756003)(76176999)(101416001)(305945005)(53936002)(48376002)(39060400002)(72206003)(2950100002)(6916009)(47776003)(478600001); DIR:OUT; SFP:1101; SCL:1; SRVR:DB6PR0301MB2135; H:EPUAKYIW2556.kyiv.epam.com; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: epam.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DB6PR0301MB2135; 23:ilx1epV9bB1r3n/1H22KY8+s7sSXHWasY33FVRR?= =?us-ascii?Q?585CEuopd4YG6WC7zcYK0gHWfbf8tcb7408AEEa1ZTAKeePr6tSqfAR83SaI?= =?us-ascii?Q?pZ8p4Dt3D79uoGs8OPBLX7+I+m/Zgcpk+iqSzHFn9uLzVEZdhIRJPo//okgH?= =?us-ascii?Q?4+3dbvNgGaAwdhR9ZZBa2l6Sy6xpOHlD2E0VXCxV8Pk4jQHCo4mS22G0kxDO?= =?us-ascii?Q?32Iawms8DL1rnOJ5Fqwq6tyZHeI4VYgIxQvlCV90428I/k2Z6ToO1+AWh2S0?= =?us-ascii?Q?JhgCnX/SCyhBGNxmhZhRccPKKNHeR85bI5rdvOVnOmOfU0jTtT82s264Rp8E?= =?us-ascii?Q?36pfOnrqFbGLPW5zvwAAZiO7Rm93eWkaUAHB/v/0ajq1fEZ7SIOQIOycbvee?= =?us-ascii?Q?9E2U/LtpSfZMpti3Xomz0oM/j1C0Fe2eOQAMeHu2mA8PtDEIOqE8UzB3MjK5?= =?us-ascii?Q?vAf2IuRThqfUULEN+G9h0BgvrS69JokkTmgJ++BybicmLKThte7u2XK6fcaB?= =?us-ascii?Q?KIfcdAcD+e4WG9AH1Y9bNp6ur0r3u/Id5PXZDZI7y3ZZen3RLdx4zxqtl0to?= =?us-ascii?Q?AF+Ok4/TrHu3WdtwLaE6jbKOTrOaaSHsGe3jrqNsCTdrJ7w/E9fmHRNY/pHl?= =?us-ascii?Q?PoN3aNBvyvq0u1sMTg1aPWME3B7F6W584I0U167921JyKp/jhAr+Jz2ZJ2Ek?= =?us-ascii?Q?XI2wBSFBtTw9hWsEZEiwu94D+r1dDljgeliiH4L8m1fg55QRks6byU2sOT5N?= =?us-ascii?Q?dbhtYSzTc9x6mWP5LPVCXJ7ysJJiGLzOCBb/BsjpibwhusgzWmXg5TPX6ybT?= =?us-ascii?Q?Xky5FlA8Zo2Y0nLvwd+BsAqL8hkSyNXD3gPfRDsUNqC/lAPnuG2efahCX/UM?= =?us-ascii?Q?ZSOdW4UEFVLJxxCnBJZplnYxhplhvGRdIss06n32j15U9SyvxPGJP94AGPp4?= =?us-ascii?Q?FSCuhXSzq6mljD6qaT14jjg/PdrBdi2r72bUvighGAgYax484p5XRJaaqwa3?= =?us-ascii?Q?SkS8gYzQqNDCMtxgzdbw4DsofydniDh31KxvgLacyc5cGYGojO5SZzrCpDUd?= =?us-ascii?Q?UJnOg3IE=3D?= X-Microsoft-Exchange-Diagnostics: 1; DB6PR0301MB2135; 6:U/ntYuoYhmsatXT+Le+g2HT/3rzErRKjcy9SPFuJuIQEFGY4gdORkzjDNaNvU5Bid0EmmrJCJnj/v5VXt9vVgDi94tUiY/He8+zPUFai3nxlvg8q7pe+cTXaJuUyzpr9W4REjnSsorvDbBv7DEMe1pIBd+T022pdDlVP6z3KF3P6LK8TgR/HxUD8wXQQDKgbBsrlTjvvhW8JxTcWBgb9WLzE9xnaJs7ItPr5xIFuixgj0e132OJtcRf7h9Hs7CX99PP1iZKFFZecwUJ+uUoJ5yBD14r90Z7EY6cptZ6KsNA3gZzLb0CsqjOCa6X+qBMbLZC9FUityMLfWdr1swSPAQ==; 5:u5VDNaq10xX9i92zShsJhDkF61+iMd0trfY17bcYCCryVWbiWpoYF3W5hNrzZ6508eNJHFU0QGD2jSgabMmJ7CfAikFwLkREFPRYV093/lhYBIYpcsGQgKHO1Ma2mqlGU1XLF0Mg9YNVVgoq+bn7EQ==; 24:2WYByO73Z4hBxF4lS5CVE5velYLLL7nKR9crJDfHawHdsrCeMiK1mT3UQMhEahtSjupEaQ0hXka3puk1KstKrpCaRc8mQrmMWOJDNNFpV08=; 7:XxYfr0ecxDzNJVh+bN17EserDTwWRg2SDWZcxMx6R0Qs/68dMHov9oPijDgVdvUp7gGwgnI1ylTbc5AMCOM86ZyqiL4rZVtgt2jPiixXVrueVxaQMOJ5yjEE4uQ0RH+VyL+KTrHrPoTILK6irWPYXgtgQ8fPjo2DVPAzZZrcT+KcuFNuEGo5EAn0yHObN6767T9j7/fDgSIZQnLCHRtNFDvZIzeO3pOWbe+LYT7/ymg= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: epam.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 Sep 2017 18:05:08.2026 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: b41b72d0-4e9f-4c26-8a69-f949f367c91d X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR0301MB2135 X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Volodymyr Babchuk Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP From: Volodymyr Babchuk There were changes in REE<->OP-TEE ABI recently. Now ABI allows us to pass non-contiguous memory buffers as list of pages to OP-TEE. This can be achieved by using new parameter attribute OPTEE_MSG_ATTR_NONCONTIG. OP-TEE also is able to use all non-secure RAM for shared buffers. This new capability is enabled with OPTEE_SMC_SEC_CAP_DYNAMIC_SHM flag. This patch adds necessary definitions to the protocol definition files at Linux side. Signed-off-by: Volodymyr Babchuk --- drivers/tee/optee/optee_msg.h | 38 ++++++++++++++++++++++++++++++++------ drivers/tee/optee/optee_smc.h | 7 +++++++ 2 files changed, 39 insertions(+), 6 deletions(-) diff --git a/drivers/tee/optee/optee_msg.h b/drivers/tee/optee/optee_msg.h index dd7a06e..3050490 100644 --- a/drivers/tee/optee/optee_msg.h +++ b/drivers/tee/optee/optee_msg.h @@ -67,11 +67,32 @@ #define OPTEE_MSG_ATTR_META BIT(8) /* - * The temporary shared memory object is not physically contigous and this - * temp memref is followed by another fragment until the last temp memref - * that doesn't have this bit set. + * Pointer to a list of pages used to register user-defined SHM buffer. + * Used with OPTEE_MSG_ATTR_TYPE_TMEM_*. + * buf_ptr should point to the beginning of the buffer. Buffer will contain + * list of page addresses. OP-TEE core can reconstruct contiguous buffer from + * that page addresses list. Page addresses are stored as 64 bit values. + * Last entry on a page should point to the next page of buffer. + * Every entry in buffer should point to a 4k page beginning (12 least + * significant bits must be equal to zero). + * + * 12 least significant bints of optee_msg_param.u.tmem.buf_ptr should hold page + * offset of the user buffer. + * + * So, entries should be placed like members of this structure: + * + * struct page_data { + * uint64_t pages_array[OPTEE_MSG_NONCONTIG_PAGE_SIZE/sizeof(uint64_t) - 1]; + * uint64_t next_page_data; + * }; + * + * Structure is designed to exactly fit into the page size + * OPTEE_MSG_NONCONTIG_PAGE_SIZE which is a standard 4KB page. + * + * The size of 4KB is chosen because this is the smallest page size for ARM + * architectures. If REE uses larger pages, it should divide them to 4KB ones. */ -#define OPTEE_MSG_ATTR_FRAGMENT BIT(9) +#define OPTEE_MSG_ATTR_NONCONTIG BIT(9) /* * Memory attributes for caching passed with temp memrefs. The actual value @@ -94,6 +115,11 @@ #define OPTEE_MSG_LOGIN_APPLICATION_USER 0x00000005 #define OPTEE_MSG_LOGIN_APPLICATION_GROUP 0x00000006 +/* + * Page size used in non-contiguous buffer entries + */ +#define OPTEE_MSG_NONCONTIG_PAGE_SIZE 4096 + /** * struct optee_msg_param_tmem - temporary memory reference parameter * @buf_ptr: Address of the buffer @@ -145,8 +171,8 @@ struct optee_msg_param_value { * * @attr & OPTEE_MSG_ATTR_TYPE_MASK indicates if tmem, rmem or value is used in * the union. OPTEE_MSG_ATTR_TYPE_VALUE_* indicates value, - * OPTEE_MSG_ATTR_TYPE_TMEM_* indicates tmem and - * OPTEE_MSG_ATTR_TYPE_RMEM_* indicates rmem. + * OPTEE_MSG_ATTR_TYPE_TMEM_* indicates @tmem and + * OPTEE_MSG_ATTR_TYPE_RMEM_* indicates @rmem, * OPTEE_MSG_ATTR_TYPE_NONE indicates that none of the members are used. */ struct optee_msg_param { diff --git a/drivers/tee/optee/optee_smc.h b/drivers/tee/optee/optee_smc.h index 069c8e1..7cd3272 100644 --- a/drivers/tee/optee/optee_smc.h +++ b/drivers/tee/optee/optee_smc.h @@ -222,6 +222,13 @@ struct optee_smc_get_shm_config_result { #define OPTEE_SMC_SEC_CAP_HAVE_RESERVED_SHM BIT(0) /* Secure world can communicate via previously unregistered shared memory */ #define OPTEE_SMC_SEC_CAP_UNREGISTERED_SHM BIT(1) + +/* + * Secure world supports commands "register/unregister shared memory", + * secure world accepts command buffers located in any parts of non-secure RAM + */ +#define OPTEE_SMC_SEC_CAP_DYNAMIC_SHM BIT(2) + #define OPTEE_SMC_FUNCID_EXCHANGE_CAPABILITIES 9 #define OPTEE_SMC_EXCHANGE_CAPABILITIES \ OPTEE_SMC_FAST_CALL_VAL(OPTEE_SMC_FUNCID_EXCHANGE_CAPABILITIES)