[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v3 01/10] xen: introduce XEN_DOMCTL_CDF_INTERNAL_directmap
- To: Penny Zheng <penny.zheng@xxxxxxx>
- From: Jan Beulich <jbeulich@xxxxxxxx>
- Date: Tue, 16 Nov 2021 08:54:45 +0100
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=plJNxoA/+o8gch4VcesZ86LbSaLbOkEwz3bpd399iM8=; b=LQMj4KSAMLamsUR00i21WJuSyQCyQXdNzqS/DTwzP1pfDrB3rvQnf4gdOuCDB2oDiG9VMbURSwl+2DGwHYlGLEnoul67eyhs+wPbanIUFlq2DGqBnt3mfaBgQ5gz+s2wfrPAftHaOP+2Ho9cp3dBYxLN9nbR3RWhF41Guh5imYZsmN4hr58FAnjkiAAOP/9gAVb/txDvX3Avd1ttIkgWKo+uK6Q3toiUtQgo19gxUsuxhWfMslRHGpHD53h/nplVcckNexcHAZHMd8ZrHhA/hVfiLCCdee3HFRGNbwK/hZkPAn8z+yuHEsH6/U/4DIZtgb/GWNp6xHuPlbuxTDXhgg==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=c74VqnYO2Qo1IKQv2vVV0RZv3xacAM02pVOF8YtCTQ4aepdoz65KP4tiiIM0ykXjucaZdANuJm57zmNZgfwxGMLtaiHfuKIb3bwtdD4AsrFLfTJYGjV10QkBQBrcAwuEpr3Uo0x0XKNSo8GxyK8LJZ53ypGzV11I/VLFPQqpDTDkr9RV97Q7y9q7uW296gJZkCfi+OVE5hhib/ZgJRMfBKPWdRouqjpkr/gpy2Ia3O/N2J2s0kGwF0EkpN01MiTOZgXZ9oMfAKYigmAt0VJm2p2Qjk0FHeZTsIBiuylWcx/n9Hsbgsx3BT/TD/GkrD7l1bjdsuDr0johitAOxX2tIw==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
- Cc: Bertrand.Marquis@xxxxxxx, Wei.Chen@xxxxxxx, xen-devel@xxxxxxxxxxxxxxxxxxxx, sstabellini@xxxxxxxxxx, julien@xxxxxxx
- Delivery-date: Tue, 16 Nov 2021 07:55:00 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 16.11.2021 07:31, Penny Zheng wrote:
> --- a/xen/arch/x86/domain.c
> +++ b/xen/arch/x86/domain.c
> @@ -692,6 +692,12 @@ int arch_sanitise_domain_config(struct
> xen_domctl_createdomain *config)
> return -EINVAL;
> }
>
> + if ( config->flags & XEN_DOMCTL_CDF_INTERNAL_directmap )
> + {
> + dprintk(XENLOG_INFO, "direct-map cannot be enabled yet\n");
> + return -EINVAL;
> + }
If this flag is to be retained in its present shape, then besides
rejecting it here (or perhaps instead of, with the check here simply
becoming ASSERT()) you want to reject it in the handling of
XEN_DOMCTL_createdomain, before calling domain_create(). Only then
would the flag become truly internal.
Jan
|