Print this page
8634 epoll fails to wake on certain edge-triggered conditions
8635 epoll should not emit POLLNVAL
8636 recursive epoll should emit EPOLLRDNORM
Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com>
Reviewed by: Robert Mustacchi <rm@joyent.com>
Reviewed by: Toomas Soome <tsoome@me.com>
Reviewed by: Igor Kozhukhov <igor@dilos.org>

*** 23,33 **** * Use is subject to license terms. * Copyright (c) 2016 by Delphix. All rights reserved. */ /* ! * Copyright (c) 2015, Joyent, Inc. All rights reserved. * Copyright 2017 James S Blachly, MD <james.blachly@gmail.com> */ /* * Memory special file --- 23,33 ---- * Use is subject to license terms. * Copyright (c) 2016 by Delphix. All rights reserved. */ /* ! * Copyright 2017 Joyent, Inc. * Copyright 2017 James S Blachly, MD <james.blachly@gmail.com> */ /* * Memory special file
*** 257,270 **** case M_ALLKMEM: *reventsp = events & (POLLIN | POLLOUT | POLLPRI | POLLRDNORM | POLLWRNORM | POLLRDBAND | POLLWRBAND); /* * A non NULL pollhead pointer should be returned in case ! * user polls for 0 events. */ ! *phpp = !anyyet && !*reventsp ? ! &mm_pollhd : (struct pollhead *)NULL; return (0); default: /* no other devices currently support polling */ return (ENXIO); } --- 257,271 ---- case M_ALLKMEM: *reventsp = events & (POLLIN | POLLOUT | POLLPRI | POLLRDNORM | POLLWRNORM | POLLRDBAND | POLLWRBAND); /* * A non NULL pollhead pointer should be returned in case ! * user polls for 0 events or is doing an edge-triggerd poll. */ ! if ((!*reventsp && !anyyet) || (events & POLLET)) { ! *phpp = &mm_pollhd; ! } return (0); default: /* no other devices currently support polling */ return (ENXIO); }