From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out-189.mta1.migadu.com (out-189.mta1.migadu.com [95.215.58.189]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 223153064A0 for ; Mon, 9 Feb 2026 19:53:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.215.58.189 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770666791; cv=none; b=WMLj6M7KosOjs5GDRD54jkSv8qchls8FgAxB6+rMtT3wAMhPcUmyzMZU/wvCuhKfykzoK5FxcIeFsOnMnikAJU9UZiqXqu3jJBeN7UwhtJX81pdlSyA+Ef3HH9O4lHyj4JLPXPFe2jWZizesAZwymozX8F1HrVA6tMbpozyRMpA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770666791; c=relaxed/simple; bh=yQ0R5fxwrSYy6VNEOLO3WcTueLmh3QneitZBZOBSFO4=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=K5Lu1goZijL1x3tbI4W3m5Y3KzDO7i0FZLsjfj0IZgDyA13A+H4tcDfi1rWbGa3+3Wi2z1ZGs7+DNjQq/aH5PTGWErt7g8Su61EprxXvpCQebMKSRN8yfre7iigiCPRNGby5qxs1Lh+oOSnxGtkJOrpyoBr2fOWeSn5lscnn0Kg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=pRuUEjPq; arc=none smtp.client-ip=95.215.58.189 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="pRuUEjPq" X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1770666777; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=AjQeKuZtmqXTFuRHD9gtw3oJWd2azY9KRMLyRkeBjK4=; b=pRuUEjPqYjwmBDHSanKaHlOaihlr7PyxgjeTLpzL8h4sDdqsMOj3jkdyaO2IePhIsgLYaE 9nfb2s/N87wj1ym+GMY9IMHn5vonmdu5CcQd8RstYyGNHUYdrn/RQcnU/oofayNaU5dfJt hF8hFABI9j3VP37sL3AIDPsXw/6RA6M= From: Yosry Ahmed To: Sean Christopherson Cc: Paolo Bonzini , kvm@vger.kernel.org, linux-kernel@vger.kernel.org, Yosry Ahmed Subject: [PATCH v2 0/2] KVM: nSVM: Handle L2 clearing EFER.SVME properly Date: Mon, 9 Feb 2026 19:51:40 +0000 Message-ID: <20260209195142.2554532-1-yosry.ahmed@linux.dev> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT Add more graceful handling of L2 clearing EFER.SVME without L1 interception, which is architecturally undefined. Shutdown L1 instead of running it with corrupted L2 state, and add a test to verify the new behavior. I did not CC stable on patch 1 because it's not technically a KVM bug, but it would be nice to have it backported. Leaving the decision to Sean. Yosry Ahmed (2): KVM: SVM: Triple fault L1 on unintercepted EFER.SVME clear by L2 KVM: selftests: Add a test for L2 clearing EFER.SVME without intercept arch/x86/kvm/svm/svm.c | 11 ++++ tools/testing/selftests/kvm/Makefile.kvm | 1 + .../kvm/x86/svm_nested_clear_efer_svme.c | 55 +++++++++++++++++++ 3 files changed, 67 insertions(+) create mode 100644 tools/testing/selftests/kvm/x86/svm_nested_clear_efer_svme.c base-commit: e944fe2c09f405a2e2d147145c9b470084bc4c9a -- 2.53.0.rc2.204.g2597b5adb4-goog