Thor Simon
2009-08-25 15:32:36 UTC
The attached patch adds an argument to socket upcall handlers, so
they can tell whether they've been called because the socket is
ready for input or output. This significantly eases the way for
in-kernel code that needs to interact with socket flow control,
such as splice() or things of its ilk. I think it might also make
it possible to improve the wakeup mechanism in the NFS code, which
seems to care whether the socket's come ready for read or write
when adjusting various timers and handling errors.
Hastily ported forward from netbsd-5 to -current -- compiles, and
appears to work (works fine in our netbsd-5 tree).
Comments?
they can tell whether they've been called because the socket is
ready for input or output. This significantly eases the way for
in-kernel code that needs to interact with socket flow control,
such as splice() or things of its ilk. I think it might also make
it possible to improve the wakeup mechanism in the NFS code, which
seems to care whether the socket's come ready for read or write
when adjusting various timers and handling errors.
Hastily ported forward from netbsd-5 to -current -- compiles, and
appears to work (works fine in our netbsd-5 tree).
Comments?
--
Thor Lancelot Simon
Coyote Point Systems, Inc. <***@coyotepoint.com>
Millerton, NY, USA
Thor Lancelot Simon
Coyote Point Systems, Inc. <***@coyotepoint.com>
Millerton, NY, USA