Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp104533pxj; Wed, 16 Jun 2021 21:35:35 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwUd4QdHpjSHPjqaJZswfkoNtzmqUr9fCz+pcqW6m+mlE3LGNk9PbvWemCFpfr37f9gY3mH X-Received: by 2002:a5d:9acd:: with SMTP id x13mr2222082ion.134.1623904535330; Wed, 16 Jun 2021 21:35:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623904535; cv=none; d=google.com; s=arc-20160816; b=V7xG6htDJCJN2LZiPyUSMKAOY7MZAlwW3yqeiM25Aw0GH1aG9dR7C3uf9d58E9iYgr 7f9GBGiONrNk5zy6XP24zCcVTBPjNkUvq+uiQP0XXX3vqC7/+efSqX47u82ZflQl6qhP UTdSvcC2iKvChwpzM7ZAcsHvBNGj6RWW2gfbWoZ5ZVYlK1RcKl8wa1RaQ73nrelY/oD9 xy0r9pjC7HkNeBs5yPWpdKT1K8s7dUaGvvnelaHR2FT9CaH2r1SO/Pd7ZKWp/d9kZRWl CH2Og4ucDjYHm4pbAVKjw2LmOELBOGJQh/CwzWNcFXaD6Z25gaN/ShIOG81sPtyzNnxB b30A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=XZjUR44YaNoQXcJB+dlktg3mNBZU4O2yhCDUy1ikvnA=; b=mHXanD1VQ7j0q9tv5KFFmbLsIrP0F18upIyl8vxFVvRNCAAFMjOTvwHHLiNerumA1D /LXpLj2e0MPLNeH188BdmVOlkRskYqp3d3WjB2NYoS4Trm0ciddSrG89PmDV9CjA+DS9 T47z/WGbu2t83WhXV8IJVpAG9IwBzvB+TAAh1kwbvCYwbvk4mvce39SU+6umcxiREbSj oGZ7MmQQvBiu7eNA0jWmLHXVm3QItPiGi+5lMscm7dMwzrh2aQNzNna3wLH6ctMByse3 //qFbCG3Mv/ZDgPj+GBlaZ7s1tfffKcZK2xXMyB+KKAjISSR+xHvvOdHbHH448e/wOaG S0KQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=VTA9Hcmi; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m6si4890912iol.83.2021.06.16.21.35.22; Wed, 16 Jun 2021 21:35:35 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=VTA9Hcmi; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229546AbhFQEfg (ORCPT + 99 others); Thu, 17 Jun 2021 00:35:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43006 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229515AbhFQEfg (ORCPT ); Thu, 17 Jun 2021 00:35:36 -0400 Received: from mail-lj1-x22d.google.com (mail-lj1-x22d.google.com [IPv6:2a00:1450:4864:20::22d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CE1AAC061574 for ; Wed, 16 Jun 2021 21:33:28 -0700 (PDT) Received: by mail-lj1-x22d.google.com with SMTP id l15so2705808lje.10 for ; Wed, 16 Jun 2021 21:33:28 -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=XZjUR44YaNoQXcJB+dlktg3mNBZU4O2yhCDUy1ikvnA=; b=VTA9HcmiANLZolcCm6eIiiATqHIyWdcIcc/pObJ3eMq4PmtDTYhHmSCCMSEIG+AAYH JIMtKQg0rUlWhZh0BxBC6WbrtwS7DtZSEY+tivkhFdpNZ7WnoUf5E/L5gjDrxNp4bxIs rhPLQAsPvvaoPdEJ040GMoeD3Spe+426FQIQ11pnUCpa77ib3GALo1RxAqBPhMkm9TvV FEhqPO98wdT40c0ldFgbOmBsFPeLxJCqgR4/DfeW38Or3kmXng6LRI1+nmCqaWHHHPi1 dAdJiGoPoj9MPX3wC+nF+gXynznwQE6cEL3a/m2S/N7rQHT2FW2hGxvlQVL7wkwDnxRc 0Wcg== 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=XZjUR44YaNoQXcJB+dlktg3mNBZU4O2yhCDUy1ikvnA=; b=U67jcG+lBhUfv6eqDcZTfz/c/AMvRY/agFA9GyADoOFkFpGhb5A/dNlMG87/RGvMt6 J/rN4+8Olm3sRaUjY5viIt7YmGH8RaCjVDlyMYGEHQW7jLKt1yGiwcNamPZSsiB5lXFr /1V0TSEln3zn29LsiDLHGAEnQJcPTT/WaNO3bmK45FtT6XtXipVsAgUYoIt8w1i9NVzk +S9AP5Jkz35GJyuR4JJASCyRY8wi0bp61Ut2IpIGx/pNJ200VQsAPmf1HEAxVR6lyGz4 KyAUqeC+Itr10d2aooF4DVP/XVkiguXKGyQydDwWxDtk1Gv0Ex85uusnxbWUlljrLDQ2 iTcw== X-Gm-Message-State: AOAM533YEWptv4sHCxcUy/2ZJ+VVN9sadozv5DwAyqZRcwNvdtqREWyJ krLHTRYWDPg/BAuS8dtH00DeKGP69YoKEbbDasUK/w== X-Received: by 2002:a2e:311:: with SMTP id 17mr2780769ljd.442.1623904407105; Wed, 16 Jun 2021 21:33:27 -0700 (PDT) MIME-Version: 1.0 References: <20210616103649.2662395-1-jens.wiklander@linaro.org> In-Reply-To: <20210616103649.2662395-1-jens.wiklander@linaro.org> From: Sumit Garg Date: Thu, 17 Jun 2021 10:03:14 +0530 Message-ID: Subject: Re: [PATCH v2 0/7] Asynchronous notifications from secure world To: Jens Wiklander Cc: Linux Kernel Mailing List , linux-arm-kernel , op-tee@lists.trustedfirmware.org, Devicetree List , Linux Doc Mailing List , Jerome Forissier , Etienne Carriere , Vincent Guittot , Rob Herring , Jonathan Corbet , Ard Biesheuvel , Marc Zyngier Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Jens, On Wed, 16 Jun 2021 at 16:07, Jens Wiklander wrote: > > Hi all, > > This adds support for asynchronous notifications from OP-TEE in secure > world to the OP-TEE driver. This allows a design with a top half and bottom > half type of driver where the top half runs in secure interrupt context and > a notifications tells normal world to schedule a yielding call to do the > bottom half processing. > > An interrupt is used to notify the driver that there are asynchronous > notifications pending. > It looks like a nice feature. I would like to get hands on with this. Can I test this feature on Qemu? -Sumit > v2: > * Added documentation > * Converted optee bindings to json-schema and added interrupt property > * Configure notification interrupt from DT instead of getting it > from secure world, suggested by Ard Biesheuvel . > > Thanks, > Jens > > Jens Wiklander (7): > docs: staging/tee.rst: add a section on OP-TEE notifications > dt-bindings: arm: Convert optee binding to json-schema > dt-bindings: arm: optee: add interrupt property > tee: fix put order in teedev_close_context() > tee: add tee_dev_open_helper() primitive > optee: separate notification functions > optee: add asynchronous notifications > > .../bindings/arm/firmware/linaro,optee-tz.txt | 31 --- > .../arm/firmware/linaro,optee-tz.yaml | 57 +++++ > Documentation/staging/tee.rst | 27 +++ > drivers/tee/optee/Makefile | 1 + > drivers/tee/optee/call.c | 27 +++ > drivers/tee/optee/core.c | 87 +++++-- > drivers/tee/optee/notif.c | 226 ++++++++++++++++++ > drivers/tee/optee/optee_msg.h | 9 + > drivers/tee/optee/optee_private.h | 23 +- > drivers/tee/optee/optee_rpc_cmd.h | 31 +-- > drivers/tee/optee/optee_smc.h | 75 +++++- > drivers/tee/optee/rpc.c | 73 +----- > drivers/tee/tee_core.c | 37 ++- > include/linux/tee_drv.h | 27 +++ > 14 files changed, 576 insertions(+), 155 deletions(-) > delete mode 100644 Documentation/devicetree/bindings/arm/firmware/linaro,optee-tz.txt > create mode 100644 Documentation/devicetree/bindings/arm/firmware/linaro,optee-tz.yaml > create mode 100644 drivers/tee/optee/notif.c > > -- > 2.31.1 >