Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp2433082pxu; Mon, 7 Dec 2020 06:33:56 -0800 (PST) X-Google-Smtp-Source: ABdhPJyVSQlAurhZDyslrnlB6pqawtkB5KrCZ69AAJvKakgu9SHPwvo7kZrjscb18G8igg3OcoR4 X-Received: by 2002:a17:906:fb1a:: with SMTP id lz26mr18991533ejb.194.1607351635770; Mon, 07 Dec 2020 06:33:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1607351635; cv=none; d=google.com; s=arc-20160816; b=iv9UIpiJ7cl0zzv/13IeACTogLQqgUHAahSqdv9oRwO7HOQoD4C2NWPDc5i7A9lbIs ot7i2mA+CsjAvrlvnFQVEW/NCeiLeYHiwSs7wHydijPYJacsSewcFwkHFBfLgFwC8q1C 2TReTwmxYrNt92P9ZGYtqrrK6TwFbBo6FpgOhbRF6u6xPrKZzuXtAZhc+KC5Sx1QSKcP LgLTGJ9um/IdT9b/KBygYMVu136y8mhhKZlbbL/6qBSI5o3ORfj7bfpfIx6jr+VBYUgs 7MrnYCj8Y+QicQKkYL/JK9TkkcBz425Gl01wxMvHM/M51U3hJR3gJB6Z+W47Leg1yOB0 g/pQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-language:content-transfer-encoding :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=oOiExwMNQHtfcgYSxIUj6xzsg445mQfA3dlJmKEAPrw=; b=ryiB7hFVKNrK/jctQuk9EebOZmaojdGFoW0+zT23PoFlLYuqzZcl9j94EC9ZL8TmWw RTxa9c7O58lvYq/8iQlzNZueBPmHwexbWkhVKWCJNA7faiDaczEt7wM1ZbkdfEGVVlwS lS0LepnYEcmMiSEmzSgSiKETUPZ9LspT5DjJvOdU3fhYK32DU+6DayoMQxelOTaJQNRR ekur7l5li4GfDbKJOXcvhIvVW8gmQN1K/OGzlCDTKLsnzsE1au/0MHjNlD18lnj8W+Kd 6e1Y75IAKsAq85C8BtJbanfpkBpxlDvfjLZ7snF5lP9tftuw/VxxUwYPl9Wp+sSfzof4 D14Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@yandex.ru header.s=mail header.b=AUvGLVlm; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=yandex.ru Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h8si7373256ejj.587.2020.12.07.06.33.32; Mon, 07 Dec 2020 06:33:55 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@yandex.ru header.s=mail header.b=AUvGLVlm; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=yandex.ru Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727383AbgLGO3q (ORCPT + 99 others); Mon, 7 Dec 2020 09:29:46 -0500 Received: from forward100o.mail.yandex.net ([37.140.190.180]:32907 "EHLO forward100o.mail.yandex.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726007AbgLGO3q (ORCPT ); Mon, 7 Dec 2020 09:29:46 -0500 Received: from mxback14g.mail.yandex.net (mxback14g.mail.yandex.net [IPv6:2a02:6b8:c03:773:0:640:d1d3:51e5]) by forward100o.mail.yandex.net (Yandex) with ESMTP id B76EC4AC05BA; Mon, 7 Dec 2020 17:29:03 +0300 (MSK) Received: from sas8-b61c542d7279.qloud-c.yandex.net (sas8-b61c542d7279.qloud-c.yandex.net [2a02:6b8:c1b:2912:0:640:b61c:542d]) by mxback14g.mail.yandex.net (mxback/Yandex) with ESMTP id tTnFluAx8C-T3sCFrax; Mon, 07 Dec 2020 17:29:03 +0300 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1607351343; bh=oOiExwMNQHtfcgYSxIUj6xzsg445mQfA3dlJmKEAPrw=; h=In-Reply-To:From:Date:References:To:Subject:Message-ID:Cc; b=AUvGLVlmuQPBN+yuVOMrO5njrrY1kAqmHObZenOTg9HuPtHR5UeA0Xi2eRNBHsmX9 lKaAGZNHIIhIksLa+XkxNwThjbu1N7lrfrWJJ/yHl0XrEzxLSjMTTNCYvvuj7bPqLR PxWWAHFQ6HPyZMGWKAH78d6ifgsYxS9wjUA/Jc5I= Authentication-Results: mxback14g.mail.yandex.net; dkim=pass header.i=@yandex.ru Received: by sas8-b61c542d7279.qloud-c.yandex.net (smtp/Yandex) with ESMTPSA id ZIoNUqAXzC-T2nenAaI; Mon, 07 Dec 2020 17:29:02 +0300 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (Client certificate not present) Subject: Re: KVM_SET_CPUID doesn't check supported bits (was Re: [PATCH 0/6] KVM: x86: KVM_SET_SREGS.CR4 bug fixes and cleanup) To: Paolo Bonzini Cc: Sean Christopherson , Vitaly Kuznetsov , Wanpeng Li , Jim Mattson , Joerg Roedel , kvm@vger.kernel.org, linux-kernel@vger.kernel.org References: <20201007014417.29276-1-sean.j.christopherson@intel.com> <99334de1-ba3d-dfac-0730-e637d39b948f@yandex.ru> <20201008175951.GA9267@linux.intel.com> <7efe1398-24c0-139f-29fa-3d89b6013f34@yandex.ru> <20201009040453.GA10744@linux.intel.com> <5dfa55f3-ecdf-9f8d-2d45-d2e6e54f2daa@yandex.ru> <20201009153053.GA16234@linux.intel.com> <9201e8ac-68d2-2bb3-1ef3-efd698391955@yandex.ru> From: stsp Message-ID: Date: Mon, 7 Dec 2020 17:29:02 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 07.12.2020 17:09, Paolo Bonzini пишет: > > > Il lun 7 dic 2020, 15:04 stsp > ha scritto: > > Perhaps it would be good if guest cpuid to > have a default values of KVM_GET_SUPPORTED_CPUID, > so that the user doesn't have to do the needless > calls to just copy host features to guest cpuid. > > > It is too late to change that aspect of the API, unfortunately. We > don't know how various userspaces would behave. Which means some sensible behaviour already exists if I don't call KVM_SET_CPUID2. So what is it, #UD on CPUID? Would be good to have that documented.