From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 81AB93858C53; Mon, 28 Aug 2023 18:24:57 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 81AB93858C53 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1693247097; bh=yNqb0+uSz1preHPJz0uAa2dtpvkpUjXNLkL2VqAdO6I=; h=From:To:Subject:Date:In-Reply-To:References:From; b=wNhbTPPK+Mmd+4oPnMhzFYzuO9I3cOrCL1Zl7DjpgLoA9qxNvKY9iL/mxwBwwGTXU H24gpBT+qsEQEyq5DB+v6AkNR0YSlUk58AQAfEw3lBJ1pgne3LdH19uE/9BG8AV1Xe 4lExOsEoZBeH+g+O10gajhwhk7ocvvyLeCvvKdms= From: "decui at microsoft dot com" To: glibc-bugs@sourceware.org Subject: [Bug libc/30643] Missing cache information on x86-64 under Intel TDX Date: Mon, 28 Aug 2023 18:24:57 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: libc X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: decui at microsoft dot com X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: hjl.tools at gmail dot com X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: security- X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://sourceware.org/bugzilla/show_bug.cgi?id=3D30643 --- Comment #6 from Dexuan Cui --- My TDX blade is running a Hyper-V dev build (July 26), which should be simi= lar to the version on Azure. My Ubuntu 20.04 VM has glibc 2.31-0ubuntu9.9. I'm running this kernel [1] in the VM: the kernel here means v6.5-rc4 + the patches in the Hyper-V tree's = next branch [2] + a few other patches. The patches should not affect the values returned from CPUID) Hyper-V provides two modes for running Intel TDX VMs [3]: Mode A) TD Partitioning mode with a paravisor. Mode B) In "fully enlightened" mode with normal TDX shared bit control ov= er page encryption, and no paravisor. This is the output for Mode A: # ./getconf-static -a | grep CACHE LEVEL1_ICACHE_SIZE 32768 LEVEL1_ICACHE_ASSOC LEVEL1_ICACHE_LINESIZE 64 LEVEL1_DCACHE_SIZE 49152 LEVEL1_DCACHE_ASSOC 12 LEVEL1_DCACHE_LINESIZE 64 LEVEL2_CACHE_SIZE 2097152 LEVEL2_CACHE_ASSOC 16 LEVEL2_CACHE_LINESIZE 64 LEVEL3_CACHE_SIZE 110100480 LEVEL3_CACHE_ASSOC 15 LEVEL3_CACHE_LINESIZE 64 LEVEL4_CACHE_SIZE LEVEL4_CACHE_ASSOC LEVEL4_CACHE_LINESIZE This is the output for Mode B: # ./getconf-static -a | grep CACHE LEVEL1_ICACHE_SIZE 32768 LEVEL1_ICACHE_ASSOC LEVEL1_ICACHE_LINESIZE 64 LEVEL1_DCACHE_SIZE 49152 LEVEL1_DCACHE_ASSOC 12 LEVEL1_DCACHE_LINESIZE 64 LEVEL2_CACHE_SIZE 2097152 LEVEL2_CACHE_ASSOC 16 LEVEL2_CACHE_LINESIZE 64 LEVEL3_CACHE_SIZE LEVEL3_CACHE_ASSOC LEVEL3_CACHE_LINESIZE LEVEL4_CACHE_SIZE LEVEL4_CACHE_ASSOC LEVEL4_CACHE_LINESIZE [1] https://github.com/dcui/linux/commits/decui/upstream-hyperv/hyperv-next/TDX= /0824-with-and-without-HCL [2] https://git.kernel.org/pub/scm/linux/kernel/git/hyperv/linux.git/log/?h=3Dh= yperv-next [3]https://lwn.net/ml/linux-kernel/20230824080712.30327-1-decui@microsoft.c= om/ --=20 You are receiving this mail because: You are on the CC list for the bug.=