[Top][All Lists]

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

Re: [Qemu-devel] [RFC PATCH 1/1] linux-user: Probe the guest base for sh

From: Paul Brook
Subject: Re: [Qemu-devel] [RFC PATCH 1/1] linux-user: Probe the guest base for shared objects when needed
Date: Thu, 28 Jun 2012 01:47:33 +0100
User-agent: KMail/1.13.7 (Linux/3.2.0-2-amd64; KDE/4.8.3; x86_64; ; )

> On 28.06.2012, at 02:06, Paul Brook wrote:
> >>> openSUSE uses a version patched so that IIUC 3G are reserved.
> >>> Just today this failed on a system where swap got disabled and the
> >>> mmap() thus failed.
> >> 
> >> Err... why?  We map with MAP_NORESERVE, so swap shouldn't matter...
> > 
> > I can't say if it's the same cause, but we fail with "ulimit -v 4046848".
> > 
> > Incidentally, it seems a strange that we only reserve 0xf7000000 bytes,
> > not the full 4G.
> Uh, I think that was because of the vdso shared page that is allocated on
> top of -R.

That can't be right.  The whole point of -R is that it defines all the guest 
accessible virtual address space.  The surrounding space is liable to be used 
by something else, and we must not make any assumptions about it.

Further inspection shows that guest_validate_base contains some extremely 
bogus code.

If the guest needs something at the top of its address space then we need to 
offset address zero within the block, and ensure accesses wrap appropriately.


reply via email to

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