qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 1/2] Add "directio" parameter to "-drive"


From: Samuel Thibault
Subject: Re: [Qemu-devel] [PATCH 1/2] Add "directio" parameter to "-drive"
Date: Wed, 28 Nov 2007 15:08:07 +0000
User-agent: Mutt/1.5.12-2006-07-14

Laurent Vivier, le Wed 28 Nov 2007 16:00:17 +0100, a écrit :
> Le mercredi 28 novembre 2007 à 14:24 +0000, Samuel Thibault a écrit :
> > Laurent Vivier, le Wed 28 Nov 2007 15:02:50 +0100, a écrit :
> > > +    ret = posix_memalign((void**)&buf, 0x200, 512);
> > 
> > For making this more easily portable, maybe it should be a new
> > qemu_memalign() function?  Also, the alignment may probably be better as
> > a global macro, since the alignment requirements depend on the OS.
> 
> I think O_DIRECT is linux specific

Yes.

> whereas posix_memalign() is part of POSIX specification.

Yes, but not so many systems have it.

> And the memory alignement should only needed by the implemetation of
> O_DIRECT on linux.

IIRC it is also required e.g. by the equivalent raw devices of Solaris.
It happens that I also need it for the Xen stubdomains support :)

Samuel




reply via email to

[Prev in Thread] Current Thread [Next in Thread]