Spdk/test/unit/lib/vhost
Dariusz Stojaczyk d4e19ecc1c vhost: use trylock inside async events body
This makes the async event body non-blocking
and also fixes potential deadlock scenario:
 * call_external_event() enqueues vhost_event
 * destroy_device() locks g_spdk_vhost_mutex
 * destroy_device() enqueues it's vhost_event
 * reactor dequeues events
  * cb from call_external_event is dequeued first
    * g_spdk_vhost_mutex is locked (deadlock)
 * destroy_device() times out, abort()

Change-Id: If8f51ada3ee5c47ba126f74187a40a285c001c77
Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/380634
Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com>
2017-09-28 17:05:34 -04:00
..
vhost_blk.c vhost: sync controller creation with g_spdk_vhost_mutex 2017-09-15 14:18:46 -04:00
vhost_scsi.c rpc/vhost_scsi: defer remove_scsi_dev RPC response 2017-09-22 14:13:40 -04:00
vhost.c vhost: use trylock inside async events body 2017-09-28 17:05:34 -04:00
Makefile ut/vhost: add UT coverage for vhost_blk.c 2017-09-06 18:14:15 -04:00