From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46721) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eyOFn-0008M4-Pp for qemu-devel@nongnu.org; Tue, 20 Mar 2018 16:53:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eyOFj-00022f-7g for qemu-devel@nongnu.org; Tue, 20 Mar 2018 16:53:07 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:56370) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1eyOFi-00022K-Th for qemu-devel@nongnu.org; Tue, 20 Mar 2018 16:53:03 -0400 Received: from pps.filterd (m0098404.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w2KKo40f014094 for ; Tue, 20 Mar 2018 16:53:01 -0400 Received: from e36.co.us.ibm.com (e36.co.us.ibm.com [32.97.110.154]) by mx0a-001b2d01.pphosted.com with ESMTP id 2gu6h6r6jx-1 (version=TLSv1.2 cipher=AES256-SHA256 bits=256 verify=NOT) for ; Tue, 20 Mar 2018 16:53:01 -0400 Received: from localhost by e36.co.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 20 Mar 2018 14:53:00 -0600 From: Stefan Berger Date: Tue, 20 Mar 2018 16:52:50 -0400 In-Reply-To: <1521579171-26213-1-git-send-email-stefanb@linux.vnet.ibm.com> References: <1521579171-26213-1-git-send-email-stefanb@linux.vnet.ibm.com> Message-Id: <1521579171-26213-4-git-send-email-stefanb@linux.vnet.ibm.com> Subject: [Qemu-devel] [PATCH v2 3/4] tpm: CRB: reset locAssigned upon relinquishing locality List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: marcandre.lureau@redhat.com, Stefan Berger Signed-off-by: Stefan Berger --- hw/tpm/tpm_crb.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/tpm/tpm_crb.c b/hw/tpm/tpm_crb.c index 4bd76b5..e8c42f6 100644 --- a/hw/tpm/tpm_crb.c +++ b/hw/tpm/tpm_crb.c @@ -137,6 +137,8 @@ static void tpm_crb_mmio_write(void *opaque, hwaddr addr, /* not loc 3 or 4 */ break; case CRB_LOC_CTRL_RELINQUISH: + ARRAY_FIELD_DP32(s->regs, CRB_LOC_STATE, + locAssigned, 0); break; case CRB_LOC_CTRL_REQUEST_ACCESS: ARRAY_FIELD_DP32(s->regs, CRB_LOC_STS, -- 2.5.5