ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/libev/ev_iouring.c
(Generate patch)

Comparing libev/ev_iouring.c (file contents):
Revision 1.2 by root, Tue Jul 9 00:04:35 2019 UTC vs.
Revision 1.3 by root, Sat Aug 17 05:30:16 2019 UTC

574static void 574static void
575iouring_poll (EV_P_ ev_tstamp timeout) 575iouring_poll (EV_P_ ev_tstamp timeout)
576{ 576{
577 /* if we have events, no need for extra syscalls, but we might have to queue events */ 577 /* if we have events, no need for extra syscalls, but we might have to queue events */
578 if (iouring_handle_cq (EV_A)) 578 if (iouring_handle_cq (EV_A))
579 timeout = 0.; 579 timeout = EV_TS_CONST (0.);
580 else 580 else
581 /* no events, so maybe wait for some */ 581 /* no events, so maybe wait for some */
582 iouring_tfd_update (EV_A_ timeout); 582 iouring_tfd_update (EV_A_ timeout);
583 583
584 /* only enter the kernel if we have somethign to submit, or we need to wait */ 584 /* only enter the kernel if we have somethign to submit, or we need to wait */
587 int res; 587 int res;
588 588
589 EV_RELEASE_CB; 589 EV_RELEASE_CB;
590 590
591 res = evsys_io_uring_enter (iouring_fd, iouring_to_submit, 1, 591 res = evsys_io_uring_enter (iouring_fd, iouring_to_submit, 1,
592 timeout ? IORING_ENTER_GETEVENTS : 0, 0, 0); 592 timeout > EV_TS_CONST (0.) ? IORING_ENTER_GETEVENTS : 0, 0, 0);
593 iouring_to_submit = 0; 593 iouring_to_submit = 0;
594 594
595 EV_ACQUIRE_CB; 595 EV_ACQUIRE_CB;
596 596
597 if (ecb_expect_false (res < 0)) 597 if (ecb_expect_false (res < 0))

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines