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

Re: [libvirt] [libvirt PATCHv6 1/1] add DHCP snooping



David Stevens/Beaverton/IBM wrote on 03/22/2012 07:26:06 PM:

> From: David Stevens/Beaverton/IBM

> To: Eric Blake <eblake redhat com>
> Cc: libvir-list redhat com, Stefan Berger/Watson/IBM IBMUS
> Date: 03/22/2012 07:26 PM
> Subject: Re: [libvirt] [libvirt PATCHv6 1/1] add DHCP snooping
>
> Eric Blake <eblake redhat com> wrote on 03/22/2012 03:54:31 PM:
>
> >
> > pthread_cancel() tends to imply that you are properly managing signal
> > blocking across threads; we haven't used it anywhere else in libvirt,
> > and I'm extremely wary of pulling it in now, as there's probably a lot
> > of subtle bugs that it would expose.  Are you sure you can't do this in
> > some other manner without dragging in pthread_cancel()?

> Well, I was trying to avoid it in the earlier versions, but we ran
> into races where a new snooper thread could start up on the same interface
> before the old one woke up and noticed it was supposed to die; the old
> thread would then interfere with the new thread in unpleasant ways.

Right. I had created several patches on top of your previous code. From what I remember pretty much all scenarios were working: SIGHUP, multiple IP addresses, suspend/resume... Some of the code that became necessary due to the interaction of the threads really wasn't 'nice' (tricky)...

   Stefan

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