lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Mon, 7 Feb 2022 14:55:36 +0200
From:   Eli Cohen <elic@...dia.com>
To:     <stephen@...workplumber.org>, <netdev@...r.kernel.org>
CC:     <jasowang@...hat.com>, <si-wei.liu@...cle.com>,
        Eli Cohen <elic@...dia.com>, Jianbo Liu <jianbol@...dia.com>
Subject: [PATCH 2/3] virtio: Define bit numbers for device independent features

Define bit fields for device independent feature bits. We need them in a
follow up patch.

Also, define macros for start and end of these feature bits.

Reviewed-by: Jianbo Liu <jianbol@...dia.com>
Signed-off-by: Eli Cohen <elic@...dia.com>
---
 include/uapi/linux/virtio_config.h | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/include/uapi/linux/virtio_config.h b/include/uapi/linux/virtio_config.h
index 3bf6c8bf8477..6d92cc31a8d3 100644
--- a/include/uapi/linux/virtio_config.h
+++ b/include/uapi/linux/virtio_config.h
@@ -45,14 +45,14 @@
 /* We've given up on this device. */
 #define VIRTIO_CONFIG_S_FAILED		0x80
 
-/*
- * Virtio feature bits VIRTIO_TRANSPORT_F_START through
- * VIRTIO_TRANSPORT_F_END are reserved for the transport
- * being used (e.g. virtio_ring, virtio_pci etc.), the
- * rest are per-device feature bits.
- */
-#define VIRTIO_TRANSPORT_F_START	28
-#define VIRTIO_TRANSPORT_F_END		38
+/* Device independent features per virtio spec 1.1 range from 28 to 38 */
+#define VIRTIO_DEV_INDEPENDENT_F_START 28
+#define VIRTIO_DEV_INDEPENDENT_F_END   38
+
+#define VIRTIO_F_RING_INDIRECT_DESC 28
+#define VIRTIO_F_RING_EVENT_IDX 29
+#define VIRTIO_F_IN_ORDER 35
+#define VIRTIO_F_NOTIFICATION_DATA 38
 
 #ifndef VIRTIO_CONFIG_NO_LEGACY
 /* Do we get callbacks when the ring is completely used, even if we've
-- 
2.34.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ