mbox series

[0/1,kinetic/linux-azure] Azure: TDX enabled hyper-visors cause segfault

Message ID 20230123140233.790103-1-tim.gardner@canonical.com
Headers show
Series Azure: TDX enabled hyper-visors cause segfault | expand

Message

Tim Gardner Jan. 23, 2023, 2:02 p.m. UTC
https://bugs.launchpad.net/bugs/2003714

SRU Justification

[Impact]

Microsoft TDX enabled hyper visors cause a segfault due to an upstream glibc bug. This can
be worked around with a kernel patch.

Issue Description:

When I start an Intel TDX Ubuntu 22.04 (or RHEL 9.0) guest on Hyper-V, the guest
always hits segfaults and can’t boot up. Here the kernel running in the guest is
the upstream kernel + my TDX patchset, or the 5.19.0-azure kernel + the same TDX patchset:

[Fix]

We confirmed the segfault also happens to TDX guests on the KVM hypervisor. After I
checked with more Intel folks, it turns out this is indeed a glibc bug
(https://sourceware.org/bugzilla/show_bug.cgi?id=28784), which has been fixed in the
upsteram glibc, but Ubuntu 22.04 and newer haven’t picked up the glibc fix yet.

I got a kernel side temporary workarouond from Intel:
https://github.com/dcui/tdx/commit/16218cf73491e867fd39c16c9e4b8aa926cbda68, which
is on the same existing branch “decui/upstream-kinetic-22.10/master-next/1209”.

[Test Plan]

Microsoft tested

[Where things could go wrong]

TDX is a new feature. Regressions are unlikely.

Comments

Cengiz Can Jan. 23, 2023, 2:46 p.m. UTC | #1
On 23-01-23 07:02:32, Tim Gardner wrote:
> https://bugs.launchpad.net/bugs/2003714
> 
> SRU Justification
> 
> [Impact]
> 
> Microsoft TDX enabled hyper visors cause a segfault due to an upstream glibc bug. This can
> be worked around with a kernel patch.
> 
> Issue Description:
> 
> When I start an Intel TDX Ubuntu 22.04 (or RHEL 9.0) guest on Hyper-V, the guest
> always hits segfaults and can’t boot up. Here the kernel running in the guest is
> the upstream kernel + my TDX patchset, or the 5.19.0-azure kernel + the same TDX patchset:
> 
> [Fix]
> 
> We confirmed the segfault also happens to TDX guests on the KVM hypervisor. After I
> checked with more Intel folks, it turns out this is indeed a glibc bug
> (https://sourceware.org/bugzilla/show_bug.cgi?id=28784), which has been fixed in the
> upsteram glibc, but Ubuntu 22.04 and newer haven’t picked up the glibc fix yet.
> 
> I got a kernel side temporary workarouond from Intel:
> https://github.com/dcui/tdx/commit/16218cf73491e867fd39c16c9e4b8aa926cbda68, which
> is on the same existing branch “decui/upstream-kinetic-22.10/master-next/1209”.
> 
> [Test Plan]
> 
> Microsoft tested
> 
> [Where things could go wrong]
> 
> TDX is a new feature. Regressions are unlikely.
> 

Acked-by: Cengiz Can <cengiz.can@canonical.com>

> 
> 
> -- 
> kernel-team mailing list
> kernel-team@lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/kernel-team
Tim Gardner Jan. 23, 2023, 3:27 p.m. UTC | #2
On 1/23/23 7:02 AM, Tim Gardner wrote:
> https://bugs.launchpad.net/bugs/2003714
> 
> SRU Justification
> 
> [Impact]
> 
> Microsoft TDX enabled hyper visors cause a segfault due to an upstream glibc bug. This can
> be worked around with a kernel patch.
> 
> Issue Description:
> 
> When I start an Intel TDX Ubuntu 22.04 (or RHEL 9.0) guest on Hyper-V, the guest
> always hits segfaults and can’t boot up. Here the kernel running in the guest is
> the upstream kernel + my TDX patchset, or the 5.19.0-azure kernel + the same TDX patchset:
> 
> [Fix]
> 
> We confirmed the segfault also happens to TDX guests on the KVM hypervisor. After I
> checked with more Intel folks, it turns out this is indeed a glibc bug
> (https://sourceware.org/bugzilla/show_bug.cgi?id=28784), which has been fixed in the
> upsteram glibc, but Ubuntu 22.04 and newer haven’t picked up the glibc fix yet.
> 
> I got a kernel side temporary workarouond from Intel:
> https://github.com/dcui/tdx/commit/16218cf73491e867fd39c16c9e4b8aa926cbda68, which
> is on the same existing branch “decui/upstream-kinetic-22.10/master-next/1209”.
> 
> [Test Plan]
> 
> Microsoft tested
> 
> [Where things could go wrong]
> 
> TDX is a new feature. Regressions are unlikely.
> 
> 
Applied to kinetic/linux-azure:master-next. Thanks.

-rtg