]> git.proxmox.com Git - mirror_ovs.git/commit
netdev-dpdk: Refactor construct and destruct.
authorDaniele Di Proietto <diproiettod@vmware.com>
Tue, 15 Nov 2016 23:40:49 +0000 (15:40 -0800)
committerDaniele Di Proietto <diproiettod@vmware.com>
Mon, 16 Jan 2017 03:25:11 +0000 (19:25 -0800)
commit1ce30dfd344e137c1ed716ef82cb7b7b23f04a05
treebf7540122d0ee7617939d1e94b25702e3f13c708
parent7f381c2e5455babf27f634f4ca8e62962460dbc4
netdev-dpdk: Refactor construct and destruct.

Some refactoring for _construct() and _destruct() methods:
* Rename netdev_dpdk_init() to common_construct(). init() has a
  different meaning in the netdev context.
* Remove DPDK_DEV_ETH and DPDK_DEV_VHOST checks in common_construct()
  and move them to different functions
* Introduce common_destruct().
* Avoid taking 'dev->mutex' in construct and destruct: we're guaranteed
  to be the only thread with access to the object.

Signed-off-by: Daniele Di Proietto <diproiettod@vmware.com>
Acked-by: Ilya Maximets <i.maximets@samsung.com>
lib/netdev-dpdk.c