On Mon, Jan 24, 2011 at 15:58, Stefano Bonifazi wrote: >> review the mmap() man page ... MAP_FIXED is always a *suggestion* and >> never a requirement. the app must check the return value to see what >> the kernel actually gave it. > > Sorry, wrong! > > MAP_FIXED > Don't interpret addr as a hint: place the mapping at exactly > that > address. [] If the specified address cannot be used, mmap() > will fail.[]
err, yes. i was thinking the specified address when MAP_FIXED isnt used. since qemu itself has its own mappings, there is a slightly greater possibility of the simulated program making a MAP_FIXED request that clashes with qemu itself, or with addresses that are free in the simulated arch's ABI but reserved in the host processor's ABI. but that can happen with the app running natively too, so any app not handling MAP_FIXED failures is buggy and not qemu's problem. -mike