ethdev: fix memory ordering for callback functions
authorHonnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Tue, 13 Oct 2020 16:25:37 +0000 (11:25 -0500)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 16 Oct 2020 17:48:18 +0000 (19:48 +0200)
commit2b69bd1179162f69c0a90d5b09309498d362b3d7
treeefe799137cebfe663869e3777e98fe2df5c2fc62
parent8dd4b2afc7b3aabcd364f9638cc7f476d48096ff
ethdev: fix memory ordering for callback functions

Call back functions are registered on the control plane. They
are accessed from the data plane. Hence, correct memory orderings
should be used to avoid race conditions.

Fixes: 4dc294158cac ("ethdev: support optional Rx and Tx callbacks")
Fixes: c8231c63ddcb ("ethdev: insert Rx callback as head of list")
Cc: stable@dpdk.org
Signed-off-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Reviewed-by: Ola Liljedahl <ola.liljedahl@arm.com>
Reviewed-by: Phil Yang <phil.yang@arm.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
lib/librte_ethdev/rte_ethdev.c
lib/librte_ethdev/rte_ethdev.h