qemu/include
Kevin Wolf 7e17111646 block/graph-lock: Make WITH_GRAPH_RDLOCK_GUARD() fully checked
Upstream clang 18 (and backports to clang 17 in Fedora and RHEL)
implemented support for __attribute__((cleanup())) in its Thread Safety
Analysis, so we can now actually have a proper implementation of
WITH_GRAPH_RDLOCK_GUARD() that understands when we acquire and when we
release the lock.

-Wthread-safety is now only enabled if the compiler is new enough to
understand this pattern. In theory, we could have used some #ifdefs to
keep the existing basic checks on old compilers, but as long as someone
runs a newer compiler (and our CI does), we will catch locking problems,
so it's probably not worth keeping multiple implementations for this.

The implementation can't use g_autoptr any more because the glib macros
define wrapper functions that don't have the right TSA attributes, so
the compiler would complain about them. Just use the cleanup attribute
directly instead.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Message-ID: <20240627181245.281403-3-kwolf@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2024-08-06 20:12:39 +02:00
..
authz
block block/graph-lock: Make WITH_GRAPH_RDLOCK_GUARD() fully checked 2024-08-06 20:12:39 +02:00
chardev chardev/char-fe: Document returned value on error 2024-07-23 22:34:54 +02:00
crypto crypto: propagate errors from TLS session I/O callbacks 2024-07-24 10:39:10 +01:00
disas disas: Fix build against Capstone v6 2024-07-16 18:18:24 +02:00
exec cpu-common.c: export cpu_get_free_index to be reused later 2024-07-26 09:21:06 +10:00
fpu
gdbstub gdbstub: Re-factor gdb command extensions 2024-07-22 09:37:44 +01:00
hw virtio-net: Fix network stall at the host side waiting for kick 2024-08-02 11:09:52 +08:00
io qio: add support for SO_PEERCRED for socket channel 2024-07-22 13:47:41 +02:00
libdecnumber
migration migration: Remove unused VMSTATE_ARRAY_TEST() macro 2024-06-21 14:37:58 -03:00
monitor monitor: Remove obsolete stubs 2024-06-30 19:51:44 +03:00
net net: Remove receive_raw() 2024-06-04 15:14:26 +08:00
qapi include: move typeof_strip_qual to compiler.h, use it in QAPI_LIST_LENGTH() 2024-06-28 14:44:52 +02:00
qemu qemu/osdep: Add excluded fd parameter to qemu_close_all_open_fd() 2024-08-05 08:21:59 +10:00
qom
scsi
semihosting semihosting: Include missing 'gdbstub/syscalls.h' header 2024-07-22 09:38:01 +01:00
standard-headers linux-headers: update to 6.10-rc1 2024-07-01 17:16:04 -04:00
sysemu accel/kvm: Introduce kvm_create_and_park_vcpu() helper 2024-07-26 09:21:06 +10:00
tcg tcg: Introduce TCG_TARGET_HAS_tst_vec 2024-05-22 19:05:21 -07:00
ui ui/console: Remove dpy_cursor_define_supported() 2024-07-16 20:04:08 +02:00
user user: Move 'thunk.h' from 'exec/user' to 'user' 2024-05-03 17:21:20 +02:00
elf.h
glib-compat.h Bump minimum glib version to v2.66 2024-05-14 12:46:24 +02:00
qemu-io.h
qemu-main.h