[AMD Official Use Only - AMD Internal Distribution Only] > -----Original Message----- > From: Paolo Bonzini <pbonz...@redhat.com> > Sent: Monday, August 5, 2024 8:36 AM > To: Arvid Picciani <arvid@kraud.cloud> > Cc: Roth, Michael <michael.r...@amd.com>; qemu-discuss@nongnu.org > Subject: Re: SNP: qemu upstream vs AMD fork on kernel 6.11 > > On Mon, Aug 5, 2024 at 3:26 PM Arvid Picciani <arvid@kraud.cloud> wrote: > > > > Hi, > > > > with linux 6.11 it looks like kvm SNP host api is finally there. > > > > However, current qemu upstream appears to be tested against a much > > older kernel by redhat (according to the libvirt IRC its via coconut > > svsm), > > It's tested against both 6.11 (actually a slightly older branch in > kvm.git) and the CentOS Stream 9 kernel. The CentOS Stream 9 kernel > has the same SNP code as Linux 6.11. > > > while the current head of the amd fork on github works just > > fine with 6.11. > > The current head of the AMD fork (https://github.com/AMDESE/qemu > snp-latest) is not in line with the upstream kernel, for example: > > 66e7fbadfc8 i386/sev: Add KVM_EXIT_VMGEXIT handling for Page State Changes > e9898385037 i386/sev: Add KVM_EXIT_VMGEXIT handling for Page State > Changes (MSR-based)
It actually adds the KVM_HC_MAP_GPA_RANGE handling on top, and then drops all KVM_EXIT_VMGEXIT handling completely as part of: commit 62434c7dd57fcf2e02f6765b9d0d2588b5e032d3 Author: Michael Roth <michael.r...@amd.com> Date: Wed May 1 01:14:39 2024 -0500 *i386/sev: Rework GHCB extended guest request handling TODO: drop the PSC patches completely so this rework can become a clean standalone patch. The v4 patches that actually went into QEMU 9.1 have this changeset appropriately split/squashed into their proper place, but I think the upstream behavior should be about the same as what is in snp-latest QEMU tree currently. If snp-latest works, but upstream QEMU does not, then there is potentially a regression upstream. However I just re-tested latest QEMU commit (f9851d2ffef5) against upstream KVM and didn't see any issue. QEMU 9.1 is already is hard-freeze, so if there is a confirmed breakage please share the full details and steps to reproduce so it can hopefully be sorted before the 9.1 release. -Mike > > What problems are you seeing with Linux 6.11? > > Paolo > > > there's also this old patch missing to enable virtiofsd > > https://lists.gnu.org/archive/html/qemu-devel/2022-01/msg03456.html > > > > i would rebase that and send it again, but current main is broken on > > 6.11, so wondering where qemu is heading. > > > > thanks > > > > > > > > -- > > https://kraudcloud.com/ > > devguard GmbH, Berlin, Geschäftsführer: Arvid E Picciani > > Handelsregister: Amtsgericht Charlottenburg (Berlin) HRB 195184 B > >