lkml.org 
[lkml]   [1999]   [Oct]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: mmapping of page 0xfffff000 impossible ?
Date
include/asm-i386/fixmap.h


"Leave one empty page between vmalloc'ed areas and the start of the fixmap,
and leave one page empty at the top of mem."

I would guess that you can't map the fixmap, either.


Nathan


> -----Original Message-----
> From: root [SMTP:koenig@tat.physik.uni-tuebingen.de]
> Sent: Sunday, October 10, 1999 9:53 PM
> To: linux-kernel-list
> Cc: Egbert Eich
> Subject: mmapping of page 0xfffff000 impossible ?
>
> why isn't it possible to mmap the very last page in 32bit address space ?
>
> strace output for 2.2.12 of the small sample program below:
> open("/dev/mem", O_RDWR) = 3
> mmap(NULL, 61440, PROT_READ, MAP_SHARED, 3, 0xffff0000) = 0x4011b000
> mmap(NULL, 61441, PROT_READ, MAP_SHARED, 3, 0xffff0000) = -1 EINVAL
> (Invalid argument)
>
> --------------------------------------------------------------------------
> -----
> #include <unistd.h>
> #include <sys/mman.h>
> #include <fcntl.h>
> main()
> {
> int f;
> void *p;
>
> f = open("/dev/mem", O_RDWR);
>
> /* this will work ... */
> p = mmap(NULL, 0xf000, PROT_READ, MAP_SHARED, f, 0xffff0000);
>
> /* this one won't :-( */
> p = mmap(NULL, 0xf001, PROT_READ, MAP_SHARED, f, 0xffff0000);
> }
> --------------------------------------------------------------------------
> -----
>
>
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.rutgers.edu
> Please read the FAQ at http://www.tux.org/lkml/

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:54    [W:0.036 / U:2.576 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site