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]
Date:   Thu, 20 Jun 2019 00:02:26 +0800
From:   李菲 <lifei.shirley@...edance.com>
To:     David Miller <davem@...emloft.net>
Cc:     Jason Wang <jasowang@...hat.com>, netdev@...r.kernel.org,
        linux-kernel@...r.kernel.org, zhengfeiran@...edance.com,
        duanxiongchun@...edance.com
Subject: Re: [External Email] Re: [PATCH net v2] tun: wake up waitqueues after
 IFF_UP is set

Thanks.

Have a nice day
Fei

On Wed, Jun 19, 2019 at 1:55 AM David Miller <davem@...emloft.net> wrote:
>
> From: Fei Li <lifei.shirley@...edance.com>
> Date: Mon, 17 Jun 2019 21:26:36 +0800
>
> > Currently after setting tap0 link up, the tun code wakes tx/rx waited
> > queues up in tun_net_open() when .ndo_open() is called, however the
> > IFF_UP flag has not been set yet. If there's already a wait queue, it
> > would fail to transmit when checking the IFF_UP flag in tun_sendmsg().
> > Then the saving vhost_poll_start() will add the wq into wqh until it
> > is waken up again. Although this works when IFF_UP flag has been set
> > when tun_chr_poll detects; this is not true if IFF_UP flag has not
> > been set at that time. Sadly the latter case is a fatal error, as
> > the wq will never be waken up in future unless later manually
> > setting link up on purpose.
> >
> > Fix this by moving the wakeup process into the NETDEV_UP event
> > notifying process, this makes sure IFF_UP has been set before all
> > waited queues been waken up.
> >
> > Signed-off-by: Fei Li <lifei.shirley@...edance.com>
> > Acked-by: Jason Wang <jasowang@...hat.com>
>
> Applied and queued up for -stable, thanks.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ