diff options
| author | Paolo Abeni <pabeni@redhat.com> | 2025-07-08 17:54:54 +0200 |
|---|---|---|
| committer | Paolo Abeni <pabeni@redhat.com> | 2025-07-08 18:05:23 +0200 |
| commit | 333c515d189657c934470c9b0b8a8fedb016ce6f (patch) | |
| tree | 96c3e07a5cbbc9a0be9e105f024d5f88f271bdcc /include/uapi/linux/vhost.h | |
| parent | 69b9461512246599ed80cf13358e7e6aff7285f9 (diff) | |
vhost-net: allow configuring extended features
Use the extended feature type for 'acked_features' and implement
two new ioctls operation allowing the user-space to set/query an
unbounded amount of features.
The actual number of processed features is limited by VIRTIO_FEATURES_MAX
and attempts to set features above such limit fail with
EOPNOTSUPP.
Note that: the legacy ioctls implicitly truncate the negotiated
features to the lower 64 bits range and the 'acked_backend_features'
field don't need conversion, as the only negotiated feature there
is in the low 64 bit range.
Acked-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Diffstat (limited to 'include/uapi/linux/vhost.h')
| -rw-r--r-- | include/uapi/linux/vhost.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/uapi/linux/vhost.h b/include/uapi/linux/vhost.h index d4b3e2ae1314..d6ad01fbb8d2 100644 --- a/include/uapi/linux/vhost.h +++ b/include/uapi/linux/vhost.h @@ -235,4 +235,11 @@ */ #define VHOST_VDPA_GET_VRING_SIZE _IOWR(VHOST_VIRTIO, 0x82, \ struct vhost_vring_state) + +/* Extended features manipulation */ +#define VHOST_GET_FEATURES_ARRAY _IOR(VHOST_VIRTIO, 0x83, \ + struct vhost_features_array) +#define VHOST_SET_FEATURES_ARRAY _IOW(VHOST_VIRTIO, 0x83, \ + struct vhost_features_array) + #endif |
