Path: blob/main/contrib/libevent/epolltable-internal.h
39475 views
/*1* Copyright (c) 2000-2007 Niels Provos <[email protected]>2* Copyright (c) 2007-2012 Niels Provos and Nick Mathewson3*4* Redistribution and use in source and binary forms, with or without5* modification, are permitted provided that the following conditions6* are met:7* 1. Redistributions of source code must retain the above copyright8* notice, this list of conditions and the following disclaimer.9* 2. Redistributions in binary form must reproduce the above copyright10* notice, this list of conditions and the following disclaimer in the11* documentation and/or other materials provided with the distribution.12* 3. The name of the author may not be used to endorse or promote products13* derived from this software without specific prior written permission.14*15* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR16* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES17* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.18* IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,19* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT20* NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,21* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY22* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT23* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF24* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.25*/26#ifndef EPOLLTABLE_INTERNAL_H_INCLUDED_27#define EPOLLTABLE_INTERNAL_H_INCLUDED_2829/*30Here are the values we're masking off to decide what operations to do.31Note that since EV_READ|EV_WRITE.3233Note also that this table is a little sparse, since ADD+DEL is34nonsensical ("xxx" in the list below.)3536Note also that we are shifting old_events by only 5 bits, since37EV_READ is 2 and EV_WRITE is 4.3839The table was auto-generated with a python script, according to this40pseudocode:[*0]4142If either the read or the write change is add+del:43This is impossible; Set op==-1, events=0.44Else, if either the read or the write change is add:45Set events to 0.46If the read change is add, or47(the read change is not del, and ev_read is in old_events):48Add EPOLLIN to events.49If the write change is add, or50(the write change is not del, and ev_write is in old_events):51Add EPOLLOUT to events.5253If old_events is set:54Set op to EPOLL_CTL_MOD [*1,*2]55Else:56Set op to EPOLL_CTL_ADD [*3]5758Else, if the read or the write change is del:59Set op to EPOLL_CTL_DEL.60If the read change is del:61If the write change is del:62Set events to EPOLLIN|EPOLLOUT63Else if ev_write is in old_events:64Set events to EPOLLOUT65Set op to EPOLL_CTL_MOD66Else67Set events to EPOLLIN68Else:69{The write change is del.}70If ev_read is in old_events:71Set events to EPOLLIN72Set op to EPOLL_CTL_MOD73Else:74Set the events to EPOLLOUT7576Else:77There is no read or write change; set op to 0 and events to 0.7879The logic is a little tricky, since we had no events set on the fd before,80we need to set op="ADD" and set events=the events we want to add. If we81had any events set on the fd before, and we want any events to remain on82the fd, we need to say op="MOD" and set events=the events we want to83remain. But if we want to delete the last event, we say op="DEL" and84set events=(any non-null pointer).8586[*0] Actually, the Python script has gotten a bit more complicated, to87support EPOLLRDHUP.8889[*1] This MOD is only a guess. MOD might fail with ENOENT if the file was90closed and a new file was opened with the same fd. If so, we'll retry91with ADD.9293[*2] We can't replace this with a no-op even if old_events is the same as94the new events: if the file was closed and reopened, we need to retry95with an ADD. (We do a MOD in this case since "no change" is more96common than "close and reopen", so we'll usually wind up doing 197syscalls instead of 2.)9899[*3] This ADD is only a guess. There is a fun Linux kernel issue where if100you have two fds for the same file (via dup) and you ADD one to an101epfd, then close it, then re-create it with the same fd (via dup2 or an102unlucky dup), then try to ADD it again, you'll get an EEXIST, since the103struct epitem is not actually removed from the struct eventpoll until104the file itself is closed.105106EV_CHANGE_ADD==1107EV_CHANGE_DEL==2108EV_READ ==2109EV_WRITE ==4110EV_CLOSED ==0x80111112Bit 0: close change is add113Bit 1: close change is del114Bit 2: read change is add115Bit 3: read change is del116Bit 4: write change is add117Bit 5: write change is del118Bit 6: old events had EV_READ119Bit 7: old events had EV_WRITE120Bit 8: old events had EV_CLOSED121*/122123#define EPOLL_OP_TABLE_INDEX(c) \124( (((c)->close_change&(EV_CHANGE_ADD|EV_CHANGE_DEL))) | \125(((c)->read_change&(EV_CHANGE_ADD|EV_CHANGE_DEL)) << 2) | \126(((c)->write_change&(EV_CHANGE_ADD|EV_CHANGE_DEL)) << 4) | \127(((c)->old_events&(EV_READ|EV_WRITE)) << 5) | \128(((c)->old_events&(EV_CLOSED)) << 1) \129)130131#if EV_READ != 2 || EV_WRITE != 4 || EV_CLOSED != 0x80 || EV_CHANGE_ADD != 1 || EV_CHANGE_DEL != 2132#error "Libevent's internals changed! Regenerate the op_table in epolltable-internal.h"133#endif134135static const struct operation {136int events;137int op;138} epoll_op_table[] = {139/* old= 0, write: 0, read: 0, close: 0 */140{ 0, 0 },141/* old= 0, write: 0, read: 0, close:add */142{ EPOLLRDHUP, EPOLL_CTL_ADD },143/* old= 0, write: 0, read: 0, close:del */144{ EPOLLRDHUP, EPOLL_CTL_DEL },145/* old= 0, write: 0, read: 0, close:xxx */146{ 0, 255 },147/* old= 0, write: 0, read:add, close: 0 */148{ EPOLLIN, EPOLL_CTL_ADD },149/* old= 0, write: 0, read:add, close:add */150{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_ADD },151/* old= 0, write: 0, read:add, close:del */152{ EPOLLIN, EPOLL_CTL_ADD },153/* old= 0, write: 0, read:add, close:xxx */154{ 0, 255 },155/* old= 0, write: 0, read:del, close: 0 */156{ EPOLLIN, EPOLL_CTL_DEL },157/* old= 0, write: 0, read:del, close:add */158{ EPOLLRDHUP, EPOLL_CTL_ADD },159/* old= 0, write: 0, read:del, close:del */160{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_DEL },161/* old= 0, write: 0, read:del, close:xxx */162{ 0, 255 },163/* old= 0, write: 0, read:xxx, close: 0 */164{ 0, 255 },165/* old= 0, write: 0, read:xxx, close:add */166{ 0, 255 },167/* old= 0, write: 0, read:xxx, close:del */168{ 0, 255 },169/* old= 0, write: 0, read:xxx, close:xxx */170{ 0, 255 },171/* old= 0, write:add, read: 0, close: 0 */172{ EPOLLOUT, EPOLL_CTL_ADD },173/* old= 0, write:add, read: 0, close:add */174{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_ADD },175/* old= 0, write:add, read: 0, close:del */176{ EPOLLOUT, EPOLL_CTL_ADD },177/* old= 0, write:add, read: 0, close:xxx */178{ 0, 255 },179/* old= 0, write:add, read:add, close: 0 */180{ EPOLLIN|EPOLLOUT, EPOLL_CTL_ADD },181/* old= 0, write:add, read:add, close:add */182{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_ADD },183/* old= 0, write:add, read:add, close:del */184{ EPOLLIN|EPOLLOUT, EPOLL_CTL_ADD },185/* old= 0, write:add, read:add, close:xxx */186{ 0, 255 },187/* old= 0, write:add, read:del, close: 0 */188{ EPOLLOUT, EPOLL_CTL_ADD },189/* old= 0, write:add, read:del, close:add */190{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_ADD },191/* old= 0, write:add, read:del, close:del */192{ EPOLLOUT, EPOLL_CTL_ADD },193/* old= 0, write:add, read:del, close:xxx */194{ 0, 255 },195/* old= 0, write:add, read:xxx, close: 0 */196{ 0, 255 },197/* old= 0, write:add, read:xxx, close:add */198{ 0, 255 },199/* old= 0, write:add, read:xxx, close:del */200{ 0, 255 },201/* old= 0, write:add, read:xxx, close:xxx */202{ 0, 255 },203/* old= 0, write:del, read: 0, close: 0 */204{ EPOLLOUT, EPOLL_CTL_DEL },205/* old= 0, write:del, read: 0, close:add */206{ EPOLLRDHUP, EPOLL_CTL_ADD },207/* old= 0, write:del, read: 0, close:del */208{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL },209/* old= 0, write:del, read: 0, close:xxx */210{ 0, 255 },211/* old= 0, write:del, read:add, close: 0 */212{ EPOLLIN, EPOLL_CTL_ADD },213/* old= 0, write:del, read:add, close:add */214{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_ADD },215/* old= 0, write:del, read:add, close:del */216{ EPOLLIN, EPOLL_CTL_ADD },217/* old= 0, write:del, read:add, close:xxx */218{ 0, 255 },219/* old= 0, write:del, read:del, close: 0 */220{ EPOLLIN|EPOLLOUT, EPOLL_CTL_DEL },221/* old= 0, write:del, read:del, close:add */222{ EPOLLRDHUP, EPOLL_CTL_ADD },223/* old= 0, write:del, read:del, close:del */224{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL },225/* old= 0, write:del, read:del, close:xxx */226{ 0, 255 },227/* old= 0, write:del, read:xxx, close: 0 */228{ 0, 255 },229/* old= 0, write:del, read:xxx, close:add */230{ 0, 255 },231/* old= 0, write:del, read:xxx, close:del */232{ 0, 255 },233/* old= 0, write:del, read:xxx, close:xxx */234{ 0, 255 },235/* old= 0, write:xxx, read: 0, close: 0 */236{ 0, 255 },237/* old= 0, write:xxx, read: 0, close:add */238{ 0, 255 },239/* old= 0, write:xxx, read: 0, close:del */240{ 0, 255 },241/* old= 0, write:xxx, read: 0, close:xxx */242{ 0, 255 },243/* old= 0, write:xxx, read:add, close: 0 */244{ 0, 255 },245/* old= 0, write:xxx, read:add, close:add */246{ 0, 255 },247/* old= 0, write:xxx, read:add, close:del */248{ 0, 255 },249/* old= 0, write:xxx, read:add, close:xxx */250{ 0, 255 },251/* old= 0, write:xxx, read:del, close: 0 */252{ 0, 255 },253/* old= 0, write:xxx, read:del, close:add */254{ 0, 255 },255/* old= 0, write:xxx, read:del, close:del */256{ 0, 255 },257/* old= 0, write:xxx, read:del, close:xxx */258{ 0, 255 },259/* old= 0, write:xxx, read:xxx, close: 0 */260{ 0, 255 },261/* old= 0, write:xxx, read:xxx, close:add */262{ 0, 255 },263/* old= 0, write:xxx, read:xxx, close:del */264{ 0, 255 },265/* old= 0, write:xxx, read:xxx, close:xxx */266{ 0, 255 },267/* old= r, write: 0, read: 0, close: 0 */268{ 0, 0 },269/* old= r, write: 0, read: 0, close:add */270{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },271/* old= r, write: 0, read: 0, close:del */272{ EPOLLIN, EPOLL_CTL_MOD },273/* old= r, write: 0, read: 0, close:xxx */274{ 0, 255 },275/* old= r, write: 0, read:add, close: 0 */276{ EPOLLIN, EPOLL_CTL_MOD },277/* old= r, write: 0, read:add, close:add */278{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },279/* old= r, write: 0, read:add, close:del */280{ EPOLLIN, EPOLL_CTL_MOD },281/* old= r, write: 0, read:add, close:xxx */282{ 0, 255 },283/* old= r, write: 0, read:del, close: 0 */284{ EPOLLIN, EPOLL_CTL_DEL },285/* old= r, write: 0, read:del, close:add */286{ EPOLLRDHUP, EPOLL_CTL_MOD },287/* old= r, write: 0, read:del, close:del */288{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_DEL },289/* old= r, write: 0, read:del, close:xxx */290{ 0, 255 },291/* old= r, write: 0, read:xxx, close: 0 */292{ 0, 255 },293/* old= r, write: 0, read:xxx, close:add */294{ 0, 255 },295/* old= r, write: 0, read:xxx, close:del */296{ 0, 255 },297/* old= r, write: 0, read:xxx, close:xxx */298{ 0, 255 },299/* old= r, write:add, read: 0, close: 0 */300{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },301/* old= r, write:add, read: 0, close:add */302{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },303/* old= r, write:add, read: 0, close:del */304{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },305/* old= r, write:add, read: 0, close:xxx */306{ 0, 255 },307/* old= r, write:add, read:add, close: 0 */308{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },309/* old= r, write:add, read:add, close:add */310{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },311/* old= r, write:add, read:add, close:del */312{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },313/* old= r, write:add, read:add, close:xxx */314{ 0, 255 },315/* old= r, write:add, read:del, close: 0 */316{ EPOLLOUT, EPOLL_CTL_MOD },317/* old= r, write:add, read:del, close:add */318{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },319/* old= r, write:add, read:del, close:del */320{ EPOLLOUT, EPOLL_CTL_MOD },321/* old= r, write:add, read:del, close:xxx */322{ 0, 255 },323/* old= r, write:add, read:xxx, close: 0 */324{ 0, 255 },325/* old= r, write:add, read:xxx, close:add */326{ 0, 255 },327/* old= r, write:add, read:xxx, close:del */328{ 0, 255 },329/* old= r, write:add, read:xxx, close:xxx */330{ 0, 255 },331/* old= r, write:del, read: 0, close: 0 */332{ EPOLLIN, EPOLL_CTL_MOD },333/* old= r, write:del, read: 0, close:add */334{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },335/* old= r, write:del, read: 0, close:del */336{ EPOLLIN, EPOLL_CTL_MOD },337/* old= r, write:del, read: 0, close:xxx */338{ 0, 255 },339/* old= r, write:del, read:add, close: 0 */340{ EPOLLIN, EPOLL_CTL_MOD },341/* old= r, write:del, read:add, close:add */342{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },343/* old= r, write:del, read:add, close:del */344{ EPOLLIN, EPOLL_CTL_MOD },345/* old= r, write:del, read:add, close:xxx */346{ 0, 255 },347/* old= r, write:del, read:del, close: 0 */348{ EPOLLIN|EPOLLOUT, EPOLL_CTL_DEL },349/* old= r, write:del, read:del, close:add */350{ EPOLLRDHUP, EPOLL_CTL_MOD },351/* old= r, write:del, read:del, close:del */352{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL },353/* old= r, write:del, read:del, close:xxx */354{ 0, 255 },355/* old= r, write:del, read:xxx, close: 0 */356{ 0, 255 },357/* old= r, write:del, read:xxx, close:add */358{ 0, 255 },359/* old= r, write:del, read:xxx, close:del */360{ 0, 255 },361/* old= r, write:del, read:xxx, close:xxx */362{ 0, 255 },363/* old= r, write:xxx, read: 0, close: 0 */364{ 0, 255 },365/* old= r, write:xxx, read: 0, close:add */366{ 0, 255 },367/* old= r, write:xxx, read: 0, close:del */368{ 0, 255 },369/* old= r, write:xxx, read: 0, close:xxx */370{ 0, 255 },371/* old= r, write:xxx, read:add, close: 0 */372{ 0, 255 },373/* old= r, write:xxx, read:add, close:add */374{ 0, 255 },375/* old= r, write:xxx, read:add, close:del */376{ 0, 255 },377/* old= r, write:xxx, read:add, close:xxx */378{ 0, 255 },379/* old= r, write:xxx, read:del, close: 0 */380{ 0, 255 },381/* old= r, write:xxx, read:del, close:add */382{ 0, 255 },383/* old= r, write:xxx, read:del, close:del */384{ 0, 255 },385/* old= r, write:xxx, read:del, close:xxx */386{ 0, 255 },387/* old= r, write:xxx, read:xxx, close: 0 */388{ 0, 255 },389/* old= r, write:xxx, read:xxx, close:add */390{ 0, 255 },391/* old= r, write:xxx, read:xxx, close:del */392{ 0, 255 },393/* old= r, write:xxx, read:xxx, close:xxx */394{ 0, 255 },395/* old= w, write: 0, read: 0, close: 0 */396{ 0, 0 },397/* old= w, write: 0, read: 0, close:add */398{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },399/* old= w, write: 0, read: 0, close:del */400{ EPOLLOUT, EPOLL_CTL_MOD },401/* old= w, write: 0, read: 0, close:xxx */402{ 0, 255 },403/* old= w, write: 0, read:add, close: 0 */404{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },405/* old= w, write: 0, read:add, close:add */406{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },407/* old= w, write: 0, read:add, close:del */408{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },409/* old= w, write: 0, read:add, close:xxx */410{ 0, 255 },411/* old= w, write: 0, read:del, close: 0 */412{ EPOLLOUT, EPOLL_CTL_MOD },413/* old= w, write: 0, read:del, close:add */414{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },415/* old= w, write: 0, read:del, close:del */416{ EPOLLOUT, EPOLL_CTL_MOD },417/* old= w, write: 0, read:del, close:xxx */418{ 0, 255 },419/* old= w, write: 0, read:xxx, close: 0 */420{ 0, 255 },421/* old= w, write: 0, read:xxx, close:add */422{ 0, 255 },423/* old= w, write: 0, read:xxx, close:del */424{ 0, 255 },425/* old= w, write: 0, read:xxx, close:xxx */426{ 0, 255 },427/* old= w, write:add, read: 0, close: 0 */428{ EPOLLOUT, EPOLL_CTL_MOD },429/* old= w, write:add, read: 0, close:add */430{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },431/* old= w, write:add, read: 0, close:del */432{ EPOLLOUT, EPOLL_CTL_MOD },433/* old= w, write:add, read: 0, close:xxx */434{ 0, 255 },435/* old= w, write:add, read:add, close: 0 */436{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },437/* old= w, write:add, read:add, close:add */438{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },439/* old= w, write:add, read:add, close:del */440{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },441/* old= w, write:add, read:add, close:xxx */442{ 0, 255 },443/* old= w, write:add, read:del, close: 0 */444{ EPOLLOUT, EPOLL_CTL_MOD },445/* old= w, write:add, read:del, close:add */446{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },447/* old= w, write:add, read:del, close:del */448{ EPOLLOUT, EPOLL_CTL_MOD },449/* old= w, write:add, read:del, close:xxx */450{ 0, 255 },451/* old= w, write:add, read:xxx, close: 0 */452{ 0, 255 },453/* old= w, write:add, read:xxx, close:add */454{ 0, 255 },455/* old= w, write:add, read:xxx, close:del */456{ 0, 255 },457/* old= w, write:add, read:xxx, close:xxx */458{ 0, 255 },459/* old= w, write:del, read: 0, close: 0 */460{ EPOLLOUT, EPOLL_CTL_DEL },461/* old= w, write:del, read: 0, close:add */462{ EPOLLRDHUP, EPOLL_CTL_MOD },463/* old= w, write:del, read: 0, close:del */464{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL },465/* old= w, write:del, read: 0, close:xxx */466{ 0, 255 },467/* old= w, write:del, read:add, close: 0 */468{ EPOLLIN, EPOLL_CTL_MOD },469/* old= w, write:del, read:add, close:add */470{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },471/* old= w, write:del, read:add, close:del */472{ EPOLLIN, EPOLL_CTL_MOD },473/* old= w, write:del, read:add, close:xxx */474{ 0, 255 },475/* old= w, write:del, read:del, close: 0 */476{ EPOLLIN|EPOLLOUT, EPOLL_CTL_DEL },477/* old= w, write:del, read:del, close:add */478{ EPOLLRDHUP, EPOLL_CTL_MOD },479/* old= w, write:del, read:del, close:del */480{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL },481/* old= w, write:del, read:del, close:xxx */482{ 0, 255 },483/* old= w, write:del, read:xxx, close: 0 */484{ 0, 255 },485/* old= w, write:del, read:xxx, close:add */486{ 0, 255 },487/* old= w, write:del, read:xxx, close:del */488{ 0, 255 },489/* old= w, write:del, read:xxx, close:xxx */490{ 0, 255 },491/* old= w, write:xxx, read: 0, close: 0 */492{ 0, 255 },493/* old= w, write:xxx, read: 0, close:add */494{ 0, 255 },495/* old= w, write:xxx, read: 0, close:del */496{ 0, 255 },497/* old= w, write:xxx, read: 0, close:xxx */498{ 0, 255 },499/* old= w, write:xxx, read:add, close: 0 */500{ 0, 255 },501/* old= w, write:xxx, read:add, close:add */502{ 0, 255 },503/* old= w, write:xxx, read:add, close:del */504{ 0, 255 },505/* old= w, write:xxx, read:add, close:xxx */506{ 0, 255 },507/* old= w, write:xxx, read:del, close: 0 */508{ 0, 255 },509/* old= w, write:xxx, read:del, close:add */510{ 0, 255 },511/* old= w, write:xxx, read:del, close:del */512{ 0, 255 },513/* old= w, write:xxx, read:del, close:xxx */514{ 0, 255 },515/* old= w, write:xxx, read:xxx, close: 0 */516{ 0, 255 },517/* old= w, write:xxx, read:xxx, close:add */518{ 0, 255 },519/* old= w, write:xxx, read:xxx, close:del */520{ 0, 255 },521/* old= w, write:xxx, read:xxx, close:xxx */522{ 0, 255 },523/* old= rw, write: 0, read: 0, close: 0 */524{ 0, 0 },525/* old= rw, write: 0, read: 0, close:add */526{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },527/* old= rw, write: 0, read: 0, close:del */528{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },529/* old= rw, write: 0, read: 0, close:xxx */530{ 0, 255 },531/* old= rw, write: 0, read:add, close: 0 */532{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },533/* old= rw, write: 0, read:add, close:add */534{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },535/* old= rw, write: 0, read:add, close:del */536{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },537/* old= rw, write: 0, read:add, close:xxx */538{ 0, 255 },539/* old= rw, write: 0, read:del, close: 0 */540{ EPOLLOUT, EPOLL_CTL_MOD },541/* old= rw, write: 0, read:del, close:add */542{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },543/* old= rw, write: 0, read:del, close:del */544{ EPOLLOUT, EPOLL_CTL_MOD },545/* old= rw, write: 0, read:del, close:xxx */546{ 0, 255 },547/* old= rw, write: 0, read:xxx, close: 0 */548{ 0, 255 },549/* old= rw, write: 0, read:xxx, close:add */550{ 0, 255 },551/* old= rw, write: 0, read:xxx, close:del */552{ 0, 255 },553/* old= rw, write: 0, read:xxx, close:xxx */554{ 0, 255 },555/* old= rw, write:add, read: 0, close: 0 */556{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },557/* old= rw, write:add, read: 0, close:add */558{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },559/* old= rw, write:add, read: 0, close:del */560{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },561/* old= rw, write:add, read: 0, close:xxx */562{ 0, 255 },563/* old= rw, write:add, read:add, close: 0 */564{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },565/* old= rw, write:add, read:add, close:add */566{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },567/* old= rw, write:add, read:add, close:del */568{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },569/* old= rw, write:add, read:add, close:xxx */570{ 0, 255 },571/* old= rw, write:add, read:del, close: 0 */572{ EPOLLOUT, EPOLL_CTL_MOD },573/* old= rw, write:add, read:del, close:add */574{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },575/* old= rw, write:add, read:del, close:del */576{ EPOLLOUT, EPOLL_CTL_MOD },577/* old= rw, write:add, read:del, close:xxx */578{ 0, 255 },579/* old= rw, write:add, read:xxx, close: 0 */580{ 0, 255 },581/* old= rw, write:add, read:xxx, close:add */582{ 0, 255 },583/* old= rw, write:add, read:xxx, close:del */584{ 0, 255 },585/* old= rw, write:add, read:xxx, close:xxx */586{ 0, 255 },587/* old= rw, write:del, read: 0, close: 0 */588{ EPOLLIN, EPOLL_CTL_MOD },589/* old= rw, write:del, read: 0, close:add */590{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },591/* old= rw, write:del, read: 0, close:del */592{ EPOLLIN, EPOLL_CTL_MOD },593/* old= rw, write:del, read: 0, close:xxx */594{ 0, 255 },595/* old= rw, write:del, read:add, close: 0 */596{ EPOLLIN, EPOLL_CTL_MOD },597/* old= rw, write:del, read:add, close:add */598{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },599/* old= rw, write:del, read:add, close:del */600{ EPOLLIN, EPOLL_CTL_MOD },601/* old= rw, write:del, read:add, close:xxx */602{ 0, 255 },603/* old= rw, write:del, read:del, close: 0 */604{ EPOLLIN|EPOLLOUT, EPOLL_CTL_DEL },605/* old= rw, write:del, read:del, close:add */606{ EPOLLRDHUP, EPOLL_CTL_MOD },607/* old= rw, write:del, read:del, close:del */608{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL },609/* old= rw, write:del, read:del, close:xxx */610{ 0, 255 },611/* old= rw, write:del, read:xxx, close: 0 */612{ 0, 255 },613/* old= rw, write:del, read:xxx, close:add */614{ 0, 255 },615/* old= rw, write:del, read:xxx, close:del */616{ 0, 255 },617/* old= rw, write:del, read:xxx, close:xxx */618{ 0, 255 },619/* old= rw, write:xxx, read: 0, close: 0 */620{ 0, 255 },621/* old= rw, write:xxx, read: 0, close:add */622{ 0, 255 },623/* old= rw, write:xxx, read: 0, close:del */624{ 0, 255 },625/* old= rw, write:xxx, read: 0, close:xxx */626{ 0, 255 },627/* old= rw, write:xxx, read:add, close: 0 */628{ 0, 255 },629/* old= rw, write:xxx, read:add, close:add */630{ 0, 255 },631/* old= rw, write:xxx, read:add, close:del */632{ 0, 255 },633/* old= rw, write:xxx, read:add, close:xxx */634{ 0, 255 },635/* old= rw, write:xxx, read:del, close: 0 */636{ 0, 255 },637/* old= rw, write:xxx, read:del, close:add */638{ 0, 255 },639/* old= rw, write:xxx, read:del, close:del */640{ 0, 255 },641/* old= rw, write:xxx, read:del, close:xxx */642{ 0, 255 },643/* old= rw, write:xxx, read:xxx, close: 0 */644{ 0, 255 },645/* old= rw, write:xxx, read:xxx, close:add */646{ 0, 255 },647/* old= rw, write:xxx, read:xxx, close:del */648{ 0, 255 },649/* old= rw, write:xxx, read:xxx, close:xxx */650{ 0, 255 },651/* old= c, write: 0, read: 0, close: 0 */652{ 0, 0 },653/* old= c, write: 0, read: 0, close:add */654{ EPOLLRDHUP, EPOLL_CTL_MOD },655/* old= c, write: 0, read: 0, close:del */656{ EPOLLRDHUP, EPOLL_CTL_DEL },657/* old= c, write: 0, read: 0, close:xxx */658{ 0, 255 },659/* old= c, write: 0, read:add, close: 0 */660{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },661/* old= c, write: 0, read:add, close:add */662{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },663/* old= c, write: 0, read:add, close:del */664{ EPOLLIN, EPOLL_CTL_MOD },665/* old= c, write: 0, read:add, close:xxx */666{ 0, 255 },667/* old= c, write: 0, read:del, close: 0 */668{ EPOLLRDHUP, EPOLL_CTL_MOD },669/* old= c, write: 0, read:del, close:add */670{ EPOLLRDHUP, EPOLL_CTL_MOD },671/* old= c, write: 0, read:del, close:del */672{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_DEL },673/* old= c, write: 0, read:del, close:xxx */674{ 0, 255 },675/* old= c, write: 0, read:xxx, close: 0 */676{ 0, 255 },677/* old= c, write: 0, read:xxx, close:add */678{ 0, 255 },679/* old= c, write: 0, read:xxx, close:del */680{ 0, 255 },681/* old= c, write: 0, read:xxx, close:xxx */682{ 0, 255 },683/* old= c, write:add, read: 0, close: 0 */684{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },685/* old= c, write:add, read: 0, close:add */686{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },687/* old= c, write:add, read: 0, close:del */688{ EPOLLOUT, EPOLL_CTL_MOD },689/* old= c, write:add, read: 0, close:xxx */690{ 0, 255 },691/* old= c, write:add, read:add, close: 0 */692{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },693/* old= c, write:add, read:add, close:add */694{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },695/* old= c, write:add, read:add, close:del */696{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },697/* old= c, write:add, read:add, close:xxx */698{ 0, 255 },699/* old= c, write:add, read:del, close: 0 */700{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },701/* old= c, write:add, read:del, close:add */702{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },703/* old= c, write:add, read:del, close:del */704{ EPOLLOUT, EPOLL_CTL_MOD },705/* old= c, write:add, read:del, close:xxx */706{ 0, 255 },707/* old= c, write:add, read:xxx, close: 0 */708{ 0, 255 },709/* old= c, write:add, read:xxx, close:add */710{ 0, 255 },711/* old= c, write:add, read:xxx, close:del */712{ 0, 255 },713/* old= c, write:add, read:xxx, close:xxx */714{ 0, 255 },715/* old= c, write:del, read: 0, close: 0 */716{ EPOLLRDHUP, EPOLL_CTL_MOD },717/* old= c, write:del, read: 0, close:add */718{ EPOLLRDHUP, EPOLL_CTL_MOD },719/* old= c, write:del, read: 0, close:del */720{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL },721/* old= c, write:del, read: 0, close:xxx */722{ 0, 255 },723/* old= c, write:del, read:add, close: 0 */724{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },725/* old= c, write:del, read:add, close:add */726{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },727/* old= c, write:del, read:add, close:del */728{ EPOLLIN, EPOLL_CTL_MOD },729/* old= c, write:del, read:add, close:xxx */730{ 0, 255 },731/* old= c, write:del, read:del, close: 0 */732{ EPOLLRDHUP, EPOLL_CTL_MOD },733/* old= c, write:del, read:del, close:add */734{ EPOLLRDHUP, EPOLL_CTL_MOD },735/* old= c, write:del, read:del, close:del */736{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL },737/* old= c, write:del, read:del, close:xxx */738{ 0, 255 },739/* old= c, write:del, read:xxx, close: 0 */740{ 0, 255 },741/* old= c, write:del, read:xxx, close:add */742{ 0, 255 },743/* old= c, write:del, read:xxx, close:del */744{ 0, 255 },745/* old= c, write:del, read:xxx, close:xxx */746{ 0, 255 },747/* old= c, write:xxx, read: 0, close: 0 */748{ 0, 255 },749/* old= c, write:xxx, read: 0, close:add */750{ 0, 255 },751/* old= c, write:xxx, read: 0, close:del */752{ 0, 255 },753/* old= c, write:xxx, read: 0, close:xxx */754{ 0, 255 },755/* old= c, write:xxx, read:add, close: 0 */756{ 0, 255 },757/* old= c, write:xxx, read:add, close:add */758{ 0, 255 },759/* old= c, write:xxx, read:add, close:del */760{ 0, 255 },761/* old= c, write:xxx, read:add, close:xxx */762{ 0, 255 },763/* old= c, write:xxx, read:del, close: 0 */764{ 0, 255 },765/* old= c, write:xxx, read:del, close:add */766{ 0, 255 },767/* old= c, write:xxx, read:del, close:del */768{ 0, 255 },769/* old= c, write:xxx, read:del, close:xxx */770{ 0, 255 },771/* old= c, write:xxx, read:xxx, close: 0 */772{ 0, 255 },773/* old= c, write:xxx, read:xxx, close:add */774{ 0, 255 },775/* old= c, write:xxx, read:xxx, close:del */776{ 0, 255 },777/* old= c, write:xxx, read:xxx, close:xxx */778{ 0, 255 },779/* old= cr, write: 0, read: 0, close: 0 */780{ 0, 0 },781/* old= cr, write: 0, read: 0, close:add */782{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },783/* old= cr, write: 0, read: 0, close:del */784{ EPOLLIN, EPOLL_CTL_MOD },785/* old= cr, write: 0, read: 0, close:xxx */786{ 0, 255 },787/* old= cr, write: 0, read:add, close: 0 */788{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },789/* old= cr, write: 0, read:add, close:add */790{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },791/* old= cr, write: 0, read:add, close:del */792{ EPOLLIN, EPOLL_CTL_MOD },793/* old= cr, write: 0, read:add, close:xxx */794{ 0, 255 },795/* old= cr, write: 0, read:del, close: 0 */796{ EPOLLRDHUP, EPOLL_CTL_MOD },797/* old= cr, write: 0, read:del, close:add */798{ EPOLLRDHUP, EPOLL_CTL_MOD },799/* old= cr, write: 0, read:del, close:del */800{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_DEL },801/* old= cr, write: 0, read:del, close:xxx */802{ 0, 255 },803/* old= cr, write: 0, read:xxx, close: 0 */804{ 0, 255 },805/* old= cr, write: 0, read:xxx, close:add */806{ 0, 255 },807/* old= cr, write: 0, read:xxx, close:del */808{ 0, 255 },809/* old= cr, write: 0, read:xxx, close:xxx */810{ 0, 255 },811/* old= cr, write:add, read: 0, close: 0 */812{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },813/* old= cr, write:add, read: 0, close:add */814{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },815/* old= cr, write:add, read: 0, close:del */816{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },817/* old= cr, write:add, read: 0, close:xxx */818{ 0, 255 },819/* old= cr, write:add, read:add, close: 0 */820{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },821/* old= cr, write:add, read:add, close:add */822{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },823/* old= cr, write:add, read:add, close:del */824{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },825/* old= cr, write:add, read:add, close:xxx */826{ 0, 255 },827/* old= cr, write:add, read:del, close: 0 */828{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },829/* old= cr, write:add, read:del, close:add */830{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },831/* old= cr, write:add, read:del, close:del */832{ EPOLLOUT, EPOLL_CTL_MOD },833/* old= cr, write:add, read:del, close:xxx */834{ 0, 255 },835/* old= cr, write:add, read:xxx, close: 0 */836{ 0, 255 },837/* old= cr, write:add, read:xxx, close:add */838{ 0, 255 },839/* old= cr, write:add, read:xxx, close:del */840{ 0, 255 },841/* old= cr, write:add, read:xxx, close:xxx */842{ 0, 255 },843/* old= cr, write:del, read: 0, close: 0 */844{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },845/* old= cr, write:del, read: 0, close:add */846{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },847/* old= cr, write:del, read: 0, close:del */848{ EPOLLIN, EPOLL_CTL_MOD },849/* old= cr, write:del, read: 0, close:xxx */850{ 0, 255 },851/* old= cr, write:del, read:add, close: 0 */852{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },853/* old= cr, write:del, read:add, close:add */854{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },855/* old= cr, write:del, read:add, close:del */856{ EPOLLIN, EPOLL_CTL_MOD },857/* old= cr, write:del, read:add, close:xxx */858{ 0, 255 },859/* old= cr, write:del, read:del, close: 0 */860{ EPOLLRDHUP, EPOLL_CTL_MOD },861/* old= cr, write:del, read:del, close:add */862{ EPOLLRDHUP, EPOLL_CTL_MOD },863/* old= cr, write:del, read:del, close:del */864{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL },865/* old= cr, write:del, read:del, close:xxx */866{ 0, 255 },867/* old= cr, write:del, read:xxx, close: 0 */868{ 0, 255 },869/* old= cr, write:del, read:xxx, close:add */870{ 0, 255 },871/* old= cr, write:del, read:xxx, close:del */872{ 0, 255 },873/* old= cr, write:del, read:xxx, close:xxx */874{ 0, 255 },875/* old= cr, write:xxx, read: 0, close: 0 */876{ 0, 255 },877/* old= cr, write:xxx, read: 0, close:add */878{ 0, 255 },879/* old= cr, write:xxx, read: 0, close:del */880{ 0, 255 },881/* old= cr, write:xxx, read: 0, close:xxx */882{ 0, 255 },883/* old= cr, write:xxx, read:add, close: 0 */884{ 0, 255 },885/* old= cr, write:xxx, read:add, close:add */886{ 0, 255 },887/* old= cr, write:xxx, read:add, close:del */888{ 0, 255 },889/* old= cr, write:xxx, read:add, close:xxx */890{ 0, 255 },891/* old= cr, write:xxx, read:del, close: 0 */892{ 0, 255 },893/* old= cr, write:xxx, read:del, close:add */894{ 0, 255 },895/* old= cr, write:xxx, read:del, close:del */896{ 0, 255 },897/* old= cr, write:xxx, read:del, close:xxx */898{ 0, 255 },899/* old= cr, write:xxx, read:xxx, close: 0 */900{ 0, 255 },901/* old= cr, write:xxx, read:xxx, close:add */902{ 0, 255 },903/* old= cr, write:xxx, read:xxx, close:del */904{ 0, 255 },905/* old= cr, write:xxx, read:xxx, close:xxx */906{ 0, 255 },907/* old= cw, write: 0, read: 0, close: 0 */908{ 0, 0 },909/* old= cw, write: 0, read: 0, close:add */910{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },911/* old= cw, write: 0, read: 0, close:del */912{ EPOLLOUT, EPOLL_CTL_MOD },913/* old= cw, write: 0, read: 0, close:xxx */914{ 0, 255 },915/* old= cw, write: 0, read:add, close: 0 */916{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },917/* old= cw, write: 0, read:add, close:add */918{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },919/* old= cw, write: 0, read:add, close:del */920{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },921/* old= cw, write: 0, read:add, close:xxx */922{ 0, 255 },923/* old= cw, write: 0, read:del, close: 0 */924{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },925/* old= cw, write: 0, read:del, close:add */926{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },927/* old= cw, write: 0, read:del, close:del */928{ EPOLLOUT, EPOLL_CTL_MOD },929/* old= cw, write: 0, read:del, close:xxx */930{ 0, 255 },931/* old= cw, write: 0, read:xxx, close: 0 */932{ 0, 255 },933/* old= cw, write: 0, read:xxx, close:add */934{ 0, 255 },935/* old= cw, write: 0, read:xxx, close:del */936{ 0, 255 },937/* old= cw, write: 0, read:xxx, close:xxx */938{ 0, 255 },939/* old= cw, write:add, read: 0, close: 0 */940{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },941/* old= cw, write:add, read: 0, close:add */942{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },943/* old= cw, write:add, read: 0, close:del */944{ EPOLLOUT, EPOLL_CTL_MOD },945/* old= cw, write:add, read: 0, close:xxx */946{ 0, 255 },947/* old= cw, write:add, read:add, close: 0 */948{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },949/* old= cw, write:add, read:add, close:add */950{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },951/* old= cw, write:add, read:add, close:del */952{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },953/* old= cw, write:add, read:add, close:xxx */954{ 0, 255 },955/* old= cw, write:add, read:del, close: 0 */956{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },957/* old= cw, write:add, read:del, close:add */958{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },959/* old= cw, write:add, read:del, close:del */960{ EPOLLOUT, EPOLL_CTL_MOD },961/* old= cw, write:add, read:del, close:xxx */962{ 0, 255 },963/* old= cw, write:add, read:xxx, close: 0 */964{ 0, 255 },965/* old= cw, write:add, read:xxx, close:add */966{ 0, 255 },967/* old= cw, write:add, read:xxx, close:del */968{ 0, 255 },969/* old= cw, write:add, read:xxx, close:xxx */970{ 0, 255 },971/* old= cw, write:del, read: 0, close: 0 */972{ EPOLLRDHUP, EPOLL_CTL_MOD },973/* old= cw, write:del, read: 0, close:add */974{ EPOLLRDHUP, EPOLL_CTL_MOD },975/* old= cw, write:del, read: 0, close:del */976{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL },977/* old= cw, write:del, read: 0, close:xxx */978{ 0, 255 },979/* old= cw, write:del, read:add, close: 0 */980{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },981/* old= cw, write:del, read:add, close:add */982{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },983/* old= cw, write:del, read:add, close:del */984{ EPOLLIN, EPOLL_CTL_MOD },985/* old= cw, write:del, read:add, close:xxx */986{ 0, 255 },987/* old= cw, write:del, read:del, close: 0 */988{ EPOLLRDHUP, EPOLL_CTL_MOD },989/* old= cw, write:del, read:del, close:add */990{ EPOLLRDHUP, EPOLL_CTL_MOD },991/* old= cw, write:del, read:del, close:del */992{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL },993/* old= cw, write:del, read:del, close:xxx */994{ 0, 255 },995/* old= cw, write:del, read:xxx, close: 0 */996{ 0, 255 },997/* old= cw, write:del, read:xxx, close:add */998{ 0, 255 },999/* old= cw, write:del, read:xxx, close:del */1000{ 0, 255 },1001/* old= cw, write:del, read:xxx, close:xxx */1002{ 0, 255 },1003/* old= cw, write:xxx, read: 0, close: 0 */1004{ 0, 255 },1005/* old= cw, write:xxx, read: 0, close:add */1006{ 0, 255 },1007/* old= cw, write:xxx, read: 0, close:del */1008{ 0, 255 },1009/* old= cw, write:xxx, read: 0, close:xxx */1010{ 0, 255 },1011/* old= cw, write:xxx, read:add, close: 0 */1012{ 0, 255 },1013/* old= cw, write:xxx, read:add, close:add */1014{ 0, 255 },1015/* old= cw, write:xxx, read:add, close:del */1016{ 0, 255 },1017/* old= cw, write:xxx, read:add, close:xxx */1018{ 0, 255 },1019/* old= cw, write:xxx, read:del, close: 0 */1020{ 0, 255 },1021/* old= cw, write:xxx, read:del, close:add */1022{ 0, 255 },1023/* old= cw, write:xxx, read:del, close:del */1024{ 0, 255 },1025/* old= cw, write:xxx, read:del, close:xxx */1026{ 0, 255 },1027/* old= cw, write:xxx, read:xxx, close: 0 */1028{ 0, 255 },1029/* old= cw, write:xxx, read:xxx, close:add */1030{ 0, 255 },1031/* old= cw, write:xxx, read:xxx, close:del */1032{ 0, 255 },1033/* old= cw, write:xxx, read:xxx, close:xxx */1034{ 0, 255 },1035/* old=crw, write: 0, read: 0, close: 0 */1036{ 0, 0 },1037/* old=crw, write: 0, read: 0, close:add */1038{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },1039/* old=crw, write: 0, read: 0, close:del */1040{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },1041/* old=crw, write: 0, read: 0, close:xxx */1042{ 0, 255 },1043/* old=crw, write: 0, read:add, close: 0 */1044{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },1045/* old=crw, write: 0, read:add, close:add */1046{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },1047/* old=crw, write: 0, read:add, close:del */1048{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },1049/* old=crw, write: 0, read:add, close:xxx */1050{ 0, 255 },1051/* old=crw, write: 0, read:del, close: 0 */1052{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },1053/* old=crw, write: 0, read:del, close:add */1054{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },1055/* old=crw, write: 0, read:del, close:del */1056{ EPOLLOUT, EPOLL_CTL_MOD },1057/* old=crw, write: 0, read:del, close:xxx */1058{ 0, 255 },1059/* old=crw, write: 0, read:xxx, close: 0 */1060{ 0, 255 },1061/* old=crw, write: 0, read:xxx, close:add */1062{ 0, 255 },1063/* old=crw, write: 0, read:xxx, close:del */1064{ 0, 255 },1065/* old=crw, write: 0, read:xxx, close:xxx */1066{ 0, 255 },1067/* old=crw, write:add, read: 0, close: 0 */1068{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },1069/* old=crw, write:add, read: 0, close:add */1070{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },1071/* old=crw, write:add, read: 0, close:del */1072{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },1073/* old=crw, write:add, read: 0, close:xxx */1074{ 0, 255 },1075/* old=crw, write:add, read:add, close: 0 */1076{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },1077/* old=crw, write:add, read:add, close:add */1078{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },1079/* old=crw, write:add, read:add, close:del */1080{ EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD },1081/* old=crw, write:add, read:add, close:xxx */1082{ 0, 255 },1083/* old=crw, write:add, read:del, close: 0 */1084{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },1085/* old=crw, write:add, read:del, close:add */1086{ EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD },1087/* old=crw, write:add, read:del, close:del */1088{ EPOLLOUT, EPOLL_CTL_MOD },1089/* old=crw, write:add, read:del, close:xxx */1090{ 0, 255 },1091/* old=crw, write:add, read:xxx, close: 0 */1092{ 0, 255 },1093/* old=crw, write:add, read:xxx, close:add */1094{ 0, 255 },1095/* old=crw, write:add, read:xxx, close:del */1096{ 0, 255 },1097/* old=crw, write:add, read:xxx, close:xxx */1098{ 0, 255 },1099/* old=crw, write:del, read: 0, close: 0 */1100{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },1101/* old=crw, write:del, read: 0, close:add */1102{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },1103/* old=crw, write:del, read: 0, close:del */1104{ EPOLLIN, EPOLL_CTL_MOD },1105/* old=crw, write:del, read: 0, close:xxx */1106{ 0, 255 },1107/* old=crw, write:del, read:add, close: 0 */1108{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },1109/* old=crw, write:del, read:add, close:add */1110{ EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD },1111/* old=crw, write:del, read:add, close:del */1112{ EPOLLIN, EPOLL_CTL_MOD },1113/* old=crw, write:del, read:add, close:xxx */1114{ 0, 255 },1115/* old=crw, write:del, read:del, close: 0 */1116{ EPOLLRDHUP, EPOLL_CTL_MOD },1117/* old=crw, write:del, read:del, close:add */1118{ EPOLLRDHUP, EPOLL_CTL_MOD },1119/* old=crw, write:del, read:del, close:del */1120{ EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL },1121/* old=crw, write:del, read:del, close:xxx */1122{ 0, 255 },1123/* old=crw, write:del, read:xxx, close: 0 */1124{ 0, 255 },1125/* old=crw, write:del, read:xxx, close:add */1126{ 0, 255 },1127/* old=crw, write:del, read:xxx, close:del */1128{ 0, 255 },1129/* old=crw, write:del, read:xxx, close:xxx */1130{ 0, 255 },1131/* old=crw, write:xxx, read: 0, close: 0 */1132{ 0, 255 },1133/* old=crw, write:xxx, read: 0, close:add */1134{ 0, 255 },1135/* old=crw, write:xxx, read: 0, close:del */1136{ 0, 255 },1137/* old=crw, write:xxx, read: 0, close:xxx */1138{ 0, 255 },1139/* old=crw, write:xxx, read:add, close: 0 */1140{ 0, 255 },1141/* old=crw, write:xxx, read:add, close:add */1142{ 0, 255 },1143/* old=crw, write:xxx, read:add, close:del */1144{ 0, 255 },1145/* old=crw, write:xxx, read:add, close:xxx */1146{ 0, 255 },1147/* old=crw, write:xxx, read:del, close: 0 */1148{ 0, 255 },1149/* old=crw, write:xxx, read:del, close:add */1150{ 0, 255 },1151/* old=crw, write:xxx, read:del, close:del */1152{ 0, 255 },1153/* old=crw, write:xxx, read:del, close:xxx */1154{ 0, 255 },1155/* old=crw, write:xxx, read:xxx, close: 0 */1156{ 0, 255 },1157/* old=crw, write:xxx, read:xxx, close:add */1158{ 0, 255 },1159/* old=crw, write:xxx, read:xxx, close:del */1160{ 0, 255 },1161/* old=crw, write:xxx, read:xxx, close:xxx */1162{ 0, 255 },1163};11641165#endif116611671168