On "nio-improve" page, you've got:
for (;;) {
evp.ep_timeout = STD_SCHED_TIMEOUT;
evp.ep_resoff = 0;
nfds = ioctl(kdpfd, EP_POLL, &evp);
pfds = (struct pollfd *) (map + evp.ep_resoff);
for (ii = 0; ii < nfds; ii++, pfds++) {
...
}
}
Assume your server is so overloaded that you need
to avoid any unproductive calls to read() or write()
or accept(). Assume that instead of many very fast
connections coming in at a furious rate, you get a
large steady current of very slow connections.
If you try to flesh out the above template with those
goals in mind, I think you'll quickly see what I've
been trying to get at with regard to the awkwardness
of not getting back some indication of the initial
state of the fd.
The current situation isn't fatal, just awkward. And
fixable. For the low low price of a tiny bit of
idealogical purity...
-- Christopher St. John cks@distributopia.com DistribuTopia http://www.distributopia.com - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/