]> git.proxmox.com Git - ovs.git/commitdiff
dpif-netdev: Add thread safety annotation to sorted_poll_list.
authorIlya Maximets <i.maximets@samsung.com>
Mon, 11 Feb 2019 17:35:41 +0000 (20:35 +0300)
committerIan Stokes <ian.stokes@intel.com>
Tue, 12 Feb 2019 13:23:09 +0000 (13:23 +0000)
'sorted_poll_list()' uses the 'pmd->poll_list' that should be
guarded by 'pmd->port_mutex'.

Signed-off-by: Ilya Maximets <i.maximets@samsung.com>
Acked-by: Kevin Traynor <ktraynor@redhat.com>
Signed-off-by: Ian Stokes <ian.stokes@intel.com>
lib/dpif-netdev.c

index 0f57e3f8ae95afc241b44b18ac24e962e7736631..481ef50498fd33beeafc76087d25cf0e76de5f55 100644 (file)
@@ -1109,6 +1109,7 @@ compare_poll_list(const void *a_, const void *b_)
 static void
 sorted_poll_list(struct dp_netdev_pmd_thread *pmd, struct rxq_poll **list,
                  size_t *n)
+    OVS_REQUIRES(pmd->port_mutex)
 {
     struct rxq_poll *ret, *poll;
     size_t i;