net/hinic: replace spinlock with mutex
authorZiyang Xuan <xuanziyang2@huawei.com>
Fri, 5 Jul 2019 06:47:47 +0000 (14:47 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 23 Jul 2019 12:31:34 +0000 (14:31 +0200)
commitae865766b334572f114d25c7519984ef8223678f
treedc3dff8aa9e80df153d8e141b15d15d2ffb08a8f
parent520270d5184a9025cf978c4f55307bfe0c3d6e3d
net/hinic: replace spinlock with mutex

Using spin lock to protect critical resources
of sending mgmt messages. This will make high
CPU usage for rte_delay_ms when sending mgmt
messages frequently. We can use mutex to protect
the critical resources and usleep to reduce CPU
usage while keep functioning properly.

Signed-off-by: Ziyang Xuan <xuanziyang2@huawei.com>
drivers/net/hinic/Makefile
drivers/net/hinic/base/hinic_compat.h
drivers/net/hinic/base/hinic_pmd_mgmt.c
drivers/net/hinic/base/hinic_pmd_mgmt.h