summaryrefslogtreecommitdiff
path: root/source4/lib/events/events_internal.h
AgeCommit message (Collapse)AuthorFilesLines
2009-01-02s4:lib/events: remove unused events_internal.hStefan Metzmacher1-5/+0
external users need to use tevent_internal.h anyway metze
2008-12-29lib/tevent: rename event_* => tevent_* in the header fileStefan Metzmacher1-0/+4
We have compat macros to keep the callers happy. metze
2008-12-26Fix some tevent includes, trying to fix the buildKai Blin1-1/+1
2008-12-17s4:lib/tevent: add lib/events/ compat and let things compileStefan Metzmacher1-0/+1
metze
2008-12-17s4:lib/events: move to toplevel directory as lib/tevent/Stefan Metzmacher1-158/+0
This commit will not compile on its own. metze
2008-06-17Avoid including events_util.h in events_internal.h since the latter isJelmer Vernooij1-2/+0
installed. (This used to be commit 7a7e8f30dd3e5bfad788a098872afa8263321cbb)
2008-06-14This patch make it possible to build the events library completelySimo Sorce1-1/+33
standalone with no ties to internal samba4 functions Samba4 itself just uses the plain library, compatibility glue is in events_s4.c only (This used to be commit 7109b6a5a19eb2dbef4259104858b171298bad6e)
2007-10-10r23792: convert Samba4 to GPLv3Andrew Tridgell1-3/+2
There are still a few tidyups of old FSF addresses to come (in both s3 and s4). More commits soon. (This used to be commit fcf38a38ac691abd0fa51b89dc951a08e89fdafa)
2007-10-10r22661: optimize the handling of directly triggered timed events:Stefan Metzmacher1-2/+1
- if someone adds a timed_event with a zero timeval we now avoid serval gettimeofday() calls and the event handler doesn't get the current time when it's called, instead we also pass a zero timeval - this also makes sure multiple timed events with a zero timeval are processed in the order there're added. the little benchmark shows that processing 2000000 directly timed events is now much faster, while avoiding syscalls at all! > time ./evtest (with the old code) real 0m6.388s user 0m1.740s sys 0m4.632s > time ./evtest (with the new code) real 0m1.498s user 0m1.496s sys 0m0.004s metze@SERNOX:~/devel/samba/4.0/samba4-ci/source> cat evtest.c #include <stdio.h> #include <stdint.h> #include <sys/time.h> #include <talloc.h> #include <events.h> static void dummy_fde_handler(struct event_context *ev_ctx, struct fd_event *fde, uint16_t flags, void *private_data) { } static void timeout_handler(struct event_context *ev, struct timed_event *te, struct timeval tval, void *private_data) { uint32_t *countp = (uint32_t *)private_data; (*countp)++; if (*countp > 2000000) exit(0); event_add_timed(ev, ev, tval, timeout_handler, countp); } int main(void) { struct event_context *ev; struct timeval tval = { 0, 0 }; uint32_t count = 0; ev = event_context_init(NULL); event_add_fd(ev, ev, 0, 0, dummy_fde_handler, NULL); event_add_timed(ev, ev, tval, timeout_handler, &count); return event_loop_wait(ev); } (This used to be commit 4db64b4ce2320b88d648078cbf86385f6fb44f1f)
2007-10-10r22634: make the events system much less dependent on the samba4 build systemAndrew Tridgell1-1/+1
(This used to be commit b0c8c1cd21e3f91431504d70a4bc0d3c6dee6071)
2007-10-10r20930: use sigaction() instead of signal()Andrew Tridgell1-1/+3
add support for sa_flags argument to event_add_signal(). These are passed to sigaction(). Special handling is provided for SA_RESETHAND (which tells the event system to remove the handler after the signal) and SA_SIGINFO which allows the siginfo structure to be received per signal (This used to be commit 1bb10b6cf7d717ad21834e73a4ca4b22b5fb6f0a)
2007-10-10r20928: added signal events to lib/eventsAndrew Tridgell1-0/+28
Jeremy asked for this to allow Samba3 to use the Samba4 events library see torture/local/event.c for an example (This used to be commit 7e105482ff9a3da6b4708ff99a64f1881614fc5f)
2007-10-10r20539: - split the common timer related events code into events_timed.cAndrew Tridgell1-2/+21
- make it easier to plug in a new events backend - add simpler 'select' and 'epoll' backends This is part of the effort to add good AIO support. The events_aio.c backend is done, but sometimes dies with a SEGV, which is why it isn't enabled yet. (This used to be commit 934f18283dbc7958944931a93a854526bcd54884)
2007-10-10r12140: - add an additional_flags field to the fd_event struct, so thatStefan Metzmacher1-0/+1
the events backend can store private flags - add function to access the gtk event loop ops struct metze (This used to be commit a5cc0758a393f36a770cdd57e317214d03934c13)
2007-10-10r5407: - this patch makes samba's event loop code more generic and makesStefan Metzmacher1-0/+80
using other implementations possible. This will be mostly usefull for client apps which have there own event loop and want to use our client libs - add a example plugin for liboop (see http://liboop.org) NOTE: this just compiles and is completly untested and is commited only as example metze (This used to be commit b3d0a410efe856e3bcf127f00c31905f5a23cc04)