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 6DDCFC07E9B for ; Wed, 7 Jul 2021 06:54:35 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 572BA61CA8 for ; Wed, 7 Jul 2021 06:54:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230378AbhGGG5N (ORCPT ); Wed, 7 Jul 2021 02:57:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51294 "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-x32d.google.com (mail-wm1-x32d.google.com [IPv6:2a00:1450:4864:20::32d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CFF62C061574 for ; Tue, 6 Jul 2021 23:54:31 -0700 (PDT) Received: by mail-wm1-x32d.google.com with SMTP id b14-20020a1c1b0e0000b02901fc3a62af78so3348224wmb.3 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=pm7sf7kPT6uEDgSqC/ILvofyFcH/XPsjxlfMfiHV6DKjLM8jX7AAv8oKMMdQDRCZ4l 13jLvV8JVV80k0ay3KINmbbHEyRQaYsnSvb4wx3omw7zley5DJo8JVwbrxmmGX2j9+fb B67kqLIvAal1UL7jjLoLBgKAs7Ope6fF6jlOLyIBuXVqIUG3ZNxCaD0DtaNtRPyhaM1C E8Dtdgsmfq7YjNDrFNEafCrBu2IMybAh9iUoo5HgHsbF4IQvCjRN1jD4oNEbIcgSGBMj pLLfs97Kfe7zeOo2eSJJYqO8ERMPzV6HSYSoA5N2lWhhbYHL5EWqm8B8OaO19w9/iANp pSzA== X-Gm-Message-State: AOAM5323RPgZ0ZfTkfGVaOjoFmiGAYXgWJR7IjDNwTSsOOqKEL2xRsSW aYd4i8iWZOEvr4+AYyKOyJ2OddG7OMWcb/S4Ackgow== 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: linux-kernel@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