qemu-e2k/include/qemu
Paolo Bonzini 53fabd4b86 qemu-ga: obey LISTEN_PID when using systemd socket activation
qemu-ga's socket activation support was not obeying the LISTEN_PID
environment variable, which avoids that a process uses a socket-activation
file descriptor meant for its parent.

Mess can for example ensue if a process forks a children before consuming
the socket-activation file descriptor and therefore setting O_CLOEXEC
on it.

Luckily, qemu-nbd also got socket activation code, and its copy does
support LISTEN_PID.  Some extra fixups are needed to ensure that the
code can be used for both, but that's what this patch does.  The
main change is to replace get_listen_fds's "consume" argument with
the FIRST_SOCKET_ACTIVATION_FD macro from the qemu-nbd code.

Cc: "Richard W.M. Jones" <rjones@redhat.com>
Cc: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Daniel P. Berrange <berrange@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2017-03-19 11:12:12 +01:00
..
acl.h
atomic.h
base64.h
bcd.h
bitmap.h
bitops.h
bswap.h
buffer.h
compiler.h
config-file.h
coroutine_int.h aio: introduce aio_co_schedule and aio_co_wake 2017-02-21 11:14:07 +00:00
coroutine.h coroutine-lock: make CoRwlock thread-safe and fair 2017-02-21 11:39:40 +00:00
crc32c.h
cutils.h util/cutils: Change qemu_strtosz*() from int64_t to uint64_t 2017-02-23 20:35:36 +01:00
envlist.h
error-report.h
event_notifier.h
fifo8.h
fifo32.h
fprintf-fn.h
futex.h
hbitmap.h
help_option.h
host-utils.h
id.h
int128.h
iov.h
jhash.h
log.h
main-loop.h
memfd.h
mmap-alloc.h exec, kvm, target-ppc: Move getrampagesize() to common code 2017-03-03 11:30:59 +11:00
module.h qmp: Dumb down how we run QMP command registration 2017-03-05 09:02:10 +01:00
notify.h
option_int.h
option.h keyval: New keyval_parse() 2017-03-07 16:07:46 +01:00
osdep.h mem-prealloc: reduce large guest start-up and migration time. 2017-03-14 13:26:36 +01:00
path.h
processor.h
qdist.h
qht.h
queue.h
range.h
ratelimit.h
rcu_queue.h
rcu.h
readline.h
seqlock.h
sockets.h
systemd.h qemu-ga: obey LISTEN_PID when using systemd socket activation 2017-03-19 11:12:12 +01:00
thread-posix.h
thread-win32.h
thread.h
throttle-options.h throttle: factor out duplicate code 2017-02-28 10:31:46 +01:00
throttle.h
timed-average.h
timer.h icount: process QEMU_CLOCK_VIRTUAL timers in vCPU thread 2017-03-14 13:51:34 +01:00
typedefs.h
unicode.h
uri.h
uuid.h
xattr.h