From: Willy Tarreau Date: Fri, 20 Dec 2013 15:03:41 +0000 (+0100) Subject: BUG: Revert "OPTIM/MEDIUM: epoll: fuse active events into polled ones during polling... X-Git-Tag: v1.5-dev22~92 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3ef5af3dccd9efdaf3bcf1e20a0174a44a05eef7;p=thirdparty%2Fhaproxy.git BUG: Revert "OPTIM/MEDIUM: epoll: fuse active events into polled ones during polling changes" This reverts commit 2f877304ef180654d165bf4ba8c88c204fc09d36. This commit is OK for clear text traffic but causes trouble with SSL when buffers are smaller than SSL buffers. Since the issue it addresses will be gone once the polling redesign is complete, there's no reason for trying to workaround temporary inefficiencies. Better remove it. --- diff --git a/src/ev_epoll.c b/src/ev_epoll.c index d53e0a9017..18abb107c7 100644 --- a/src/ev_epoll.c +++ b/src/ev_epoll.c @@ -64,14 +64,7 @@ REGPRM2 static void _do_poll(struct poller *p, int exp) if (fdtab[fd].owner && (eo ^ en)) { if ((eo ^ en) & FD_EV_POLLED_RW) { - /* poll status changed. We'll have to run some syscalls - * for this, so let's merge any pending speculative events - * into them in order to avoid possible future failed calls - * (typically recv()). In practice on a slow connection - * establishment, this saves one epoll_ctl() and one recv(). - */ - en = (en & FD_EV_POLLED_RW) | ((en & FD_EV_ACTIVE_RW) * FD_EV_POLLED / FD_EV_ACTIVE); - + /* poll status changed */ if ((en & FD_EV_POLLED_RW) == 0) { /* fd removed from poll list */ opcode = EPOLL_CTL_DEL;