summaryrefslogtreecommitdiff
path: root/drivers/net/ifc
diff options
context:
space:
mode:
authorXiao Wang <xiao.w.wang@intel.com>2018-12-18 16:01:59 +0800
committerFerruh Yigit <ferruh.yigit@intel.com>2018-12-21 16:22:40 +0100
commit43f34e35663f6fb2b52990cb3fb40f01d7074d1e (patch)
tree18289512d30151ec8798eb59346da90c97fd5291 /drivers/net/ifc
parent02e3b285d447f0745b7e09d1ce9717aad55633e5 (diff)
downloaddpdk-next-eventdev-43f34e35663f6fb2b52990cb3fb40f01d7074d1e.zip
dpdk-next-eventdev-43f34e35663f6fb2b52990cb3fb40f01d7074d1e.tar.gz
dpdk-next-eventdev-43f34e35663f6fb2b52990cb3fb40f01d7074d1e.tar.xz
vhost: provide helper for host notifier ctrl
VDPA driver can decide if it needs to enable/disable the host notifier mapping, so exposing a API can allow flexibility. A later patch will base on this. Signed-off-by: Xiao Wang <xiao.w.wang@intel.com> Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Diffstat (limited to 'drivers/net/ifc')
-rw-r--r--drivers/net/ifc/ifcvf_vdpa.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ifc/ifcvf_vdpa.c b/drivers/net/ifc/ifcvf_vdpa.c
index 97a57f1..e844109 100644
--- a/drivers/net/ifc/ifcvf_vdpa.c
+++ b/drivers/net/ifc/ifcvf_vdpa.c
@@ -556,6 +556,9 @@ ifcvf_dev_config(int vid)
rte_atomic32_set(&internal->dev_attached, 1);
update_datapath(internal);
+ if (rte_vhost_host_notifier_ctrl(vid, true) != 0)
+ DRV_LOG(NOTICE, "vDPA (%d): software relay is used.", did);
+
return 0;
}