Lines Matching refs:ch
176 const struct event_change *ch) in epoll_apply_one_change() argument
194 if ((ch->read_change & EV_CHANGE_ADD) || in epoll_apply_one_change()
195 (ch->write_change & EV_CHANGE_ADD)) { in epoll_apply_one_change()
200 if (ch->read_change & EV_CHANGE_ADD) { in epoll_apply_one_change()
202 } else if (ch->read_change & EV_CHANGE_DEL) { in epoll_apply_one_change()
204 } else if (ch->old_events & EV_READ) { in epoll_apply_one_change()
207 if (ch->write_change & EV_CHANGE_ADD) { in epoll_apply_one_change()
209 } else if (ch->write_change & EV_CHANGE_DEL) { in epoll_apply_one_change()
211 } else if (ch->old_events & EV_WRITE) { in epoll_apply_one_change()
214 if ((ch->read_change|ch->write_change) & EV_ET) in epoll_apply_one_change()
217 if (ch->old_events) { in epoll_apply_one_change()
234 } else if ((ch->read_change & EV_CHANGE_DEL) || in epoll_apply_one_change()
235 (ch->write_change & EV_CHANGE_DEL)) { in epoll_apply_one_change()
240 if (ch->read_change & EV_CHANGE_DEL) { in epoll_apply_one_change()
241 if (ch->write_change & EV_CHANGE_DEL) { in epoll_apply_one_change()
243 } else if (ch->old_events & EV_WRITE) { in epoll_apply_one_change()
249 } else if (ch->write_change & EV_CHANGE_DEL) { in epoll_apply_one_change()
250 if (ch->old_events & EV_READ) { in epoll_apply_one_change()
263 epev.data.fd = ch->fd; in epoll_apply_one_change()
265 if (epoll_ctl(epollop->epfd, op, ch->fd, &epev) == -1) { in epoll_apply_one_change()
271 if (epoll_ctl(epollop->epfd, EPOLL_CTL_ADD, ch->fd, &epev) == -1) { in epoll_apply_one_change()
273 (int)epev.events, ch->fd); in epoll_apply_one_change()
278 ch->fd)); in epoll_apply_one_change()
288 if (epoll_ctl(epollop->epfd, EPOLL_CTL_MOD, ch->fd, &epev) == -1) { in epoll_apply_one_change()
290 (int)epev.events, ch->fd); in epoll_apply_one_change()
295 ch->fd)); in epoll_apply_one_change()
305 ch->fd, in epoll_apply_one_change()
311 ch->fd, in epoll_apply_one_change()
312 ch->old_events, in epoll_apply_one_change()
313 ch->read_change, in epoll_apply_one_change()
314 change_to_string(ch->read_change), in epoll_apply_one_change()
315 ch->write_change, in epoll_apply_one_change()
316 change_to_string(ch->write_change)); in epoll_apply_one_change()
323 (int)ch->fd, in epoll_apply_one_change()
324 ch->old_events, in epoll_apply_one_change()
325 ch->read_change, in epoll_apply_one_change()
326 ch->write_change)); in epoll_apply_one_change()
337 struct event_change *ch; in epoll_apply_changes() local
343 ch = &changelist->changes[i]; in epoll_apply_changes()
344 if (epoll_apply_one_change(base, epollop, ch) < 0) in epoll_apply_changes()
355 struct event_change ch; in epoll_nochangelist_add() local
356 ch.fd = fd; in epoll_nochangelist_add()
357 ch.old_events = old; in epoll_nochangelist_add()
358 ch.read_change = ch.write_change = 0; in epoll_nochangelist_add()
360 ch.write_change = EV_CHANGE_ADD | in epoll_nochangelist_add()
363 ch.read_change = EV_CHANGE_ADD | in epoll_nochangelist_add()
366 return epoll_apply_one_change(base, base->evbase, &ch); in epoll_nochangelist_add()
373 struct event_change ch; in epoll_nochangelist_del() local
374 ch.fd = fd; in epoll_nochangelist_del()
375 ch.old_events = old; in epoll_nochangelist_del()
376 ch.read_change = ch.write_change = 0; in epoll_nochangelist_del()
378 ch.write_change = EV_CHANGE_DEL; in epoll_nochangelist_del()
380 ch.read_change = EV_CHANGE_DEL; in epoll_nochangelist_del()
382 return epoll_apply_one_change(base, base->evbase, &ch); in epoll_nochangelist_del()