SINGLEBUFFER

Hal Murray hmurray at megapathdsl.net
Thu Sep 20 23:53:11 UTC 2018


It's simple, at least conceptually.  I'm embarrassed I didn't see it (much) 
sooner.

The general idea with the old code is:

>From several places deep in ntp_io
  read data into rb
  rb->receiver = xxx
  add_full_recv_buffer(rb)

then way up in ntpd:
  rb = get_full_recv_buffer()
  (rb->receiver)(rb)
  freerecvbuf(rb)

So all we have to do is remove the second chunk and replace the first chunk 
with:
  read data into rb
  xxx(rb)
  freerecvbuf(rb)

The first chunk actually happens in several places, one for packets, another 
for refclocks, ...

I've got it working.  I'll push in a day or so.  There is lots of checking and 
cleanup to do.


-- 
These are my opinions.  I hate spam.





More information about the devel mailing list