Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/pci virtio(4): Use __BIT, not inline shift.
details: https://anonhg.NetBSD.org/src/rev/cc8a5b084591
branches: trunk
changeset: 371889:cc8a5b084591
user: riastradh <riastradh%NetBSD.org@localhost>
date: Sat Oct 15 20:00:35 2022 +0000
description:
virtio(4): Use __BIT, not inline shift.
Reduces need for cast.
diffstat:
sys/dev/pci/virtioreg.h | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diffs (26 lines):
diff -r 33299f0a138f -r cc8a5b084591 sys/dev/pci/virtioreg.h
--- a/sys/dev/pci/virtioreg.h Sat Oct 15 19:55:37 2022 +0000
+++ b/sys/dev/pci/virtioreg.h Sat Oct 15 20:00:35 2022 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: virtioreg.h,v 1.10 2022/04/13 10:56:11 uwe Exp $ */
+/* $NetBSD: virtioreg.h,v 1.11 2022/10/15 20:00:35 riastradh Exp $ */
/*
* Copyright (c) 2010 Minoura Makoto.
@@ -79,11 +79,11 @@
#define VIRTIO_DEVICE_ID_9P 9
/* common device/guest features */
-#define VIRTIO_F_NOTIFY_ON_EMPTY (1<<24)
-#define VIRTIO_F_RING_INDIRECT_DESC (1<<28)
-#define VIRTIO_F_RING_EVENT_IDX (1<<29)
-#define VIRTIO_F_BAD_FEATURE (1<<30)
-#define VIRTIO_F_VERSION_1 (UINT64_C(1) << 32)
+#define VIRTIO_F_NOTIFY_ON_EMPTY __BIT(24)
+#define VIRTIO_F_RING_INDIRECT_DESC __BIT(28)
+#define VIRTIO_F_RING_EVENT_IDX __BIT(29)
+#define VIRTIO_F_BAD_FEATURE __BIT(30)
+#define VIRTIO_F_VERSION_1 __BIT(32)
/* common device status flags */
#define VIRTIO_CONFIG_DEVICE_STATUS_RESET 0
Home |
Main Index |
Thread Index |
Old Index