[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [tor-bugs] #23711 [Core Tor/Tor]: sched: KIST writes to kernel and get a "wants to write" notification right after
#23711: sched: KIST writes to kernel and get a "wants to write" notification right
after
--------------------------+------------------------------------
Reporter: dgoulet | Owner: (none)
Type: defect | Status: new
Priority: Medium | Milestone: Tor: 0.3.2.x-final
Component: Core Tor/Tor | Version:
Severity: Normal | Resolution:
Keywords: tor-sched | Actual Points:
Parent ID: | Points:
Reviewer: | Sponsor:
--------------------------+------------------------------------
Comment (by dgoulet):
After some analysis, the Vanilla scheduler needs this call for the case
where the connection outbuf was full and the circuit queue still has cells
in it.
This way, once the outbuf is flushed onto the network, if we ever are
under the low watermark (16k), the channel is rescheduled so to try to
flush the cells into the outbuf which has room at that point.
This is a big house of cards because the channel *has* to be in
`SCHED_CHAN_WAITING_TO_WRITE` if we ever want to drain the circuit queue
because the `scheduler_channel_has_waiting_cells()` will never do anything
unless the channel is in state `SCHED_CHAN_WAITING_FOR_CELLS`.
For KIST, this "wants to write" is useless outside of the scheduler
because KIST actually schedules things and always put back a channel in
state "waiting to write" in the channels pending list to be re-assess at
the next tick and writes to kernel what it just flushed.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/23711#comment:1>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs