[systemd-devel] sd_event_run
Lennart Poettering
lennart at poettering.net
Sun Apr 12 10:34:17 PDT 2015
On Sat, 11.04.15 18:24, Shawn Landden (shawnlandden at gmail.com) wrote:
> On Sat, Apr 11, 2015 at 6:01 PM, Shawn Landden <shawnlandden at gmail.com> wrote:
> > On Sat, Apr 11, 2015 at 4:52 PM, Zbigniew Jędrzejewski-Szmek
> > <zbyszek at in.waw.pl> wrote:
> >> On Fri, Apr 10, 2015 at 06:14:40PM +0200, Lennart Poettering wrote:
> >>> On Sat, 14.03.15 12:19, Tom Gundersen (teg at jklm.no) wrote:
> >>>
> >>> > > 1. shouldn't SD_EVENT_PASSIVE become SD_EVENT_INITIAL? "passive" seems strange
> >>> > > in this context.
> > How about SD_EVENT_STALE? Stale things are distasteful unless they are
> > freshened up.
> Nah, Prepared is good.
>
> But this SD_EVENT_PASSIVE and SD_EVENT_RUNNING is incompatible with
> making this multithreaded. Instead there could be a function (int
> sd_event_references(sd_event *e)) that returns e->n_ref.
This is never going to be multithreaded. We strictly dispatch in
order, and this is not going to change. This behaviour is visible
pretty much everywhere in the API, already because we have priorities
and stuff.
In fact, none of our library code is thread-safe, but all is
threads-aware, and that's not going to change, sorry...
Lennart
--
Lennart Poettering, Red Hat
More information about the systemd-devel
mailing list