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 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 2AD19C07E8E for ; Wed, 24 Apr 2024 13:19:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:Content-Type: Content-Transfer-Encoding:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:From:References:Cc:To:Subject: MIME-Version:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=NkIBSjj26BsV5m0h98o23XC1An+CuGPx7ntFRp6EKSM=; b=avqGw+FeJMElRU PyCNfSDi3SAHGJiaYjT/wD+MACVNedUTio84yA2grBH6EJkahZbwvTyn4PcgMm0SexFqK7vBowm3N AaKxW/+SO2HWaXsqtNjP9e0qgeFmNVnRbUbFwtDn31xPNHG3YGTKYq3HZ5VbCSvIS2XtDr7iHtFAs iV9KtLpRWEKvYbhCyDTEgR0PkgQtkA6/LjePjGh5xnlm7XnKvapJWPJGVjSecfR2sXfHes2Xr8Qc3 KxBMxEffCARABgWDQzjMj34HxFAASrW85r26CRWHV4m/FqAcW5P0qSxpT0VS0+SVu2f3NFkQKZwwx QJOhDrX3bvVFQXCVM6tw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rzcXE-00000004E2I-0Kgd; Wed, 24 Apr 2024 13:19:40 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rzcXB-00000004E0w-2ZmT for linux-arm-kernel@lists.infradead.org; Wed, 24 Apr 2024 13:19:39 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 438422F; Wed, 24 Apr 2024 06:20:02 -0700 (PDT) Received: from [10.57.86.198] (unknown [10.57.86.198]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 2932E3F64C; Wed, 24 Apr 2024 06:19:32 -0700 (PDT) Message-ID: <87ac462c-c453-4f3a-9b0e-5542727578aa@arm.com> Date: Wed, 24 Apr 2024 14:19:30 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2 14/14] virt: arm-cca-guest: TSM_REPORT support for realms Content-Language: en-GB To: Steven Price , kvm@vger.kernel.org, kvmarm@lists.linux.dev Cc: Sami Mujawar , Catalin Marinas , Marc Zyngier , Will Deacon , James Morse , Oliver Upton , Zenghui Yu , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Joey Gouly , Alexandru Elisei , Christoffer Dall , Fuad Tabba , linux-coco@lists.linux.dev, Ganapatrao Kulkarni References: <20240412084056.1733704-1-steven.price@arm.com> <20240412084213.1733764-1-steven.price@arm.com> <20240412084213.1733764-15-steven.price@arm.com> From: Suzuki K Poulose In-Reply-To: <20240412084213.1733764-15-steven.price@arm.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240424_061937_792365_48E07AB5 X-CRM114-Status: GOOD ( 19.38 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 12/04/2024 09:42, Steven Price wrote: > From: Sami Mujawar > > Introduce an arm-cca-guest driver that registers with > the configfs-tsm module to provide user interfaces for > retrieving an attestation token. > > When a new report is requested the arm-cca-guest driver > invokes the appropriate RSI interfaces to query an > attestation token. > > The steps to retrieve an attestation token are as follows: > 1. Mount the configfs filesystem if not already mounted > mount -t configfs none /sys/kernel/config > 2. Generate an attestation token > report=/sys/kernel/config/tsm/report/report0 > mkdir $report > dd if=/dev/urandom bs=64 count=1 > $report/inblob > hexdump -C $report/outblob > rmdir $report > > Signed-off-by: Sami Mujawar > Signed-off-by: Suzuki K Poulose > Signed-off-by: Steven Price > --- > drivers/virt/coco/Kconfig | 2 + > drivers/virt/coco/Makefile | 1 + > drivers/virt/coco/arm-cca-guest/Kconfig | 11 + > drivers/virt/coco/arm-cca-guest/Makefile | 2 + > .../virt/coco/arm-cca-guest/arm-cca-guest.c | 208 ++++++++++++++++++ > 5 files changed, 224 insertions(+) > create mode 100644 drivers/virt/coco/arm-cca-guest/Kconfig > create mode 100644 drivers/virt/coco/arm-cca-guest/Makefile > create mode 100644 drivers/virt/coco/arm-cca-guest/arm-cca-guest.c > > diff --git a/drivers/virt/coco/Kconfig b/drivers/virt/coco/Kconfig > index 87d142c1f932..4fb69804b622 100644 > --- a/drivers/virt/coco/Kconfig > +++ b/drivers/virt/coco/Kconfig > @@ -12,3 +12,5 @@ source "drivers/virt/coco/efi_secret/Kconfig" > source "drivers/virt/coco/sev-guest/Kconfig" > > source "drivers/virt/coco/tdx-guest/Kconfig" > + > +source "drivers/virt/coco/arm-cca-guest/Kconfig" > diff --git a/drivers/virt/coco/Makefile b/drivers/virt/coco/Makefile > index 18c1aba5edb7..a6228a1bf992 100644 > --- a/drivers/virt/coco/Makefile > +++ b/drivers/virt/coco/Makefile > @@ -6,3 +6,4 @@ obj-$(CONFIG_TSM_REPORTS) += tsm.o > obj-$(CONFIG_EFI_SECRET) += efi_secret/ > obj-$(CONFIG_SEV_GUEST) += sev-guest/ > obj-$(CONFIG_INTEL_TDX_GUEST) += tdx-guest/ > +obj-$(CONFIG_ARM_CCA_GUEST) += arm-cca-guest/ > diff --git a/drivers/virt/coco/arm-cca-guest/Kconfig b/drivers/virt/coco/arm-cca-guest/Kconfig > new file mode 100644 > index 000000000000..c4039c10dce2 > --- /dev/null > +++ b/drivers/virt/coco/arm-cca-guest/Kconfig > @@ -0,0 +1,11 @@ > +config ARM_CCA_GUEST > + tristate "Arm CCA Guest driver" > + depends on ARM64 > + default m > + select TSM_REPORTS > + help > + The driver provides userspace interface to request and > + attestation report from the Realm Management Monitor(RMM). > + > + If you choose 'M' here, this module will be called > + realm-guest. This needs to be updated to arm-cca-guest. Suzuki _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel