lkml.org 
[lkml]   [2002]   [Jul]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: BUG at rmap.c:212
On Wed, 31 Jul 2002, Petr Vandrovec wrote:

> > Line 212 is 'pte_chain_unlock(page);' right ?
>
> Nope. On my system (2.5.29-changeset548) it is a BUG() call which was
> added by akpm in rmap.c revision 1.5, in his 'Add BUG() on a can't-happen
> code path in page_remove_rmap()'. It just added #else BUG() branch
> to #ifdef DEBUG_RMAP conditional.

> Probably because of your code did not do anything special when
> 'Not found. This should NEVER happen!' code path triggers.

It used to, until I found out that that regularly blew up
for people mmap()ing devices and I had to remove that code
again ;)

The reason for that problem is that a device driver would
allocate memory, set PG_reserved on it and then let user
programs mmap() it.

These reserved pages do not get a pte chain because the
memory isn't swappable and if the page stays reserved
page_remove_rmap won't even try searching for the pte
chain.

However, some drivers (nvidia) clear PG_reserved without
first having the programs exit, so page_remove_rmap will
end up searching for the pte chain, which of course
doesn't exist...

Of course, ntpd is probably running into a different problem,
but the printk's enabled with DEBUG_RMAP should give us some
hints.

regards,

Rik
--
Bravely reimplemented by the knights who say "NIH".

http://www.surriel.com/ http://distro.conectiva.com/

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

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