From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Graham, Simon" Subject: RE: Reducing impact of save/restore/dump on Dom0 Date: Tue, 6 Feb 2007 12:25:53 -0500 Message-ID: <342BAC0A5467384983B586A6B0B3767104A69C0E@EXNA.corp.stratus.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Return-path: Content-class: urn:content-classes:message List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: John Levon Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org Thanks for the comments: >=20 > +#ifndef O_DIRECT > +#define O_DIRECT 040000 > +#endif >=20 > O_DIRECT doesn't exist on Solaris. The closest equivalent is > directio(fd, DIRECTIO_ON). Either way you shouldn't be defining it > yourself? >=20 Well, I would agree with you except that it ends up not being defined when I build on RHEL4/U2! It seems to me that O_DIRECT is something that folks really don't want me to be able to use!=20 Anyone know of a generic mechanism that works everywhere for enabling this? If not, I guess I'll have to add #ifdef's... yuck! What I can do is fix the problem on Linux and make it behave the same old way on everything else (that I can't build/test for)... other people can then add platform specific implementations as needed... > And you should expect this to be able to fail, on Solaris at least. >=20 > + dump_mem_start =3D mmap(0, PAGE_SIZE*DUMP_INCREMENT, > + PROT_READ|PROT_WRITE, > + MAP_PRIVATE|MAP_ANONYMOUS, 0, 0); >=20 > Please use the more portable MAP_ANON. >=20 Will do. Simon