qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Gerd Hoffmann <kraxel@redhat.com>
To: Blue Swirl <blauwirbel@gmail.com>
Cc: xen-devel@lists.xensource.com, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 5/7] xen: add block device backend driver.
Date: Mon, 04 Aug 2008 21:50:50 +0200	[thread overview]
Message-ID: <48975D9A.7070109@redhat.com> (raw)
In-Reply-To: <f43fc5580808041026t49c8962fhe6ef926608e3db6c@mail.gmail.com>

Blue Swirl wrote:
> On 8/4/08, Gerd Hoffmann <kraxel@redhat.com> wrote:
>>  +/* i386 protocol version */
>>  +#pragma pack(push, 4)
> 
> What's wrong with __attribute__(__aligned__)?

That one is tricky because we must be binary compatible with xen.  And
the block driver protocol has a small design flaw:  It has a 64bit value
 which is not aligned on a 64bit border.  This leads to different struct
layouts on i386 and x86_64 due to different alignment rules.  Unless you
force them into something else, like we do in that header file to deal
with it.  Which is needed to run 32bit guests on 64bit hosts.

>>  +    RING_PUSH_RESPONSES_AND_CHECK_NOTIFY(&blkdev->rings.common, send_notify);
> 
> EUGLY_LONG_NAME_WITH_ALL_CAPS

Xen API, no way around that, sorry.

>>  +       mode   = O_RDONLY;
>>  +       qflags = BDRV_O_RDONLY;
>>  +       info  |= VDISK_READONLY | VDISK_REMOVABLE | VDISK_CDROM;
> 
> Does this mean that all read-only disks are assumed to be CDROMs or
> that all removable disks are read-only?

I'll double-check, but I think there is no media=[disk|cdrom] indicator
in xenstore.  So that was the best I could come up with ...

> Why IF_XEN?

I've seen you've noticed meanwhile in patch #7 ;)

> Why different protocols for i386 and x86_64?

See above.

> Would I need to add
> Sparc32 and Sparc64 versions some day?

Not sure whenever the same 32/64bit ABI issue exists on sparc.  If so,
the code handling this on x86 should work for sparc too.

cheers,
  Gerd

-- 
http://kraxel.fedorapeople.org/xenner/

  parent reply	other threads:[~2008-08-04 19:51 UTC|newest]

Thread overview: 94+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-04 15:50 [Qemu-devel] [PATCH 0/7] merge some xen bits into qemu Gerd Hoffmann
2008-08-04 15:50 ` [Qemu-devel] [PATCH 1/7] xen: groundwork for xen support Gerd Hoffmann
2008-08-04 16:34   ` Blue Swirl
2008-08-04 18:01     ` Gerd Hoffmann
2008-08-04 17:35   ` Anthony Liguori
2008-08-04 18:04     ` Gerd Hoffmann
2008-08-04 15:50 ` [Qemu-devel] [PATCH 2/7] xen: backend driver core Gerd Hoffmann
2008-08-04 15:50 ` [Qemu-devel] [PATCH 3/7] xen: add console backend driver Gerd Hoffmann
2008-08-04 16:52   ` Blue Swirl
2008-08-04 18:15     ` Gerd Hoffmann
2008-08-04 20:47       ` Blue Swirl
2008-08-04 15:50 ` [Qemu-devel] [PATCH 4/7] xen: add framebuffer " Gerd Hoffmann
2008-08-04 17:09   ` Blue Swirl
2008-08-04 18:20     ` Gerd Hoffmann
2008-08-04 15:50 ` [Qemu-devel] [PATCH 5/7] xen: add block device " Gerd Hoffmann
2008-08-04 17:26   ` Blue Swirl
2008-08-04 17:37     ` Samuel Thibault
2008-08-04 17:46     ` Anthony Liguori
2008-08-04 19:50     ` Gerd Hoffmann [this message]
2008-08-04 20:04       ` Paul Brook
2008-08-05  7:18         ` Gerd Hoffmann
2008-08-04 20:58       ` Blue Swirl
2008-08-05  7:01         ` Gerd Hoffmann
2008-08-04 21:34       ` [Xen-devel] " Samuel Thibault
2008-08-05  6:52         ` Gerd Hoffmann
2008-08-05 10:47           ` Samuel Thibault
2008-08-05 11:07             ` Gerd Hoffmann
2008-08-05 11:36               ` Samuel Thibault
2008-08-04 15:50 ` [Qemu-devel] [PATCH 6/7] xen: add net " Gerd Hoffmann
2008-08-04 15:50 ` [Qemu-devel] [PATCH 7/7] xen: blk & nic configuration via cmd line Gerd Hoffmann
2008-08-04 17:35   ` Blue Swirl
2008-08-04 18:12     ` Gerd Hoffmann
2008-08-04 20:45       ` Blue Swirl
2008-08-04 17:42 ` [Qemu-devel] [PATCH 0/7] merge some xen bits into qemu Anthony Liguori
2008-08-05  9:58   ` Gerd Hoffmann
2008-08-05 10:15     ` Samuel Thibault
2008-08-05 10:46   ` Samuel Thibault
2008-08-05 11:12     ` Gerd Hoffmann
2008-08-05 11:29       ` Samuel Thibault
2008-08-05 13:18         ` Gerd Hoffmann
2008-08-05 15:03           ` Samuel Thibault
2008-08-05 15:41             ` Samuel Thibault
2008-08-05 15:46               ` Anthony Liguori
2008-08-05 16:07                 ` Blue Swirl
2008-08-05 15:47               ` Samuel Thibault
2008-08-06 10:14               ` Gerd Hoffmann
2008-08-06 10:23                 ` Samuel Thibault
2008-08-06 12:43                   ` [Xen-devel] " Markus Armbruster
2008-08-06 12:50                     ` Samuel Thibault
2008-08-06 13:54                       ` Gerd Hoffmann
2008-08-06 14:01                         ` Samuel Thibault
2008-08-06 14:08                           ` Gerd Hoffmann
2008-08-06 14:25                             ` Samuel Thibault
2008-08-06 15:35                               ` Gerd Hoffmann
2008-08-06 15:47                                 ` Samuel Thibault
2008-08-06 22:10                                   ` Gerd Hoffmann
2008-08-06 22:16                                     ` Samuel Thibault
2008-08-06 16:01                                 ` Laurent Vivier
2008-08-06 22:10                               ` Samuel Thibault
2008-08-07  7:33                                 ` Gerd Hoffmann
2008-08-07 10:53                                   ` Samuel Thibault
2008-08-07 12:13                                     ` Gerd Hoffmann
2008-08-07 12:54                                       ` Samuel Thibault
2008-08-07 16:17                                         ` Gerd Hoffmann
2008-08-07 16:48                                           ` Samuel Thibault
2008-08-07 16:54                                             ` Samuel Thibault
2008-08-07 16:09                                       ` Samuel Thibault
2008-08-07 16:34                                       ` Samuel Thibault
2008-08-11  8:16                                         ` Gerd Hoffmann
2008-08-11  9:23                                           ` Stefano Stabellini
2008-08-11 10:12                                       ` Ian Jackson
2008-08-07 15:06                                   ` Blue Swirl
2008-08-07 15:13                                     ` Samuel Thibault
2008-08-07 15:13                                     ` Samuel Thibault
2008-08-07 15:21                                     ` Gerd Hoffmann
2008-08-08 15:24                                       ` Blue Swirl
2008-08-11 12:46                                         ` Gerd Hoffmann
2008-08-11 18:53                                           ` Blue Swirl
2008-08-08 11:03                                     ` Samuel Thibault
2008-08-07 17:40                         ` Stefano Stabellini
2008-08-11  9:18                         ` Ian Jackson
2008-08-11 11:08                           ` Gerd Hoffmann
2008-08-06 13:24                   ` Gerd Hoffmann
2008-08-06 13:39                     ` Samuel Thibault
2008-08-06 14:18                       ` Gerd Hoffmann
2008-08-06 14:51                         ` Samuel Thibault
2008-08-06 15:25                           ` Gerd Hoffmann
2008-08-11 16:36   ` [Qemu-devel] Xen's qemu branches, etc Ian Jackson
2008-08-11 16:48     ` [Qemu-devel] Re: [Xen-devel] " Samuel Thibault
2008-08-11 19:17     ` [Qemu-devel] " Anthony Liguori
2008-08-11 19:34     ` [Qemu-devel] " Gerd Hoffmann
  -- strict thread matches above, loose matches on Subject: below --
2008-10-28 12:23 [Qemu-devel] [PATCH 0/7] merge some xen bits into qemu Gerd Hoffmann
2008-10-28 12:23 ` [Qemu-devel] [PATCH 5/7] xen: add block device backend driver Gerd Hoffmann
2008-07-28 13:17 [Qemu-devel] [PATCH 0/7] merge some xen bits into qemu Gerd Hoffmann
2008-07-28 13:17 ` [Qemu-devel] [PATCH 5/7] xen: add block device backend driver Gerd Hoffmann
2008-07-28 14:25   ` Anthony Liguori

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=48975D9A.7070109@redhat.com \
    --to=kraxel@redhat.com \
    --cc=blauwirbel@gmail.com \
    --cc=qemu-devel@nongnu.org \
    --cc=xen-devel@lists.xensource.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 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).