Re: [PATCH v2 27/39] util/log: Introduce qemu_set_log_filename_flags

2022-04-14 Thread Richard Henderson
On 4/14/22 07:56, Alex Bennée wrote: #ifdef CONFIG_TRACE_LOG -qemu_loglevel |= LOG_TRACE; +log_flags |= LOG_TRACE; #endif +qemu_loglevel = log_flags; + This looked weird - so should we consider a qatomic_set here to avoid an inconsistent set of flags being read non-atomically el

Re: [PATCH v2 27/39] util/log: Introduce qemu_set_log_filename_flags

2022-04-14 Thread Alex Bennée
Richard Henderson writes: > Provide a function to set both filename and flags at > the same time. This is the common case at startup. > > Signed-off-by: Richard Henderson > --- > v2: Return bool, per recommendations in qapi/error.h (phil). > --- > include/qemu/log.h | 1 + > util/log.c

[PATCH v2 27/39] util/log: Introduce qemu_set_log_filename_flags

2022-03-26 Thread Richard Henderson
Provide a function to set both filename and flags at the same time. This is the common case at startup. Signed-off-by: Richard Henderson --- v2: Return bool, per recommendations in qapi/error.h (phil). --- include/qemu/log.h | 1 + util/log.c | 122