[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-trivial] [PATCH v4 38/40] hw/virtio: Use the IEC binary prefix def
From: |
Philippe Mathieu-Daudé |
Subject: |
[Qemu-trivial] [PATCH v4 38/40] hw/virtio: Use the IEC binary prefix definitions |
Date: |
Sun, 10 Jun 2018 22:14:59 -0300 |
It eases code review, unit is explicit.
Patch generated using:
$ git grep -E '(1024|2048|4096|8192|(<<|>>).?(10|20|30))' hw/ include/hw/
and modified manually.
Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
---
include/hw/virtio/virtio-net.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/include/hw/virtio/virtio-net.h b/include/hw/virtio/virtio-net.h
index 02484dc94c..4d7f3c82ca 100644
--- a/include/hw/virtio/virtio-net.h
+++ b/include/hw/virtio/virtio-net.h
@@ -14,6 +14,7 @@
#ifndef QEMU_VIRTIO_NET_H
#define QEMU_VIRTIO_NET_H
+#include "qemu/units.h"
#include "standard-headers/linux/virtio_net.h"
#include "hw/virtio/virtio.h"
@@ -44,7 +45,7 @@ typedef struct virtio_net_conf
} virtio_net_conf;
/* Maximum packet size we can receive from tap device: header + 64k */
-#define VIRTIO_NET_MAX_BUFSIZE (sizeof(struct virtio_net_hdr) + (64 << 10))
+#define VIRTIO_NET_MAX_BUFSIZE (sizeof(struct virtio_net_hdr) + (64 * KiB))
typedef struct VirtIONetQueue {
VirtQueue *rx_vq;
--
2.17.1
- [Qemu-trivial] [PATCH v4 29/40] hw/mips/r4k: Constify params_size, (continued)
- [Qemu-trivial] [PATCH v4 29/40] hw/mips/r4k: Constify params_size, Philippe Mathieu-Daudé, 2018/06/10
- [Qemu-trivial] [PATCH v4 30/40] hw/mips: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/10
- [Qemu-trivial] [PATCH v4 32/40] hw/ppc: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/10
- [Qemu-trivial] [PATCH v4 34/40] hw/net: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/10
- [Qemu-trivial] [PATCH v4 35/40] hw/usb: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/10
- [Qemu-trivial] [PATCH v4 36/40] hw/sd: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/10
- [Qemu-trivial] [PATCH v4 37/40] hw/vfio: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/10
- [Qemu-trivial] [PATCH v4 38/40] hw/virtio: Use the IEC binary prefix definitions,
Philippe Mathieu-Daudé <=
- [Qemu-trivial] [PATCH v4 39/40] hw/rdma: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/10
- [Qemu-trivial] [PATCH v4 40/40] cutils: Do not include "qemu/units.h" directly, Philippe Mathieu-Daudé, 2018/06/10
- Message not available
- Re: [Qemu-trivial] [PATCH v4 00/40] Use the IEC binary prefix definitions, Michael S. Tsirkin, 2018/06/11
- Re: [Qemu-trivial] [PATCH v4 00/40] Use the IEC binary prefix definitions, Eric Blake, 2018/06/11
- Re: [Qemu-trivial] [PATCH v4 00/40] Use the IEC binary prefix definitions, Cornelia Huck, 2018/06/11