Skip to content

Commit

Permalink
rcu_queue: remove barrier from QLIST_EMPTY_RCU
Browse files Browse the repository at this point in the history
It's unnecessary because the pointer isn't dereferenced.

Signed-off-by: Emilio G. Cota <cota@braap.org>
Message-Id: <20180819091335.22863-3-cota@braap.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
  • Loading branch information
cota authored and bonzini committed Aug 23, 2018
1 parent c177e0b commit 735d1af
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/qemu/rcu_queue.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ extern "C" {
/*
* List access methods.
*/
#define QLIST_EMPTY_RCU(head) (atomic_rcu_read(&(head)->lh_first) == NULL)
#define QLIST_EMPTY_RCU(head) (atomic_read(&(head)->lh_first) == NULL)
#define QLIST_FIRST_RCU(head) (atomic_rcu_read(&(head)->lh_first))
#define QLIST_NEXT_RCU(elm, field) (atomic_rcu_read(&(elm)->field.le_next))

Expand Down

0 comments on commit 735d1af

Please sign in to comment.