qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Eric Blake <eblake@redhat.com>
To: qemu-devel@nongnu.org
Cc: lbloch@janustech.com, armbru@redhat.com, kwolf@redhat.com,
	qemu-block@nongnu.org, Stefan Weil <sw@weilnetz.de>,
	Max Reitz <mreitz@redhat.com>
Subject: [Qemu-devel] [PATCH v3 3/6] Revert "vdi: Use a literal number of bytes for DEFAULT_CLUSTER_SIZE"
Date: Thu, 10 Jan 2019 13:18:57 -0600	[thread overview]
Message-ID: <20190110191901.5082-4-eblake@redhat.com> (raw)
In-Reply-To: <20190110191901.5082-1-eblake@redhat.com>

This reverts commit 3dd5b8f4718c6ca1eadb16dd67a8cad76455ddb0.

Now that we can express QemuOpts values as an integer, we don't have
to be careful about how we spell our macro.
---
 block/vdi.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/block/vdi.c b/block/vdi.c
index 65659c9b179..180a45b70f6 100644
--- a/block/vdi.c
+++ b/block/vdi.c
@@ -85,7 +85,7 @@
 #define BLOCK_OPT_STATIC "static"

 #define SECTOR_SIZE 512
-#define DEFAULT_CLUSTER_SIZE S_1MiB
+#define DEFAULT_CLUSTER_SIZE (1 * MiB)

 #if defined(CONFIG_VDI_DEBUG)
 #define VDI_DEBUG 1
@@ -432,7 +432,7 @@ static int vdi_open(BlockDriverState *bs, QDict *options, int flags,
         goto fail;
     } else if (header.block_size != DEFAULT_CLUSTER_SIZE) {
         error_setg(errp, "unsupported VDI image (block size %" PRIu32
-                         " is not %" PRIu32 ")",
+                         " is not %" PRIu64 ")",
                    header.block_size, DEFAULT_CLUSTER_SIZE);
         ret = -ENOTSUP;
         goto fail;
-- 
2.20.1

  parent reply	other threads:[~2019-01-10 19:19 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-10 19:18 [Qemu-devel] [PATCH v3 0/6] include: Auto-generate the sizes lookup table Eric Blake
2019-01-10 19:18 ` [Qemu-devel] [PATCH v3 1/6] qemu-option: Allow integer defaults Eric Blake
2019-01-11 14:14   ` Leonid Bloch
2019-01-11 16:23     ` Eric Blake
2019-01-11 18:54       ` Leonid Bloch
2019-01-10 19:18 ` [Qemu-devel] [PATCH v3 2/6] block: Take advantage of QemuOpt default integers Eric Blake
2019-01-11 10:38   ` Kevin Wolf
2019-01-11 16:28     ` Eric Blake
2019-01-10 19:18 ` Eric Blake [this message]
2019-01-10 19:42   ` [Qemu-devel] [PATCH v3 3/6] Revert "vdi: Use a literal number of bytes for DEFAULT_CLUSTER_SIZE" Eric Blake
2019-01-10 19:18 ` [Qemu-devel] [PATCH v3 4/6] qemu: Prefer '(x * MiB)' over 'S_xiB' Eric Blake
2019-01-10 19:18 ` [Qemu-devel] [PATCH v3 5/6] Revert "include: Add a comment to explain the origin of sizes' lookup table" Eric Blake
2019-01-10 19:19 ` [Qemu-devel] [PATCH v3 6/6] Revert "include: Add a lookup table of sizes" Eric Blake
2019-01-10 19:26 ` [Qemu-devel] [Qemu-block] [PATCH v3 0/6] include: Auto-generate the sizes lookup table Eric Blake
2019-01-10 20:21   ` Eric Blake
2019-01-10 20:28     ` Eric Blake
2019-01-11 10:02 ` [Qemu-devel] " Kevin Wolf
2019-01-13 22:50 ` no-reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190110191901.5082-4-eblake@redhat.com \
    --to=eblake@redhat.com \
    --cc=armbru@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=lbloch@janustech.com \
    --cc=mreitz@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=sw@weilnetz.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).