[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v1 2/2] xen: move arm/include/asm/vm_event.h to stubs
- To: Oleksii Kurochko <oleksii.kurochko@xxxxxxxxx>
- From: Jan Beulich <jbeulich@xxxxxxxx>
- Date: Mon, 28 Aug 2023 18:05:58 +0200
- 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=Mp7cpYfUI4DZyBtHSEZ552Qp3NijN18wJVOrzzeXxWg=; b=Rr66U8yi63DaniV565sqgy7kUIXxcOErJLwKUAIrOW8/0UABfQAhepjqg9wzJwpPuntfRtqIyxjdPvemPmzP2qKKpItxDI4Qa6pk8R2L9y7BqS3fZazeO8tZsHb3snSs7oAHURvwVu8j8IfUkWrt08DXvI7zlA/bYeGFz1QnJFMfy74QUTM3dXfyBogUlqrbzS8NBMmdTF/ty6ZbCheWK/p519Z7eh0NKvW1r6ekUCKL7IK8QOLJRut1lJlyrygADDqwaxBOpwhLJh0LcoVHYwix8Y+H08QnqSpuU0FUZqAU1jNNvaZcus5iCVQpsGweeXX8dvGeFJq1KrnXA880sQ==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=BDufDPXLavuy3PaO5OC2mEHDUvYR+SMN+YnOQLQTy3JajYxwqpXM95w/dBMZaWSTUxpZqa79Ukz+IJLo+zGAqe8wMPbl4mj9bGAMZWAAymq+Z2IqrmpXj0BQSmd4XO8ocAxyStT7MW3Bn7uQr5vZ6TH/RBOWImpkRLGufEz/1Edt6sD1ScIgbFpupbU+0ZaPqs++wJmw/xNPnuNadX+GTGpOf+ipaNrjxOWrfTXwd5ToFSzj94B1VfuTgTMv6OTRkSvMilG+gUf5vM/YJvKRVFux5c6wZ7NzhSlsAUs1xb7F9TYP6PW3ginwMVvsSnQ2LAb+I/jM6b4vzjNvFGhaaw==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
- Cc: Tamas K Lengyel <tamas.k.lengyel@xxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Bertrand Marquis <bertrand.marquis@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
- Delivery-date: Mon, 28 Aug 2023 16:06:37 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 28.08.2023 17:57, Oleksii Kurochko wrote:
> asm/vm_event.h is common for ARM and RISC-V so it will be moved to
> stubs dir.
>
> Original asm/vm_event.h from ARM was updated:
> * use SPDX-License-Identifier.
> * update comment messages of stubs.
> * update #ifdef
When generalizing such a header, more tidying wants doing imo:
> --- /dev/null
> +++ b/xen/include/stubs/asm/vm_event.h
> @@ -0,0 +1,55 @@
> +/* SPDX-License-Identifier: GPL-2.0 */
> +/*
> + * vm_event.h: stubs for architecture specific vm_event handling routines
> + *
> + * Copyright (c) 2015 Tamas K Lengyel (tamas@xxxxxxxxxxxxx)
> + */
> +
> +#ifndef __ASM_STUB_VM_EVENT_H__
> +#define __ASM_STUB_VM_EVENT_H__
> +
> +#include <xen/sched.h>
> +#include <public/domctl.h>
I can't spot why this is being included here. All that's needed ought to
be public/vm_event.h, and even that only if we were to continue to use
vm_event_response_t in the function definitions (which isn't really
necessary).
> +static inline int vm_event_init_domain(struct domain *d)
> +{
> + /* Nothing to do. */
> + return 0;
> +}
> +
> +static inline void vm_event_cleanup_domain(struct domain *d)
> +{
> + memset(&d->monitor, 0, sizeof(d->monitor));
This looks to be the sole reason that xen/sched.h is needed. I question
the existence of that field in the first place when this stub is being
used. But I guess cleaning that up as well might be going too far.
Jan
|