From: Stefan Weil <sw@weilnetz.de>
To: Stefan Priebe <s.priebe@profihost.ag>
Cc: Stefan Hajnoczi <stefanha@gmail.com>,
qemu-devel@nongnu.org, pve-devel@pve.proxmox.com,
josh.durgin@inktank.com, pbonzini@redhat.com,
ceph-devel@vger.kernel.org
Subject: Re: [PATCH] use int64_t for return values from rbd instead of int
Date: Wed, 21 Nov 2012 18:03:42 +0100 [thread overview]
Message-ID: <50AD096E.9080002@weilnetz.de> (raw)
In-Reply-To: <1353415495-30561-1-git-send-email-s.priebe@profihost.ag>
Am 20.11.2012 13:44, schrieb Stefan Priebe:
> rbd / rados tends to return pretty often length of writes
> or discarded blocks. These values might be bigger than int.
>
> Signed-off-by: Stefan Priebe <s.priebe@profihost.ag>
> ---
> block/rbd.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/block/rbd.c b/block/rbd.c
> index f57d0c6..6bf9c2e 100644
> --- a/block/rbd.c
> +++ b/block/rbd.c
> @@ -69,7 +69,7 @@ typedef enum {
> typedef struct RBDAIOCB {
> BlockDriverAIOCB common;
> QEMUBH *bh;
> - int ret;
> + int64_t ret;
> QEMUIOVector *qiov;
> char *bounce;
> RBDAIOCmd cmd;
> @@ -87,7 +87,7 @@ typedef struct RADOSCB {
> int done;
> int64_t size;
> char *buf;
> - int ret;
> + int64_t ret;
> } RADOSCB;
>
> #define RBD_FD_READ 0
Why do you use int64_t instead of off_t?
If the value is related to file sizes, off_t would be a good choice.
Stefan W.
WARNING: multiple messages have this Message-ID (diff)
From: Stefan Weil <sw@weilnetz.de>
To: Stefan Priebe <s.priebe@profihost.ag>
Cc: Stefan Hajnoczi <stefanha@gmail.com>,
qemu-devel@nongnu.org, pve-devel@pve.proxmox.com,
josh.durgin@inktank.com, pbonzini@redhat.com,
ceph-devel@vger.kernel.org
Subject: Re: [Qemu-devel] [PATCH] use int64_t for return values from rbd instead of int
Date: Wed, 21 Nov 2012 18:03:42 +0100 [thread overview]
Message-ID: <50AD096E.9080002@weilnetz.de> (raw)
In-Reply-To: <1353415495-30561-1-git-send-email-s.priebe@profihost.ag>
Am 20.11.2012 13:44, schrieb Stefan Priebe:
> rbd / rados tends to return pretty often length of writes
> or discarded blocks. These values might be bigger than int.
>
> Signed-off-by: Stefan Priebe <s.priebe@profihost.ag>
> ---
> block/rbd.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/block/rbd.c b/block/rbd.c
> index f57d0c6..6bf9c2e 100644
> --- a/block/rbd.c
> +++ b/block/rbd.c
> @@ -69,7 +69,7 @@ typedef enum {
> typedef struct RBDAIOCB {
> BlockDriverAIOCB common;
> QEMUBH *bh;
> - int ret;
> + int64_t ret;
> QEMUIOVector *qiov;
> char *bounce;
> RBDAIOCmd cmd;
> @@ -87,7 +87,7 @@ typedef struct RADOSCB {
> int done;
> int64_t size;
> char *buf;
> - int ret;
> + int64_t ret;
> } RADOSCB;
>
> #define RBD_FD_READ 0
Why do you use int64_t instead of off_t?
If the value is related to file sizes, off_t would be a good choice.
Stefan W.
next prev parent reply other threads:[~2012-11-21 17:03 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-20 12:44 [PATCH] use int64_t for return values from rbd instead of int Stefan Priebe
2012-11-20 12:44 ` [Qemu-devel] " Stefan Priebe
2012-11-20 16:29 ` Stefan Hajnoczi
2012-11-20 16:29 ` Stefan Hajnoczi
2012-11-20 19:16 ` Stefan Priebe
2012-11-20 19:16 ` Stefan Priebe
2012-11-21 6:41 ` Stefan Hajnoczi
2012-11-21 6:41 ` Stefan Hajnoczi
2012-11-21 7:47 ` Stefan Priebe - Profihost AG
2012-11-21 7:47 ` Stefan Priebe - Profihost AG
2012-11-21 8:26 ` Stefan Hajnoczi
2012-11-21 8:26 ` Stefan Hajnoczi
[not found] ` <20121121082616.GB13504-lxVrvc10SDTaErKTczak/Dh473NlOPsLVpNB7YpNyf8@public.gmane.org>
2012-11-21 8:33 ` Stefan Priebe - Profihost AG
2012-11-21 8:33 ` Stefan Priebe - Profihost AG
2012-11-21 8:43 ` Stefan Hajnoczi
2012-11-21 8:43 ` Stefan Hajnoczi
2012-11-21 17:03 ` Stefan Weil [this message]
2012-11-21 17:03 ` Stefan Weil
2012-11-21 20:53 ` Stefan Priebe - Profihost AG
2012-11-21 20:53 ` Stefan Priebe - Profihost AG
2012-11-21 22:32 ` Peter Maydell
2012-11-21 22:32 ` [Qemu-devel] " Peter Maydell
[not found] ` <CAFEAcA-cAx88UZRQjHT7uk_oj8P+tXBJ+hb9v0N1Wym8FUMkHQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2012-11-22 8:23 ` Stefan Priebe - Profihost AG
2012-11-22 8:23 ` Stefan Priebe - Profihost AG
2012-11-22 8:40 ` Peter Maydell
2012-11-22 8:40 ` [Qemu-devel] " Peter Maydell
[not found] ` <CAFEAcA86AomWmobTObpw80rMNWM30JzAKqHZXWxmB48+GU3VYQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2012-11-22 9:08 ` Stefan Priebe - Profihost AG
2012-11-22 9:08 ` Stefan Priebe - Profihost AG
-- strict thread matches above, loose matches on Subject: below --
2012-11-21 21:26 Stefan Weil
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=50AD096E.9080002@weilnetz.de \
--to=sw@weilnetz.de \
--cc=ceph-devel@vger.kernel.org \
--cc=josh.durgin@inktank.com \
--cc=pbonzini@redhat.com \
--cc=pve-devel@pve.proxmox.com \
--cc=qemu-devel@nongnu.org \
--cc=s.priebe@profihost.ag \
--cc=stefanha@gmail.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.