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] [thread-next>] [day] [month] [year] [list]
Message-ID: <3943477e-7768-ceb3-38a3-3a20cb0e3082@oracle.com>
Date:   Thu, 1 Feb 2018 15:08:22 -0500
From:   Boris Ostrovsky <boris.ostrovsky@...cle.com>
To:     Oleksandr Andrushchenko <andr2000@...il.com>,
        xen-devel@...ts.xenproject.org, linux-kernel@...r.kernel.org
Cc:     jgross@...e.com, david.vrabel@...rix.com, otubo@...hat.com,
        Oleksandr Andrushchenko <oleksandr_andrushchenko@...m.com>
Subject: Re: [PATCH] xen: fix frontend driver disconnected from xenbus on
 removal

On 02/01/2018 03:57 AM, Oleksandr Andrushchenko wrote:
> From: Oleksandr Andrushchenko <oleksandr_andrushchenko@...m.com>
>
> Current xenbus frontend driver removal flow first disconnects
> the driver from xenbus and then calls driver's remove callback.
> This makes it impossible for the driver to listen to backend's
> state changes and synchronize the removal procedure.
>
> Fix this by removing other end XenBus watches after the
> driver's remove callback is called.
>
> Signed-off-by: Oleksandr Andrushchenko <oleksandr_andrushchenko@...m.com>
> ---
>  drivers/xen/xenbus/xenbus_probe.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/xen/xenbus/xenbus_probe.c b/drivers/xen/xenbus/xenbus_probe.c
> index 74888cacd0b0..9c63cd3f416b 100644
> --- a/drivers/xen/xenbus/xenbus_probe.c
> +++ b/drivers/xen/xenbus/xenbus_probe.c
> @@ -258,11 +258,11 @@ int xenbus_dev_remove(struct device *_dev)
>  
>  	DPRINTK("%s", dev->nodename);
>  
> -	free_otherend_watch(dev);
> -
>  	if (drv->remove)
>  		drv->remove(dev);


Is it possible for the watch to fire here?

-boris

>  
> +	free_otherend_watch(dev);
> +
>  	free_otherend_details(dev);
>  
>  	xenbus_switch_state(dev, XenbusStateClosed);

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ