Re: [spice-server v2 3/5] Don't modify watch when network queue is full

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

 



> 
> On Fri, Apr 28, 2017 at 07:46:53AM -0400, Frediano Ziglio wrote:
> > > 
> > > Since 5c460d, we need to watch for WATCH_EVENT_WRITE as long as there are
> > > items queued waiting to be sent, this should not be done only when the
> > > network queue is full.
> > > 
> > > red_channel_client_set_blocked()/red_channel_client_msg_sent() are
> > > still adding/removing WATCH_EVENT_WRITE when the channel becomes
> > > blocked/unblocked. This should not be causing issues as if there is
> > > already pending data, we will send it without needing WATCH_EVENT_WRITE,
> > > and if it starts blocking, the write watch will be reenabled.
> > > 
> > 
> > I don't know why but I feel the above sentence is really confusing.
> > red_channel_client_set_blocked add the WRITE, in this case can be removed
> > as WRITE is already set.
> > red_channel_client_msg_sent removes the WRITE but this is also done
> > later after sending data so is redundant.
> 
> Ah, I can change it, tried to summarize what I understood without
> spending too much time on this ;)
> 
> Is this better?
> 
> « Don't modify watch when network queue is full
> 
> Since 5c460d, we need to watch for WATCH_EVENT_WRITE as long as there
> are
> items queued waiting to be sent, this does not need to be done only when
> the network queue is full.
> 
> When red_channel_client_set_blocked() is called, as a message is being
> sent, WATCH_EVENT_WRITE will already be set, so it does not need to set
> it again.
> red_channel_client_msg_sent() removes WATCH_EVENT_WRITE, but this will
> be done later anyway by red_channel_client_push() if needed.
> 
> Since it's redundant, so we can remove this. »
> 
> Christophe
> 

In the last sentence are not since or so redundant? I think

    It's redundant so we can remove this.

or

    Since it's redundant we can remove this.

are enough.

Apart this:

Acked

Frediano
_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/spice-devel




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]