From nobody Sat Apr 20 10:00:12 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=none (zohomail.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=fail(p=none dis=none) header.from=citrix.com Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 158143014961383.26351995028028; Tue, 11 Feb 2020 06:09:09 -0800 (PST) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1j1WDR-0008EH-6w; Tue, 11 Feb 2020 14:08:41 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1j1WDQ-0008EC-Ct for xen-devel@lists.xenproject.org; Tue, 11 Feb 2020 14:08:40 +0000 Received: from esa1.hc3370-68.iphmx.com (unknown [216.71.145.142]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id 00624c40-4cd8-11ea-8bf0-bc764e2007e4; Tue, 11 Feb 2020 14:08:39 +0000 (UTC) X-Inumbo-ID: 00624c40-4cd8-11ea-8bf0-bc764e2007e4 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1581430120; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=wDZ8da/P3RxEsccKLRKUl5KDl0lqwvfsyMjzGM4ztf8=; b=XLwoH1gEhX8a4y+Nlesgr7zUvR2Vanq+wvILeNktK7zURxx1/F/SsyK3 VBzbAzACsvE6fNQSrPF9bh2rxfGn/eIUmGD00aI+pdme6d7wpbjyTGsuD mvL5mMyCN+qwcnR1vVyXc836WdN9ZSg4gAzOZ1IgZ7TNd012YLGTd6wIH U=; Authentication-Results: esa1.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none; spf=None smtp.pra=andrew.cooper3@citrix.com; spf=Pass smtp.mailfrom=Andrew.Cooper3@citrix.com; spf=None smtp.helo=postmaster@mail.citrix.com Received-SPF: none (zohomail.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Received-SPF: None (esa1.hc3370-68.iphmx.com: no sender authenticity information available from domain of andrew.cooper3@citrix.com) identity=pra; client-ip=162.221.158.21; receiver=esa1.hc3370-68.iphmx.com; envelope-from="Andrew.Cooper3@citrix.com"; x-sender="andrew.cooper3@citrix.com"; x-conformance=sidf_compatible Received-SPF: Pass (esa1.hc3370-68.iphmx.com: domain of Andrew.Cooper3@citrix.com designates 162.221.158.21 as permitted sender) identity=mailfrom; client-ip=162.221.158.21; receiver=esa1.hc3370-68.iphmx.com; envelope-from="Andrew.Cooper3@citrix.com"; x-sender="Andrew.Cooper3@citrix.com"; x-conformance=sidf_compatible; x-record-type="v=spf1"; x-record-text="v=spf1 ip4:209.167.231.154 ip4:178.63.86.133 ip4:195.66.111.40/30 ip4:85.115.9.32/28 ip4:199.102.83.4 ip4:192.28.146.160 ip4:192.28.146.107 ip4:216.52.6.88 ip4:216.52.6.188 ip4:162.221.158.21 ip4:162.221.156.83 ip4:168.245.78.127 ~all" Received-SPF: None (esa1.hc3370-68.iphmx.com: no sender authenticity information available from domain of postmaster@mail.citrix.com) identity=helo; client-ip=162.221.158.21; receiver=esa1.hc3370-68.iphmx.com; envelope-from="Andrew.Cooper3@citrix.com"; x-sender="postmaster@mail.citrix.com"; x-conformance=sidf_compatible IronPort-SDR: ZmCWkTZ+DE/ITDxNfkldmGvQZZ/rSSRwbsF3ybCsM6c7L+87GanYTThWOAuE/4kiQLBOU65QQS gX5RYQSNdDx41b0KkbqJPSYYDylK3VQTGtaS3XupVFz8GDSvgnYWnyofOmQDUTUfJDmFsFRim2 B58n3ZqE2p0YdlBC9mjNb+Zw87QdQVMtYb5YWu9ngAKmCgAeTRup6RHfTQ87GC03CHichj+sJJ zTIqgCUBx77LkizrINxL3CizTJwIbOex/zCOk/9HeslZd3qVtp+19n1whK47DS31d9KpgoAz+z hAA= X-SBRS: 2.7 X-MesageID: 12445351 X-Ironport-Server: esa1.hc3370-68.iphmx.com X-Remote-IP: 162.221.158.21 X-Policy: $RELAYED X-IronPort-AV: E=Sophos;i="5.70,428,1574139600"; d="scan'208";a="12445351" From: Andrew Cooper To: Xen-devel Date: Tue, 11 Feb 2020 14:08:25 +0000 Message-ID: <20200211140825.1192-1-andrew.cooper3@citrix.com> X-Mailer: git-send-email 2.11.0 MIME-Version: 1.0 Subject: [Xen-devel] [PATCH] hvmloader: Drop use of XENVER_extraversion X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: Andrew Cooper , Wei Liu , Jan Beulich , =?UTF-8?q?Roger=20Pau=20Monn=C3=A9?= Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) The printf() in init_hypercalls() only ends up in the hypervisor console lo= g, so extraversion really isn't interesting. The SMBios table doesn't need extraversion, and removing it reduces the ability for a guest to fingerprint the exact hypervisor it is running under. Signed-off-by: Andrew Cooper --- CC: Jan Beulich CC: Wei Liu CC: Roger Pau Monn=C3=A9 --- tools/firmware/hvmloader/hvmloader.c | 4 +--- tools/firmware/hvmloader/smbios.c | 10 ---------- 2 files changed, 1 insertion(+), 13 deletions(-) diff --git a/tools/firmware/hvmloader/hvmloader.c b/tools/firmware/hvmloade= r/hvmloader.c index 598a226278..99c8841790 100644 --- a/tools/firmware/hvmloader/hvmloader.c +++ b/tools/firmware/hvmloader/hvmloader.c @@ -121,7 +121,6 @@ static void init_hypercalls(void) uint32_t eax, ebx, ecx, edx; unsigned long i; char signature[13]; - xen_extraversion_t extraversion; uint32_t base; =20 for ( base =3D 0x40000000; base < 0x40010000; base +=3D 0x100 ) @@ -146,8 +145,7 @@ static void init_hypercalls(void) =20 /* Print version information. */ cpuid(base + 1, &eax, &ebx, &ecx, &edx); - hypercall_xen_version(XENVER_extraversion, extraversion); - printf("Detected Xen v%u.%u%s\n", eax >> 16, eax & 0xffff, extraversio= n); + printf("Detected Xen v%u.%u\n", eax >> 16, eax & 0xffff); } =20 /* Replace possibly erroneous memory-size CMOS fields with correct values.= */ diff --git a/tools/firmware/hvmloader/smbios.c b/tools/firmware/hvmloader/s= mbios.c index 97a054e9e3..46ba1cb7b3 100644 --- a/tools/firmware/hvmloader/smbios.c +++ b/tools/firmware/hvmloader/smbios.c @@ -256,7 +256,6 @@ hvm_write_smbios_tables( xen_domain_handle_t uuid; uint16_t xen_major_version, xen_minor_version; uint32_t xen_version; - char xen_extra_version[XEN_EXTRAVERSION_LEN]; /* guess conservatively on buffer length for Xen version string */ char xen_version_str[80]; /* temporary variables used to build up Xen version string */ @@ -274,8 +273,6 @@ hvm_write_smbios_tables( xen_major_version =3D (uint16_t) (xen_version >> 16); xen_minor_version =3D (uint16_t) xen_version; =20 - hypercall_xen_version(XENVER_extraversion, xen_extra_version); - /* build up human-readable Xen version string */ p =3D xen_version_str; len =3D 0; @@ -302,13 +299,6 @@ hvm_write_smbios_tables( strcpy(p, tmp); p +=3D tmp_len; =20 - tmp_len =3D strlen(xen_extra_version); - len +=3D tmp_len; - if ( len >=3D sizeof(xen_version_str) ) - goto error_out; - strcpy(p, xen_extra_version); - p +=3D tmp_len; - xen_version_str[sizeof(xen_version_str)-1] =3D '\0'; =20 /* scratch_start is a safe large memory area for scratch. */ --=20 2.11.0 _______________________________________________ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel