From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id EB3B6C433EF for ; Tue, 7 Dec 2021 13:17:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236950AbhLGNVI (ORCPT ); Tue, 7 Dec 2021 08:21:08 -0500 Received: from mail.skyhub.de ([5.9.137.197]:42086 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236913AbhLGNVH (ORCPT ); Tue, 7 Dec 2021 08:21:07 -0500 Received: from zn.tnic (dslb-088-067-202-008.088.067.pools.vodafone-ip.de [88.67.202.8]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id A07471EC047E; Tue, 7 Dec 2021 14:17:31 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1638883051; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=95VQLKSNF4QWMQ09hda7pdps2WmbfOKf1gNMtpDPlS4=; b=np3NMTz+/Qi3FJluqNhrqUTFzwJNqFZhFGubvx83OlmR0HPXR0Flz8vwvOWEGECZi1RCbI rqQfcKSJgEqGW2+1cjJIji8I55z+pO+EH9eKLBk/wGjX20DmBewYR1JLPBCFZaPLCABxTv W9r7V93QzzXgzXyRpJhnM5q6quWyczY= Date: Tue, 7 Dec 2021 14:17:33 +0100 From: Borislav Petkov To: Tianyu Lan Cc: Brijesh Singh , x86@kernel.org, linux-kernel@vger.kernel.org, kvm@vger.kernel.org, linux-efi@vger.kernel.org, platform-driver-x86@vger.kernel.org, linux-coco@lists.linux.dev, linux-mm@kvack.org, Michael Kelley , "Andrea Parri (Microsoft)" , Thomas Gleixner , Ingo Molnar , Joerg Roedel , Tom Lendacky , "H. Peter Anvin" , Ard Biesheuvel , Paolo Bonzini , Sean Christopherson , Vitaly Kuznetsov , Jim Mattson , Andy Lutomirski , Dave Hansen , Sergio Lopez , Peter Gonda , Peter Zijlstra , Srinivas Pandruvada , David Rientjes , Dov Murik , Tobin Feldman-Fitzthum , Michael Roth , Vlastimil Babka , "Kirill A . Shutemov" , Andi Kleen , "Dr . David Alan Gilbert" , tony.luck@intel.com, marcorr@google.com, sathyanarayanan.kuppuswamy@linux.intel.com Subject: Re: [PATCH v7 09/45] x86/sev: Save the negotiated GHCB version Message-ID: References: <20211110220731.2396491-1-brijesh.singh@amd.com> <20211110220731.2396491-10-brijesh.singh@amd.com> <5b1c348a-fc26-e257-7bc2-82d1326de321@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <5b1c348a-fc26-e257-7bc2-82d1326de321@gmail.com> Precedence: bulk List-ID: X-Mailing-List: platform-driver-x86@vger.kernel.org On Tue, Dec 07, 2021 at 08:51:53PM +0800, Tianyu Lan wrote: > Hi Brijesh: Do me a favor please and learn not to top-post on a public mailing list. Also, take the time to read Documentation/process/ before you send upstream patches and how to work with the community in general. > We find this patch breaks AMD SEV support in the Hyper-V Isolation > VM. Hyper-V code also uses sev_es_ghcb_hv_call() to read or write msr > value. The sev_es_check_cpu_features() isn't called in the Hyper-V > code and so the ghcb_version is always 0. If hyperv is going to expose hypervisor features, then it better report GHCB v2. If not, then I guess < 2 or 1 or so, depending on how this is defined. > Could you add a new parameter ghcb_version for sev_es_ghcb_hv_call() > and then caller may input ghcb_version? No, your hypervisor needs to adhere to the spec and report proper ghcb version. We won't be doing any accomodate-hyperv hacks. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette