lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <659fc57f-0c02-4bf2-9938-976200262145@redhat.com>
Date: Tue, 19 Mar 2024 09:54:24 +0100
From: David Hildenbrand <david@...hat.com>
To: David Stevens <stevensd@...omium.org>,
 "Michael S . Tsirkin" <mst@...hat.com>
Cc: virtualization@...ts.linux-foundation.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] virtio_balloon: Treat stats requests as wakeup events

On 18.03.24 10:10, David Stevens wrote:
> From: David Stevens <stevensd@...omium.org>
> 
> Treat stats requests as wakeup events to ensure that the driver responds
> to device requests in a timely manner.
> 
> Signed-off-by: David Stevens <stevensd@...omium.org>
> ---
>   drivers/virtio/virtio_balloon.c | 75 ++++++++++++++++++++-------------
>   1 file changed, 46 insertions(+), 29 deletions(-)
> 
> diff --git a/drivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_balloon.c
> index 7fe7ef5f1c77..402dec98e08c 100644
> --- a/drivers/virtio/virtio_balloon.c
> +++ b/drivers/virtio/virtio_balloon.c
> @@ -121,11 +121,14 @@ struct virtio_balloon {
>   	struct page_reporting_dev_info pr_dev_info;
>   
>   	/* State for keeping the wakeup_source active while adjusting the balloon */
> -	spinlock_t adjustment_lock;
> -	bool adjustment_signal_pending;
> -	bool adjustment_in_progress;
> +	spinlock_t wakeup_lock;
> +	bool processing_wakeup_event;
> +	u32 wakeup_signal_mask;
>   };
>   
> +#define ADJUSTMENT_WAKEUP_SIGNAL (1 << 0)
> +#define STATS_WAKEUP_SIGNAL (1 << 1)

I'd suggest a different naming like:

VIRTIO_BALLOON_WAKEUP_SIGNAL_ADJUST
VIRTIO_BALLOON_WAKEUP_SIGNAL_STATS


Apart from that, nothing jumped at me.

Acked-by: David Hildenbrand <david@...hat.com>

-- 
Cheers,

David / dhildenb


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ