From patchwork Wed May 29 08:42:21 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?TGlqdS1jbHIgQ2hlbiAo6Zmz6bqX5aaCKQ==?= X-Patchwork-Id: 1941094 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=mediatek.com header.i=@mediatek.com header.a=rsa-sha256 header.s=dk header.b=uHmGkS5E; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=2604:1380:45e3:2400::1; helo=sv.mirrors.kernel.org; envelope-from=devicetree+bounces-70328-incoming-dt=patchwork.ozlabs.org@vger.kernel.org; receiver=patchwork.ozlabs.org) Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org [IPv6:2604:1380:45e3:2400::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Vq2w35n0Jz20Pc for ; Wed, 29 May 2024 18:43:15 +1000 (AEST) Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 6D2742872C5 for ; Wed, 29 May 2024 08:43:14 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 27C08169AD9; Wed, 29 May 2024 08:42:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=mediatek.com header.i=@mediatek.com header.b="uHmGkS5E" X-Original-To: devicetree@vger.kernel.org Received: from mailgw02.mediatek.com (unknown [210.61.82.184]) (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 64B4E7347D; Wed, 29 May 2024 08:42:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=210.61.82.184 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716972173; cv=none; b=G4eUl262iM00/7hCaGEPOG9K8mSPT3ZFRP/QIV61a4pDKiHYLMK526OyAhb39aGVXnQF0/G1DoUos4HmDZtYeyrKbTygq0DMy61Sd6C/SqDLdA6lQlm64vuAtOrm9Wd+N7kaJcxc0ht5pctrz9W4aGJgsDLxTMXVCAjLVHPg3hY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716972173; c=relaxed/simple; bh=Q62rf9UUSUDgLwM1lxhdNcBx1hr81BSniRYuHSbebLY=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=rQfj5UnDD4TFEZ0RPg7IGgHnoL2oEjOgob06pa4yit9pQo8eUZMuSbu06dMD39KKTRit7W/rlYAnwFZoz9X0fG9WRbn3FBN9HQVrS3WtxGdZtpFdAbqLvucy815GFxgG1bW3bzPDURNxq6oNNw588SLK+beTUTCwc4fVvzYZsEU= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=mediatek.com; spf=pass smtp.mailfrom=mediatek.com; dkim=pass (1024-bit key) header.d=mediatek.com header.i=@mediatek.com header.b=uHmGkS5E; arc=none smtp.client-ip=210.61.82.184 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=mediatek.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mediatek.com X-UUID: 6932f80c1d9711efbfff99f2466cf0b4-20240529 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=Mwk/tyTv9CQDrGBR2+J82VIQl88qfKTbtJvAZBieAtw=; b=uHmGkS5EuB/f9Lb6jRlHAlPhyS2Lff2BoLLZVJJi6BFRfctpuqcSWr9IgBkVYI6R/gMul984Z1THWrsYW47g/pqdr3uXgd4j4U93nt3ZrYW8s3fU6xqZeLdT3D9F4m+xozLpuFgAnH9J24mky6zE3u2EZh3ZJ1xYnQBLovhz3FU=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.39,REQID:c1f7e8b4-4315-442c-b5cc-d18a4049ad89,IP:0,U RL:25,TC:0,Content:-5,EDM:0,RT:0,SF:0,FILE:0,BULK:0,RULE:Release_Ham,ACTIO N:release,TS:20 X-CID-META: VersionHash:393d96e,CLOUDID:f20b7584-4f93-4875-95e7-8c66ea833d57,B ulkID:nil,BulkQuantity:0,Recheck:0,SF:102,TC:nil,Content:0,EDM:-3,IP:nil,U RL:11|1,File:nil,RT:nil,Bulk:nil,QS:nil,BEC:nil,COL:0,OSI:0,OSA:0,AV:0,LES :1,SPR:NO,DKR:0,DKP:0,BRR:0,BRE:0,ARC:0 X-CID-BVR: 0 X-CID-BAS: 0,_,0,_ X-CID-FACTOR: TF_CID_SPAM_ULN,TF_CID_SPAM_SNR X-UUID: 6932f80c1d9711efbfff99f2466cf0b4-20240529 Received: from mtkmbs14n1.mediatek.inc [(172.21.101.75)] by mailgw02.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 816346424; Wed, 29 May 2024 16:42:41 +0800 Received: from mtkmbs11n1.mediatek.inc (172.21.101.185) by mtkmbs11n2.mediatek.inc (172.21.101.187) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.26; Wed, 29 May 2024 16:42:39 +0800 Received: from mtksdccf07.mediatek.inc (172.21.84.99) by mtkmbs11n1.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.2.1118.26 via Frontend Transport; Wed, 29 May 2024 16:42:39 +0800 From: Liju-clr Chen To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Jonathan Corbet , Catalin Marinas , Will Deacon , Steven Rostedt , Masami Hiramatsu , Mathieu Desnoyers , Richard Cochran , Matthias Brugger , AngeloGioacchino Del Regno , Liju-clr Chen , Yingshiuan Pan , Ze-yu Wang CC: , , , , , , , David Bradil , Trilok Soni , Shawn Hsiao , PeiLun Suei , Chi-shen Yeh , Kevenny Hsieh Subject: [PATCH v11 03/21] dt-bindings: hypervisor: Add MediaTek GenieZone hypervisor Date: Wed, 29 May 2024 16:42:21 +0800 Message-ID: <20240529084239.11478-4-liju-clr.chen@mediatek.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20240529084239.11478-1-liju-clr.chen@mediatek.com> References: <20240529084239.11478-1-liju-clr.chen@mediatek.com> Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MTK: N From: Yi-De Wu From: "Yingshiuan Pan" Add documentation for GenieZone(gzvm) node. This node informs gzvm driver to start probing if proprietary geniezone hypervisor firmware is available and capable of executing virtual machine operations. [Reason to use dt solution] The GenieZone hypervisor acts as a vendor firmware to enable platform virtualization, offering an implementation that is independent of Linux-specific implementations. - Previously, our approach involved probing via hypercalls to detect the presence of our hypervisor firmware. However, this method raised concerns about potential impacts on all systems, including those without the embedded GenieZone hypervisor. - By utilizing the device tree solution, we can accurately identify the GenieZone hypervisor's presence without relying on hypercalls, ensuring a more targeted and efficient detection process that minimizes the risk of unintended consequences on non-GenieZone systems. Link: https://lore.kernel.org/all/2fe0c7f9-55fc-ae63-3631-8526a0212ccd@linaro.org/ Signed-off-by: Yingshiuan Pan Signed-off-by: Liju Chen Signed-off-by: Yi-De Wu --- .../bindings/firmware/mediatek,geniezone.yaml | 34 +++++++++++++++++++ MAINTAINERS | 3 +- 2 files changed, 36 insertions(+), 1 deletion(-) create mode 100644 Documentation/devicetree/bindings/firmware/mediatek,geniezone.yaml diff --git a/Documentation/devicetree/bindings/firmware/mediatek,geniezone.yaml b/Documentation/devicetree/bindings/firmware/mediatek,geniezone.yaml new file mode 100644 index 000000000000..9955890cb8b7 --- /dev/null +++ b/Documentation/devicetree/bindings/firmware/mediatek,geniezone.yaml @@ -0,0 +1,34 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/firmware/mediatek,geniezone.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: MediaTek GenieZone hypervisor + +maintainers: + - Yingshiuan Pan + +description: + GenieZone is a proprietary type-II hypervisor firmware developed by MediaTek, + providing an isolated execution environment for mTEE (MediaTek Trusted + Execution Environment) and AVF (Android Virtualization Framework) virtual + machines. This binding facilitates the integration of GenieZone into the + Android Virtualization Framework (AVF) with Crosvm as the VMM. The driver + exposes hypervisor control interfaces to the VMM for managing virtual + machine lifecycles and assisting virtual device emulation. + +properties: + compatible: + const: mediatek,geniezone + +required: + - compatible + +additionalProperties: false + +examples: + - | + hypervisor { + compatible = "mediatek,geniezone"; + }; diff --git a/MAINTAINERS b/MAINTAINERS index 59481b0764d6..f42bd174caad 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -9273,7 +9273,8 @@ F: lib/vdso/ GENIEZONE HYPERVISOR DRIVER M: Yingshiuan Pan M: Ze-Yu Wang -M: Yi-De Wu +M: Liju Chen +F: Documentation/devicetree/bindings/firmware/mediatek,geniezone.yaml F: Documentation/virt/geniezone/ GENWQE (IBM Generic Workqueue Card)