From nobody Tue Oct 28 12:12:52 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (208.118.235.17 [208.118.235.17]) by mx.zohomail.com with SMTPS id 1513606259822295.7289607888546; Mon, 18 Dec 2017 06:10:59 -0800 (PST) Received: from localhost ([::1]:38905 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eQw7y-00039d-DU for importer@patchew.org; Mon, 18 Dec 2017 09:10:46 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36386) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eQw5W-0001fu-UW for qemu-devel@nongnu.org; Mon, 18 Dec 2017 09:08:15 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eQw5U-0002UI-8b for qemu-devel@nongnu.org; Mon, 18 Dec 2017 09:08:14 -0500 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:57308 helo=mx0a-001b2d01.pphosted.com) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1eQw5U-0002Tm-39 for qemu-devel@nongnu.org; Mon, 18 Dec 2017 09:08:12 -0500 Received: from pps.filterd (m0098414.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id vBIE6DPn028695 for ; Mon, 18 Dec 2017 09:08:08 -0500 Received: from e31.co.us.ibm.com (e31.co.us.ibm.com [32.97.110.149]) by mx0b-001b2d01.pphosted.com with ESMTP id 2exc279cr5-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Mon, 18 Dec 2017 09:08:08 -0500 Received: from localhost by e31.co.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 18 Dec 2017 07:08:07 -0700 Received: from b03cxnp07029.gho.boulder.ibm.com (9.17.130.16) by e31.co.us.ibm.com (192.168.1.131) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Mon, 18 Dec 2017 07:08:04 -0700 Received: from b03ledav003.gho.boulder.ibm.com (b03ledav003.gho.boulder.ibm.com [9.17.130.234]) by b03cxnp07029.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id vBIE84UK59441392; Mon, 18 Dec 2017 07:08:04 -0700 Received: from b03ledav003.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id E05036A042; Mon, 18 Dec 2017 07:08:03 -0700 (MST) Received: from sbct-3.watson.ibm.com (unknown [9.47.158.153]) by b03ledav003.gho.boulder.ibm.com (Postfix) with ESMTP id 6D7F76A043; Mon, 18 Dec 2017 07:08:03 -0700 (MST) From: Stefan Berger To: qemu-devel@nongnu.org, thuth@redhat.com Date: Mon, 18 Dec 2017 09:07:58 -0500 X-Mailer: git-send-email 2.5.5 X-TM-AS-GCONF: 00 x-cbid: 17121814-8235-0000-0000-00000CBFE961 X-IBM-SpamModules-Scores: X-IBM-SpamModules-Versions: BY=3.00008222; HX=3.00000241; KW=3.00000007; PH=3.00000004; SC=3.00000244; SDB=6.00962030; UDB=6.00486591; IPR=6.00742025; BA=6.00005750; NDR=6.00000001; ZLA=6.00000005; ZF=6.00000009; ZB=6.00000000; ZP=6.00000000; ZH=6.00000000; ZU=6.00000002; MB=3.00018605; XFM=3.00000015; UTC=2017-12-18 14:08:06 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17121814-8236-0000-0000-00003EE43CC4 Message-Id: <1513606078-728-1-git-send-email-stefanb@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-12-18_10:, , 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 impostorscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1709140000 definitions=main-1712180187 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] [fuzzy] X-Received-From: 148.163.158.5 Subject: [Qemu-devel] [PATCH] tpm: Fix linker error when using --disable-tpm X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: peter.maydell@linaro.org, Stefan Berger , marcandre.lureau@redhat.com Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Commit 493b7830 extends core/qdev-properties-system.c with a property to lookup a TPM backend, which calls into TPM related functions. Unfortunately this breaks the build when --disable-tpm is used. To fix this we extend stubs/tpm.c with the missing stub functions. Signed-off-by: Stefan Berger --- stubs/tpm.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/stubs/tpm.c b/stubs/tpm.c index c18aac1..bb1db44 100644 --- a/stubs/tpm.c +++ b/stubs/tpm.c @@ -6,6 +6,7 @@ */ #include "qemu/osdep.h" #include "sysemu/tpm.h" +#include "sysemu/tpm_backend.h" #include "qmp-commands.h" =20 int tpm_init(void) @@ -31,3 +32,18 @@ TpmModelList *qmp_query_tpm_models(Error **errp) { return NULL; } + +void tpm_backend_reset(TPMBackend *s) +{ + return; +} + +int tpm_backend_init(TPMBackend *s, TPMIf *tpmif, Error **errp) +{ + return 0; +} + +TPMBackend *qemu_find_tpm_be(const char *id) +{ + return NULL; +} \ No newline at end of file --=20 2.5.5