Re: The MAX high_addr for `mmap` on PPC64

From
David Gibson <hidden>
Date
2012-08-29 03:42:58
Reply to
madper, 2012-08-29
On Wed, Aug 29, 2012 at 11:34:08AM +0800, madper wrote:
Hi every one,
    I use the ltp (Linux-Test-Project) and run it on both ppc64 and x86_64.
    There is a code like follows in
`ltp/testcase/kernel/mem/hugetbl/hugemmap/hugemmap03.c`:
`code`
        #define HIGH_ADDR       (void *)(0x1000000000000)
	/* Attempt to mmap into highmem addr, should get ENOMEM */
	addr = mmap(HIGH_ADDR, map_sz, PROT_READ,
	            MAP_SHARED | MAP_FIXED, fildes, 0);
`code ends`
    It return ENOMEM on x86_64 as well as we expected. But return
EINVAL on ppc64. So I want to know the MAX high addr for PPC64.
That's a pretty bogus test, since the max address is not specified
strictly.  It's currently 4T on ppc64, but patches that are in the
works will change it to 16T.

Also I'm not convinced that "highmem addr" has any meaning in the
context of userspace addresses.

-- 
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson
Thread (4 messages) 4 messages, 2 authors, last reply 2012-08-29
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help