qemu-e2k/util
Paolo Bonzini 21b7cf9e07 rcu: handle forks safely
After forking, only the calling thread is duplicated in the child process.
The call_rcu thread has to be recreated in the child.  Exploit the fact
that only one thread exists (same as when constructors run), and just redo
the entire initialization to ensure the threads are in the proper state.

The only additional things to do are emptying the list of threads
registered with RCU, and unlocking the lock that was taken in the prepare
callback (implementations are allowed to fail pthread_mutex_init()
if the mutex is still locked).

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2015-03-10 10:49:25 +01:00
..
Makefile.objs rcu: add rcu library 2015-02-02 16:55:10 +01:00
acl.c acl: fix memory leak 2014-11-17 11:48:56 +01:00
aes.c aes: remove a dead return statement 2015-02-10 09:27:20 +03:00
bitmap.c
bitops.c
compatfd.c
crc32c.c
cutils.c qxl: refactor rounding up to a nearest power of 2 2015-03-03 08:33:08 +01:00
envlist.c utils: drop strtok_r from envlist_parse 2015-02-16 16:20:02 -06:00
error.c error: Use error_report_err() where appropriate 2015-02-18 10:51:09 +01:00
event_notifier-posix.c
event_notifier-win32.c
fifo8.c savevm: Remove all the unneeded version_minimum_id_old (arm) 2014-05-13 16:09:35 +01:00
getauxval.c util: Move general qemu_getauxval to util/getauxval.c 2014-09-09 13:13:05 +02:00
hbitmap.c util: Use g_new() & friends where that makes obvious sense 2014-12-10 11:34:15 +03:00
hexdump.c
host-utils.c util: Don't link host-utils.o if it's empty 2014-09-09 13:13:05 +02:00
id.c util: Emancipate id_wellformed() from QemuOpts 2014-10-03 10:30:33 +01:00
iov.c util: Use g_new() & friends where that makes obvious sense 2014-12-10 11:34:15 +03:00
module.c module: Don't complain when a module is absent 2014-07-18 14:57:35 +02:00
notify.c
osdep.c do not call g_thread_init() for glib >= 2.31 2014-05-07 21:00:43 +04:00
oslib-posix.c memory: expose alignment used for allocating RAM as MemoryRegion API 2014-11-23 12:11:30 +02:00
oslib-win32.c memory: expose alignment used for allocating RAM as MemoryRegion API 2014-11-23 12:11:30 +02:00
path.c util/path: Use the GLib memory allocation routines 2014-08-24 13:16:32 +04:00
qemu-config.c QemuOpts: Drop qemu_opt_set(), rename qemu_opt_set_err(), fix use 2015-02-26 14:49:31 +01:00
qemu-error.c qemu-error: Add error_vreport() 2014-10-09 15:36:15 +02:00
qemu-openpty.c util/qemu-openpty: fix build with musl libc by include termios.h as fallback 2014-06-11 00:25:06 +01:00
qemu-option.c qemu-img: Suppress unhelpful extra errors in convert, amend 2015-02-26 14:51:21 +01:00
qemu-progress.c
qemu-sockets.c qemu-sockets: Simplify setting numeric and boolean options 2015-02-26 14:51:53 +01:00
qemu-thread-posix.c qemu-thread: do not use PTHREAD_MUTEX_ERRORCHECK 2015-03-10 10:49:25 +01:00
qemu-thread-win32.c qemu-thread: add per-thread atexit functions 2015-01-13 13:43:29 +00:00
qemu-timer-common.c
rcu.c rcu: handle forks safely 2015-03-10 10:49:25 +01:00
readline.c readline: Clear screen on form feed. 2014-06-11 10:10:29 -04:00
rfifolock.c
throttle.c throttle: add throttle_detach/attach_aio_context() 2014-06-04 09:56:12 +02:00
unicode.c
uri.c util/uri: URI member path can be null, compare more carfully 2015-02-10 09:27:20 +03:00