Re: [Lguest] [PATCH 4/5] lguest: use KVM hypercalls

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx> writes:

> On Wed, Apr 15, 2009 at 06:23:29AM -0700, Eric W. Biederman wrote:
>> 
>> There is a GIGANTIC reason to have the wait queue on tfile.
>> 
>> If you open a file, and do ip link del tapN you can still
>> be blocked waiting in poll.
>> 
>> The problem is specifically free_poll_entry, where we call
>> remove_wait_queue and fput without calling any file methods.
>> So all of this happens without struct tun_file's count being
>> elevated.  Which means tun_net_uninit can detach before we get
>> off of the stupid poll wait queue.
>
> What about taking a netdev refcount before calling poll_wait?

Because as far as I can tell we would just leak that refcount.

The poll code does not appear to call back into any of the file
methods when it frees itself from the wait queue.

Eric
_______________________________________________
Virtualization mailing list
Virtualization@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linux-foundation.org/mailman/listinfo/virtualization

[Index of Archives]     [KVM Development]     [Libvirt Development]     [Libvirt Users]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux