From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E4CD2C07E9C for ; Wed, 7 Jul 2021 06:54:33 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id CCB0461C77 for ; Wed, 7 Jul 2021 06:54:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230263AbhGGG5M (ORCPT ); Wed, 7 Jul 2021 02:57:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51298 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230305AbhGGG5M (ORCPT ); Wed, 7 Jul 2021 02:57:12 -0400 Received: from mail-wm1-x329.google.com (mail-wm1-x329.google.com [IPv6:2a00:1450:4864:20::329]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EC961C061762 for ; Tue, 6 Jul 2021 23:54:31 -0700 (PDT) Received: by mail-wm1-x329.google.com with SMTP id g10so1080855wmh.2 for ; Tue, 06 Jul 2021 23:54:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=tUE8wev4VkWfjOiCPCyu/GqgRwGG7gs7uHBEzTIZe3c=; b=HO5A4MDpkx13VC3Yw2cptgr73MkV2G5xH8GcIHQMD2ep1iOn3CS8VoF9o3sz43+71+ +R3aWRgRdYsGc6k3/64PPRrYJD21oDybN4rqEhpKo01JhMlzSsZO7a8AA9DtJ2BXuujx c0clc8S636KiUYaSY0FYeM3+kPfaJyglcf4WULX91rK5G+Ro3gKLyhZetCrXWUeVW75Q 9BgGYbV10cmt9K9NMzE3gPVjlh5YklXD5+L+dtzEhOS+JPnIYcUslFn69z82ZRbmriW1 ljQbYX9t34JqSYy11CaSfLUYiyr0FBIn0f9gUvE74yfUhGspGvfKQP7V9EeJRc8IrIQb 0ZfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=tUE8wev4VkWfjOiCPCyu/GqgRwGG7gs7uHBEzTIZe3c=; b=glHeD17jr/8W8GiQLFKEEP8NJEflExqVrXR4rBa/zCWcbIuiud46snd+mNkiRGWEDn FpPaDPA1FLP3sPjhWhfXEejy5eO2BcMIhj694LSU7YkXxxLsZqSVUDervwmasUxJYtpB hG70WhqnQfyeea5gTwDnr3mmkenmQK4Thfj/5D25SISD90nHf6mfXDmsRVJB8iKQ4QSd hq6LwWL6ib29WWQPHpcNt/m9Mqw0dM5XnHmu4/epcaR8fPhkz/4cxVbPIHweHVw90yku Yki65jd+K2Vl7r+mXI1gT2CM2WWnuLQgSxcOKh0YQNobfbhjlGMPX/hQ0EOqhcvskOK7 Y/ZA== X-Gm-Message-State: AOAM533Mw3lvN3RLtoRa5xv/fPLJ7zjUr27c2VKPYDNo0V32cU3Uy/px 05UvVbCWNgCGyFW4ev4FEe1ucJ12kC9RFyPrQrYaVw== X-Google-Smtp-Source: ABdhPJystGdZsA+nB5gQafyHzssXeyJUm/HUE9cWQIs/s/XU88ED35qV7XIB+cBbpx80emEOfYRUo2JXYOLR4W96FtE= X-Received: by 2002:a7b:ce82:: with SMTP id q2mr4888352wmj.60.1625640870431; Tue, 06 Jul 2021 23:54:30 -0700 (PDT) MIME-Version: 1.0 References: <20210616103649.2662395-1-jens.wiklander@linaro.org> <87czrv91b2.wl-maz@kernel.org> <87a6mz8vaj.wl-maz@kernel.org> In-Reply-To: From: Jens Wiklander Date: Wed, 7 Jul 2021 08:54:19 +0200 Message-ID: Subject: Re: [PATCH v2 0/7] Asynchronous notifications from secure world To: Sumit Garg Cc: Marc Zyngier , Linux Kernel Mailing List , linux-arm-kernel , OP-TEE TrustedFirmware , Devicetree List , Linux Doc Mailing List , Jerome Forissier , Etienne Carriere , Vincent Guittot , Rob Herring , Jonathan Corbet , Ard Biesheuvel Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Hi, On Wed, Jul 7, 2021 at 7:52 AM Sumit Garg wrote: > > On Tue, 6 Jul 2021 at 18:16, Marc Zyngier wrote: > > [snip] > > > > - Is there any case where you would instead need a level interrupt > > > > (which a SGI cannot provide)? > > > > > > I think SGI should be sufficient to suffice OP-TEE notifications use-case. > > > > I don't care about OP-TEE. If you are proposing a contract between S > > and NS, it has to be TEE and OS independent. That's how the > > architecture works. > > > > Agree, here we are not proposing a common contract among the S and NS > world that every TEE (based on Arm TrustZone) will use to communicate > with REE (Linux in our case) but rather an OP-TEE specific > notifications feature that is built on top of OP-TEE specific ABIs. > > And I can see your arguments coming from an FFA perspective but there > are platforms like the ones based on Armv7 which don't support FFA > ABI. Maybe Jens can elaborate how this feature will fit in when FFA > comes into picture? OP-TEE has one official ABI at the moment, the SMC based one. It's about to get another one based on FF-A instead. The two ABIs will never be used at the same time. It's a build time option for the OP-TEE firmware to either use SMC or FF-A based communication. The patches I've posted here concern the SMC based ABI. Asynchronous notification in OP-TEE with a FF-A based ABI will use the notification framework provided by FF-A instead to implement that counterpart provided by these patches. So the OP-TEE driver here in the kernel will use the FF-A framework in the kernel instead of registering an interrupt handler directly. Cheers, Jens