page fault on 1.2.0-RELEASE

Matthew Dillon dillon at
Mon Jun 13 15:13:35 PDT 2005

:you betcha
:>     sources?   It should be possible to figure out what is going on by
:>     adding printf()s in vm_page_startup() and vm_add_new_page().  I
:>     would print out e.g.  first_page, page_range, npages, end,
:>     vm_page_array, new_end, and the 'mapped' variable.  I would print
:>     all those out after it calls pmap_map().
:	first_page 0x1
:	page_range 0xb
:	npages -2046298670
:	end 0xffc0008f00000000
:	new_end 0xffc0008efffff000
:	vm_page_array 0xc081a000
:	mapped 0xc081b000
:	new_end 0xffc0008efffff000


    A little broken... vm_paddr_t is a 64 bit quantity, you have to use
    %lld or %qd in your printfs .  That's why page_range and npages
    are broken.

:>     I would also print out the phys_avail[i] and phys_avail[i+1] inside
:>     the for (...) loop under the 'Construct the free queues' comment,
:>     and the 'ps' and 'last_pa' variables just before the inner while()
:>     loop.
:	phys_avail[i] 0x1000
:	phys_avail[i+1] 0x9f000
:	last_pa 0x9f000
:As a bonus, a couple of items from vm_add_new_page printed right
:before the call 'if (vpq->flipflop)'. The instruction pointer looked
:like it might be somewhere in the TAILQ_INSERT_HEAD()
:	m 0xc081a000
:	m->queue 52410
:	vpq 0xc052ffa8
:	vpq->flipflop 8
:	vpq->pl 0xc052ffa8

    The value for m->queue should not be possible.  The m->pc
    mask is 0x3f (63).  So the m->pc assignment and thus the
    m->queue assignment after it should be a fairly small number.

:Fatal trap 12: page fault while in kernel mode
:mp_lock = 00000000; cpuid = 0; = 00000000
:fault virtual address	= 0x26000
:fault code		= supervisor write, page not present
:instruction pointer	= 0x8:0xc02f2753
:stack pointer	        = 0x10:0xc059ace8
:frame pointer	        = 0x10:0xc059ad0c
:code segment		= base 0x0, limit 0xfffff, type 0x1b

    Since this is your rebuilt kernel you will have to 
    gdb -k yourkernel and 'disassemble 0xc02f2753'.

:Chuck Tuffli
:Agilent Technologies

					Matthew Dillon 
					<dillon at xxxxxxxxxxxxx>

More information about the Bugs mailing list