From patchwork Fri Jul 12 01:19:32 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Roth X-Patchwork-Id: 11040989 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 3DE64138B for ; Fri, 12 Jul 2019 01:43:56 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2FBF4289EA for ; Fri, 12 Jul 2019 01:43:56 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 245EE28BAF; Fri, 12 Jul 2019 01:43:56 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id C0DE2289EA for ; Fri, 12 Jul 2019 01:43:55 +0000 (UTC) Received: from localhost ([::1]:46162 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hlkbK-00078g-2V for patchwork-qemu-devel@patchwork.kernel.org; Thu, 11 Jul 2019 21:43:54 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60965) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hlkb5-0006Jt-Sl for qemu-devel@nongnu.org; Thu, 11 Jul 2019 21:43:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hlkb4-0003FU-TO for qemu-devel@nongnu.org; Thu, 11 Jul 2019 21:43:39 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:33120) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hlkb4-0003En-HZ for qemu-devel@nongnu.org; Thu, 11 Jul 2019 21:43:38 -0400 Received: from pps.filterd (m0098394.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x6C1gDrM138066 for ; Thu, 11 Jul 2019 21:43:37 -0400 Received: from e13.ny.us.ibm.com (e13.ny.us.ibm.com [129.33.205.203]) by mx0a-001b2d01.pphosted.com with ESMTP id 2tpfh0tdjv-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 11 Jul 2019 21:43:37 -0400 Received: from localhost by e13.ny.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 12 Jul 2019 02:21:02 +0100 Received: from b01cxnp22034.gho.pok.ibm.com (9.57.198.24) by e13.ny.us.ibm.com (146.89.104.200) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Fri, 12 Jul 2019 02:20:30 +0100 Received: from b01ledav003.gho.pok.ibm.com (b01ledav003.gho.pok.ibm.com [9.57.199.108]) by b01cxnp22034.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x6C1K1Qp49021416 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 12 Jul 2019 01:20:01 GMT Received: from b01ledav003.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 089E3B206B; Fri, 12 Jul 2019 01:20:01 +0000 (GMT) Received: from b01ledav003.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id DF26EB2064; Fri, 12 Jul 2019 01:20:00 +0000 (GMT) Received: from localhost (unknown [9.53.179.212]) by b01ledav003.gho.pok.ibm.com (Postfix) with ESMTP; Fri, 12 Jul 2019 01:20:00 +0000 (GMT) From: Michael Roth To: qemu-devel@nongnu.org Date: Thu, 11 Jul 2019 20:19:32 -0500 X-Mailer: git-send-email 2.17.1 X-TM-AS-GCONF: 00 x-cbid: 19071201-0064-0000-0000-000003FA8FFE X-IBM-SpamModules-Scores: X-IBM-SpamModules-Versions: BY=3.00011412; HX=3.00000242; KW=3.00000007; PH=3.00000004; SC=3.00000286; SDB=6.01230877; UDB=6.00648363; IPR=6.01012152; MB=3.00027683; MTD=3.00000008; XFM=3.00000015; UTC=2019-07-12 01:21:00 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19071201-0065-0000-0000-00003E3A2A2B Message-Id: <20190712011934.29863-1-mdroth@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-07-11_07:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1907120020 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 148.163.156.1 Subject: [Qemu-devel] [RFC PATCH 0/2] spapr: Implement H_TPM_COMM for accessing host TPM device X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linuxram@us.ibm.com, qemu-ppc@nongnu.org, david@gibson.dropbear.id.au Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP These patches are also available at: https://github.com/mdroth/qemu/commits/spapr-tpm-hcall-v0 This patchset implements the H_TPM_COMM hypercall, which provides a way for an Ultravisor to pass raw TPM commands on to a host's TPM device, either directly or through a TPM Resource Manager (needed to support multiple guests). Secure Guests running on an Ultravisor have a symmetric key that is encrypted using a public key that is bound to a trusted host's TPM hardware. This hypercall provides a means to decrypt the symmetric key on behalf of a Secure Guest using the host's TPM hardware. More details are provided in the spec summary introduced in patch 1. docs/specs/ppc-spapr-uv-hcalls.txt | 74 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ hw/ppc/Makefile.objs | 1 + hw/ppc/spapr.c | 27 +++++++++++++++++++++++++++ hw/ppc/spapr_hcall_tpm.c | 135 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ hw/ppc/trace-events | 4 ++++ include/hw/ppc/spapr.h | 7 ++++++- 6 files changed, 247 insertions(+), 1 deletion(-)