#
06856cab |
| 26-Jan-2021 |
Maxime Coquelin <maxime.coquelin@redhat.com> |
net/virtio: add virtio-user ops to set owner
This patch implements a dedicated callback for sending owner request. All the requests will be converted that way so that backends other than Vhost-user
net/virtio: add virtio-user ops to set owner
This patch implements a dedicated callback for sending owner request. All the requests will be converted that way so that backends other than Vhost-user don't have to work around being it.
Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com> Reviewed-by: Chenbo Xia <chenbo.xia@intel.com>
show more ...
|
#
72f64d10 |
| 26-Jan-2021 |
Maxime Coquelin <maxime.coquelin@redhat.com> |
net/virtio: make vhost-user request sender consistent
This patch makes vhost_user_write() consistent with vhost_user_read(), by passing a Vhost-user message pointer instead of a buffer pointer and i
net/virtio: make vhost-user request sender consistent
This patch makes vhost_user_write() consistent with vhost_user_read(), by passing a Vhost-user message pointer instead of a buffer pointer and its length, which is now calculated in the function.
Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com> Reviewed-by: Chenbo Xia <chenbo.xia@intel.com>
show more ...
|
#
c3243eb5 |
| 18-Dec-2020 |
Olivier Matz <olivier.matz@6wind.com> |
net/virtio-user: fix protocol features advertising
When connected to a vhost-user backend, the flag VHOST_USER_F_PROTOCOL_FEATURES is not advertised, preventing to do multiqueue (the VHOST_USER_PROT
net/virtio-user: fix protocol features advertising
When connected to a vhost-user backend, the flag VHOST_USER_F_PROTOCOL_FEATURES is not advertised, preventing to do multiqueue (the VHOST_USER_PROTOCOL_F_MQ protocol feature is ignored by some backends if the VHOST_USER_F_PROTOCOL_FEATURES feature is not set).
When setting vhost-user features, advertise this flag if it was advertised by our peer.
Fixes: 8e7561054ac7 ("net/virtio: support vhost-user protocol features") Cc: stable@dpdk.org
Suggested-by: Maxime Coquelin <maxime.coquelin@redhat.com> Signed-off-by: Olivier Matz <olivier.matz@6wind.com> Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
show more ...
|
#
5043a060 |
| 26-Oct-2020 |
Adrian Moreno <amorenoz@redhat.com> |
net/virtio-user: ignore result if status is unsupported
GET/SET STATUS is an optional feature, so it may not be negotiated. In that case, the VIRTIO_GET_STATUS call will not update the status (given
net/virtio-user: ignore result if status is unsupported
GET/SET STATUS is an optional feature, so it may not be negotiated. In that case, the VIRTIO_GET_STATUS call will not update the status (given as a pointer argument). Failing to identify this case would lead to undefined behavior as the device status will be updated with the value of a stack-allocated variable.
To fix this, return ENOTSUP if the feature is not supported and, in that case, don't update device status.
Fixes: 44102e6298e7 ("net/virtio: check protocol feature in user backend") Cc stable@dpdk.org
Signed-off-by: Adrian Moreno <amorenoz@redhat.com> Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
show more ...
|
#
0fa6d4c4 |
| 26-Oct-2020 |
Adrian Moreno <amorenoz@redhat.com> |
net/virtio-user: do not assume features are negotiated
According to the virtio spec, ACK and DRIVER status bits should be set before feature negotiation.
However, until the protocol features are ne
net/virtio-user: do not assume features are negotiated
According to the virtio spec, ACK and DRIVER status bits should be set before feature negotiation.
However, until the protocol features are negotiated, the driver does not know if the device actually supports those vhost-user messages. Therefore, until FEATURES_OK is set, the GET/SET_STATUS messages should not be sent.
Fixes: 57912824615f ("net/virtio-user: support vhost status setting") Cc: stable@dpdk.org
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com> Signed-off-by: Adrian Moreno <amorenoz@redhat.com>
show more ...
|
#
44102e62 |
| 29-Sep-2020 |
Maxime Coquelin <maxime.coquelin@redhat.com> |
net/virtio: check protocol feature in user backend
When sending set status message, move protocol feature check to vhost_user to be compatible with different backend types.
Signed-off-by: Maxime Co
net/virtio: check protocol feature in user backend
When sending set status message, move protocol feature check to vhost_user to be compatible with different backend types.
Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com> Reviewed-by: Chenbo Xia <chenbo.xia@intel.com>
show more ...
|
#
0b0dc66c |
| 05-Aug-2020 |
Adrian Moreno <amorenoz@redhat.com> |
net/virtio-user: support vhost status getting
This patch adds support for VHOST_USER_GET_STATUS request.
Only vhost-user backed is supported for now
Signed-off-by: Adrian Moreno <amorenoz@redhat.c
net/virtio-user: support vhost status getting
This patch adds support for VHOST_USER_GET_STATUS request.
Only vhost-user backed is supported for now
Signed-off-by: Adrian Moreno <amorenoz@redhat.com> Reviewed-by: Chenbo Xia <chenbo.xia@intel.com>
show more ...
|
#
57912824 |
| 05-Aug-2020 |
Maxime Coquelin <maxime.coquelin@redhat.com> |
net/virtio-user: support vhost status setting
This patch adds support for VHOST_USER_SET_STATUS request. It is used to make the backend aware of Virtio devices status update.
It is useful for the b
net/virtio-user: support vhost status setting
This patch adds support for VHOST_USER_SET_STATUS request. It is used to make the backend aware of Virtio devices status update.
It is useful for the backend to know when the Virtio driver is done with the Virtio device configuration.
Reviewed-by: Chenbo Xia <chenbo.xia@intel.com> Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com> Signed-off-by: Adrian Moreno <amorenoz@redhat.com>
show more ...
|
#
f4c1456a |
| 14-Jul-2020 |
Chenbo Xia <chenbo.xia@intel.com> |
net/virtio-user: fix uninitialized reply-ack variable
This patch fixes an issue that uninitialized has_reply_ack is used for setting message flags.
Coverity issue: 360834 Fixes: c60208dd6384 ("net/
net/virtio-user: fix uninitialized reply-ack variable
This patch fixes an issue that uninitialized has_reply_ack is used for setting message flags.
Coverity issue: 360834 Fixes: c60208dd6384 ("net/virtio-user: support reply-ack")
Signed-off-by: Chenbo Xia <chenbo.xia@intel.com> Acked-by: Adrian Moreno <amorenoz@redhat.com>
show more ...
|
#
c60208dd |
| 03-Jul-2020 |
Maxime Coquelin <maxime.coquelin@redhat.com> |
net/virtio-user: support reply-ack
This patch adds support reply-ack vhost-user protocol feature, which is for now only used to ensure VHOST_USER_SET_MEM_TABLE requests are handled by the slave, but
net/virtio-user: support reply-ack
This patch adds support reply-ack vhost-user protocol feature, which is for now only used to ensure VHOST_USER_SET_MEM_TABLE requests are handled by the slave, but later will be used for VHOST_USER_SET_STATUS.
Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com> Reviewed-by: Chenbo Xia <chenbo.xia@intel.com>
show more ...
|
#
8e756105 |
| 03-Jul-2020 |
Maxime Coquelin <maxime.coquelin@redhat.com> |
net/virtio: support vhost-user protocol features
This patch adds support for Vhost-user protocol features. It is required to support protocol features that were not in initial Vhost-user specificati
net/virtio: support vhost-user protocol features
This patch adds support for Vhost-user protocol features. It is required to support protocol features that were not in initial Vhost-user specification, such as reply-ack, MTU...
Also, this patch prevents Virtio multiqueue feature negotiation if the slave does not support MQ protocol feature as stated in Vhost-user specification: "The multiple queues feature is supported only when the protocol feature ``VHOST_USER_PROTOCOL_F_MQ`` (bit 0) is set."
Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com> Reviewed-by: Chenbo Xia <chenbo.xia@intel.com>
show more ...
|
#
ef5baf34 |
| 09-Feb-2020 |
Thomas Monjalon <thomas@monjalon.net> |
replace packed attributes
There is a common macro __rte_packed for packing structs, which is now used where appropriate for consistency.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
|
#
47ac9661 |
| 25-Nov-2019 |
Tiwei Bie <tiwei.bie@intel.com> |
net/virtio-user: do not close tap when disabling queue pairs
Do not close the tap fds when disabling queue pairs, instead, we just need to unbind the backend. Otherwise, tap port can be destroyed un
net/virtio-user: do not close tap when disabling queue pairs
Do not close the tap fds when disabling queue pairs, instead, we just need to unbind the backend. Otherwise, tap port can be destroyed unexpectedly.
Fixes: e3b434818bbb ("net/virtio-user: support kernel vhost") Cc: stable@dpdk.org
Reported-by: Stephen Hemminger <stephen@networkplumber.org> Signed-off-by: Tiwei Bie <tiwei.bie@intel.com> Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
show more ...
|
#
8ac35916 |
| 12-Aug-2019 |
David Marchand <david.marchand@redhat.com> |
remove useless include of EAL memory config header
Restrict this header inclusion to its real users.
Fixes: 028669bc9f0d ("eal: hide shared memory config") Cc: stable@dpdk.org
Signed-off-by: David
remove useless include of EAL memory config header
Restrict this header inclusion to its real users.
Fixes: 028669bc9f0d ("eal: hide shared memory config") Cc: stable@dpdk.org
Signed-off-by: David Marchand <david.marchand@redhat.com> Acked-by: Anatoly Burakov <anatoly.burakov@intel.com>
show more ...
|
#
1e986888 |
| 10-Apr-2019 |
Chenbo Xia <chenbo.xia@intel.com> |
net/virtio-user: fix return value check
Fix unchecked return value for fcntl.
Coverity issue: 277210 Fixes: bd8f50a45d0f ("net/virtio-user: support server mode") Cc: stable@dpdk.org
Signed-off-by:
net/virtio-user: fix return value check
Fix unchecked return value for fcntl.
Coverity issue: 277210 Fixes: bd8f50a45d0f ("net/virtio-user: support server mode") Cc: stable@dpdk.org
Signed-off-by: Chenbo Xia <chenbo.xia@intel.com> Acked-by: Rami Rosen <ramirose@gmail.com> Reviewed-by: Jens Freimann <jfreimann@redhat.com> Reviewed-by: Tiwei Bie <tiwei.bie@intel.com>
show more ...
|
#
6723c0fc |
| 03-Apr-2019 |
Bruce Richardson <bruce.richardson@intel.com> |
replace snprintf with strlcpy
Do a global replace of snprintf(..."%s",...) with strlcpy, adding in the rte_string_fns.h header if needed. The function changes in this patch were auto-generated via
replace snprintf with strlcpy
Do a global replace of snprintf(..."%s",...) with strlcpy, adding in the rte_string_fns.h header if needed. The function changes in this patch were auto-generated via command:
spatch --sp-file devtools/cocci/strlcpy.cocci --dir . --in-place
and then the files edited using awk to add in the missing header:
gawk -i inplace '/include <rte_/ && ! seen { \ print "#include <rte_string_fns.h>"; seen=1} {print}'
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
show more ...
|
#
520dd992 |
| 28-Oct-2018 |
Ferruh Yigit <ferruh.yigit@intel.com> |
drivers: prefix global variables with module name
Some global variables are defined with generic names, add component name as prefix to variables to prevent collusion with application variables.
Si
drivers: prefix global variables with module name
Some global variables are defined with generic names, add component name as prefix to variables to prevent collusion with application variables.
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com> Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com> Acked-by: Shreyansh Jain <shreyansh.jain@nxp.com> Acked-by: Tianfei Zhang <tianfei.zhang@intel.com>
show more ...
|
#
534bccba |
| 05-Sep-2018 |
Tiwei Bie <tiwei.bie@intel.com> |
net/virtio-user: avoid parsing process mappings
Recently some memory APIs were introduced to allow users to get the file descriptor and offset for each memory segment. We can leverage those APIs to
net/virtio-user: avoid parsing process mappings
Recently some memory APIs were introduced to allow users to get the file descriptor and offset for each memory segment. We can leverage those APIs to get rid of the /proc magic on memory table preparation in vhost-user backend.
Signed-off-by: Tiwei Bie <tiwei.bie@intel.com> Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
show more ...
|
#
201a4165 |
| 11-May-2018 |
Zhiyong Yang <zhiyong.yang@intel.com> |
net/virtio-user: fix multiple queues fail in server mode
This patch fixes multiple queues failure when virtio-user works in server mode.
This patch adds feature negotiation in the processing of vir
net/virtio-user: fix multiple queues fail in server mode
This patch fixes multiple queues failure when virtio-user works in server mode.
This patch adds feature negotiation in the processing of virtio-user connection and enables multiple-queue pairs.
Fixes: bd8f50a45d0f ("net/virtio-user: support server mode") Cc: stable@dpdk.org
Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com> Reviewed-by: Tiwei Bie <tiwei.bie@intel.com>
show more ...
|
#
169a9da6 |
| 26-Apr-2018 |
Jianfeng Tan <jianfeng.tan@intel.com> |
net/virtio-user: fix hugepage files enumeration
After the commit 2a04139f66b4 ("eal: add single file segments option"), one hugepage file could contain multiple hugepages which are further mapped to
net/virtio-user: fix hugepage files enumeration
After the commit 2a04139f66b4 ("eal: add single file segments option"), one hugepage file could contain multiple hugepages which are further mapped to different memory regions.
Original enumeration implementation cannot handle this situation.
This patch filters out the duplicated files; and adjust the size after the enumeration.
Fixes: 6a84c37e3975 ("net/virtio-user: add vhost-user adapter layer")
Signed-off-by: Jianfeng Tan <jianfeng.tan@intel.com> Acked-by: Maxime Coquelin <maxime.coquelin@redhat.com>
show more ...
|
#
bd8f50a4 |
| 06-Apr-2018 |
Zhiyong Yang <zhiyong.yang@intel.com> |
net/virtio-user: support server mode
In a container environment if the vhost-user backend restarts, there's no way for it to reconnect to virtio-user. To address this, support for server mode is add
net/virtio-user: support server mode
In a container environment if the vhost-user backend restarts, there's no way for it to reconnect to virtio-user. To address this, support for server mode is added. In this mode the socket file is created by virtio- user, which the backend then connects to. This means that if the backend restarts, it can reconnect to virtio-user and continue communications.
With current implementation, LSC is enabled at virtio-user side to support to accept the coming connection.
Server mode virtio-user only supports to work with vhost-user.
Release note is updated in this patch.
Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com> Reviewed-by: Jianfeng Tan <jianfeng.tan@intel.com>
show more ...
|
#
5566a3e3 |
| 19-Dec-2017 |
Bruce Richardson <bruce.richardson@intel.com> |
drivers: use SPDX tag for Intel copyright files
Replace the BSD license header with the SPDX tag for files with only an Intel copyright on them.
Signed-off-by: Bruce Richardson <bruce.richardson@in
drivers: use SPDX tag for Intel copyright files
Replace the BSD license header with the SPDX tag for files with only an Intel copyright on them.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
show more ...
|
#
7b3249c5 |
| 22-Sep-2017 |
Daniel Mrzyglod <danielx.t.mrzyglod@intel.com> |
net/virtio: fix untrusted scalar value
The unscrutinized value may be incorrectly assumed to be within a certain range by later operations.
In vhost_user_read: An unscrutinized value from an untrus
net/virtio: fix untrusted scalar value
The unscrutinized value may be incorrectly assumed to be within a certain range by later operations.
In vhost_user_read: An unscrutinized value from an untrusted source used in a trusted context - the value of sz_payload may be harmfull and we need limit them to the max value of payload.
Coverity issue: 139601 Fixes: 6a84c37e3975 ("net/virtio-user: add vhost-user adapter layer") Cc: stable@dpdk.org
Signed-off-by: Daniel Mrzyglod <danielx.t.mrzyglod@intel.com> Acked-by: Jianfeng Tan <jianfeng.tan@intel.com> Acked-by: Yuanhan Liu <yliu@fridaylinux.org>
show more ...
|
#
33d24d65 |
| 13-Jan-2017 |
Jianfeng Tan <jianfeng.tan@intel.com> |
net/virtio-user: abstract backend operations
Add a struct virtio_user_backend_ops to abstract three kinds of backend operations: - setup, create the unix socket connection; - send_request, sync
net/virtio-user: abstract backend operations
Add a struct virtio_user_backend_ops to abstract three kinds of backend operations: - setup, create the unix socket connection; - send_request, sync messages with backend; - enable_qp, enable some queue pair.
Signed-off-by: Jianfeng Tan <jianfeng.tan@intel.com> Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
show more ...
|
#
5526b0cb |
| 13-Jan-2017 |
Jianfeng Tan <jianfeng.tan@intel.com> |
net/virtio-user: move vhost-user specific code
To support vhost kernel as the backend of net_virtio_user in coming patches, we move vhost_user specific structs and macros into vhost_user.c, and only
net/virtio-user: move vhost-user specific code
To support vhost kernel as the backend of net_virtio_user in coming patches, we move vhost_user specific structs and macros into vhost_user.c, and only keep common definitions in vhost.h.
Besides, remove VHOST_USER_MQ feature check.
Signed-off-by: Jianfeng Tan <jianfeng.tan@intel.com> Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
show more ...
|