tb-maint: do not use mb_read/mb_set
authorPaolo Bonzini <pbonzini@redhat.com>
Fri, 3 Mar 2023 12:12:50 +0000 (13:12 +0100)
committerPaolo Bonzini <pbonzini@redhat.com>
Mon, 8 May 2023 09:10:49 +0000 (11:10 +0200)
commit20f46806b3858b92e9d1b5cf586558d62bd5a913
tree757482ed7bbfd33e45d60bda5952127fed0ccc04
parent8f593ba9c5c96b1790cc6aceb95b5b83bbac92cd
tb-maint: do not use mb_read/mb_set

The load side can use a relaxed load, which will surely happen before
the work item is run by async_safe_run_on_cpu() or before double-checking
under mmap_lock.  The store side can use an atomic RMW operation.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
accel/tcg/tb-maint.c