"alloc_area_pte: page already exists"
Hi,
I am working on a PPC440 board running 2.4.19 kernel. I am seeing this message when I try to boot up the system. "alloc_area_pte: page already exists". I am able to get a stack trace to show where it comes from. The stack trace is shown as follows.
======= Stack trace begins =============
Quoted 1 line
Quoted 1 line
NIP;
c002e474<__vmalloc+0x164/0x234[kernel]>
<=====
Trace; c002e474 <__vmalloc+0x164/0x234 [kernel]> Trace; c019422c <copy_entries_to_user+0x40/0x2f0 [kernel]>
Trace; c019453c <get_entries+0x60/0xac [kernel]> Trace; c0195148 <do_ipt_get_ctl+0x2a4/0x2cc [kernel]> Trace; c0158190 <nf_sockopt+0x150/0x210 [kernel]> Trace; c0158290 <nf_getsockopt+0x14/0x24 [kernel]> Trace; c0168380 <ip_getsockopt+0x6f4/0x9ec [kernel]> Trace; c01829fc <raw_getsockopt+0x1c/0x160 [kernel]> Trace; c0189a8c <inet_getsockopt+0x20/0x30 [kernel]> Trace; c01496f0 <sys_getsockopt+0x78/0x9c [kernel]> Trace; c0149d9c <sys_socketcall+0x1ac/0x1e0 [kernel]> Trace; c000353c <ret_from_syscall_1+0x0/0xb4 [kernel]> Trace; 7fffccb8 <Unknown (0x7fffccb8)>
Trace; 10006de4 <Unknown (0x10006de4)>
Trace; 100018f4 <Unknown (0x100018f4)>
Trace; 10001d1c <Unknown (0x10001d1c)>
Trace; 0fefe7f8 <Unknown (0xfefe7f8)>
Trace; 00000000 <Unknown (0x0)>
============ Stack trace ends ================
It seems to me it is from vmalloc(). Has anybody seen this problem before?
Thank you in advanced for your reply.
Regards,
Terry L.
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Quoted 4 lines · Xupei Liang
Hi,
I am working on a PPC440 board running 2.4.19 kernel.
Custom board?
--
Matt Porter
[email protected]
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Matt,
It is a custom board with 256MB of memory.
Regards,
Terry Liang
Quoted 6 lines · --- Matt Porter
Quoted 3 lines · Xupei Liang
Hi,
Quoted 10 lines
Quoted 1 line
I am working on a PPC440 board running 2.4.19
kernel.
Custom board?
--
Matt Porter
[email protected]
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Quoted 4 lines · Xupei Liang
Matt,
It is a custom board with 256MB of memory.
Ahh, ok. So, what you've done is misconfigured a mapping in your custom board port. It's reporting that you already have a pte allocated in the vmalloc area which must be untouched so the VM can allocate memory at runtime.
Usually, this is the result of an errant io_block_map entry which overlaps the vmalloc area. Examine the VMALLOC_START macro to see how the start of vmalloc space is calculated. In your case, (256MB of RAM) the start of vmalloc space will be at 0xd1000000 assuming a standard PAGE_OFFSET of 0xc0000000. If you've mapped something near that virtual address or somewhere close above that address then you need to move it. How much vmalloc space you need to reserve depends solely on your specific application.
In most cases, it's smarter to never use io_block_map and to let ioremap() create mappings dynamically so this sort of thing doesn't happen. Most modern in-kernel ports try to not use io_block_map if at all possible.
Regards,
--
Matt Porter
[email protected]
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Hi, Matt,
Thank you.
I am not using any io_block_map() call in the code. However, there are might be other similar causes. I am still working on it.
If you have more ideas, please let me know.
Regards,
Terry L.
Quoted 42 lines · --- Matt Porter
Quoted 4 lines · Xupei Liang
Matt,
It is a custom board with 256MB of memory.
Ahh, ok. So, what you've done is misconfigured a
mapping in
your custom board port. It's reporting that you
already have
a pte allocated in the vmalloc area which must be
untouched
so the VM can allocate memory at runtime.Usually, this is the result of an errant
io_block_mapentry
which overlaps the vmalloc area. Examine theVMALLOC_START
macro to see how the start of vmalloc space is calculated.
In your case, (256MB of RAM) the start of vmalloc space will
be at0xd1000000assuming a standardPAGE_OFFSETof0xc0000000.
If you've mapped something near that virtual address or somewhere
close above that address then you need to move it. How much
vmalloc space you need to reserve depends solely on your specific
application.In most cases, it's smarter to never use
io_block_mapand to
letioremap()create mappings dynamically so this sort of thing
doesn't happen. Most modern in-kernel ports try to not useio_block_mapif at all possible.
Quoted 6 lines
Regards,
--
Matt Porter
[email protected]
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/