Subject: kern/11672: ext2fs write panics
To: None <gnats-bugs@gnats.netbsd.org>
From: None <fvdl@vaasje.org>
List: netbsd-bugs
Date: 12/09/2000 14:16:11
>Number:         11672
>Category:       kern
>Synopsis:       ext2fs write panics
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Dec 09 14:16:00 PST 2000
>Closed-Date:
>Last-Modified:
>Originator:     Frank van der Linden
>Release:        -curren as of dec 7th
>Organization:
	
>Environment:
NetBSD struis 1.5L NetBSD 1.5L (VMSTRUIS) #0: Sat Dec  9 22:11:28 MET 2000     fvdl@sushi:/work/trees/current/sys/arch/i386/compile/VMSTRUIS i386


>Description:
	While running a Linux binary of gcc from a Linux partition
	(mounted on /emul/linux, filetype ext2fs),
	kernel panicked in the KASSERT at line 1233 of uvm_page.c:

#13 0xc028e411 in __assert () at ../../../../../../lib/libkern/__assert.c:47
#14 0xc022df6a in uvm_page_unbusy (pgs=0xe30abcf4, npgs=1)
    at ../../../../uvm/uvm_page.c:1233
#15 0xc0207935 in ext2fs_balloc_range (vp=0xe309e6d8, off=1024, len=187, 
    cred=0xc04f8e00, flags=0) at ../../../../ufs/ext2fs/ext2fs_balloc.c:489
#16 0xc020a5e2 in ext2fs_write (v=0xe30abe50)
    at ../../../../ufs/ext2fs/ext2fs_readwrite.c:279
#17 0xc019e430 in vn_write (fp=0xe2f6c7e0, offset=0xe2f6c7fc, uio=0xe30abe9c, 
    cred=0xc04f8e00, flags=1) at ../../../../sys/vnode_if.h:386
#18 0xc01805c4 in dofilewrite (p=0xe303c4d0, fd=3, fp=0xe2f6c7e0, 
    buf=0x480bf000, nbyte=55, offset=0xe2f6c7fc, flags=1, retval=0xe30abf24)
    at ../../../../kern/sys_generic.c:360
#19 0xc0180527 in sys_write (p=0xe303c4d0, v=0xe30abf2c, retval=0xe30abf24)
    at ../../../../kern/sys_generic.c:311
#20 0xc0275230 in linux_syscall (frame=0xe30abfb0)
    at ../../../../arch/i386/i386/linux_syscall.c:227
#21 0xc023b154 in syscall (frame={tf_es = 31, tf_ds = 31, tf_edi = 134840784, 
      tf_esi = 55, tf_ebp = -1077946540, tf_ebx = 3, tf_edx = 55, 
      tf_ecx = 1208741888, tf_eax = 4, tf_trapno = 3, tf_err = 2, 
      tf_eip = 1209423220, tf_cs = 23, tf_eflags = 518, tf_esp = -1077946580, 
      tf_ss = 31, tf_vm86_es = 0, tf_vm86_ds = 0, tf_vm86_fs = 0, 
      tf_vm86_gs = 0}) at ../../../../arch/i386/i386/trap.c:589
#22 0xc0100d4d in syscall1
(gdb) print *pg
$11 = {pageq = {tqe_next = 0xc0433988, tqe_prev = 0xc031bb40}, hashq = {
    tqe_next = 0x0, tqe_prev = 0xc24cf6c0}, listq = {tqe_next = 0x0, 
    tqe_prev = 0xe309e6e0}, uanon = 0x0, uobject = 0xe309e6d8, offset = 0, 
  flags = 141, version = 1, wire_count = 0, pqflags = 0, loan_count = 0, 
  phys_addr = 66957312}
(gdb) up
#15 0xc0207935 in ext2fs_balloc_range (vp=0xe309e6d8, off=1024, len=187, 
    cred=0xc04f8e00, flags=0) at ../../../../ufs/ext2fs/ext2fs_balloc.c:489
489                     uvm_page_unbusy(pgs1, npages1);
(gdb) print npages1
$12 = 1
(gdb) print pgs1[0]
$13 = 0xe30abcf4
(gdb) print off
$14 = 1024
(gdb) print pagestart
$15 = 0
(gdb) print *vp
$16 = {v_uvm = {u_obj = {vmobjlock = {lock_data = 0}, pgops = 0xc02e1ee0, 
      memq = {tqh_first = 0xc0433950, tqh_last = 0xc0433960}, uo_npages = 1, 
      uo_refs = 2}, u_flags = 0, u_nio = 0, u_size = 1211}, v_writecount = 1, 
  v_holdcnt = 0, v_lastr = 0, v_id = 939, v_mount = 0xc04f6400, 
  v_op = 0xc0498f00, v_freelist = {tqe_next = 0x0, tqe_prev = 0x0}, 
  v_mntvnodes = {le_next = 0xe309e600, le_prev = 0xc04f6414}, v_cleanblkhd = {
    lh_first = 0x0}, v_dirtyblkhd = {lh_first = 0x0}, v_synclist = {
    le_next = 0x0, le_prev = 0x0}, v_type = VREG, v_un = {
    vu_mountedhere = 0x0, vu_socket = 0x0, vu_specinfo = 0x0, 
    vu_fifoinfo = 0x0}, v_lease = 0x0, v_lastw = 0, v_cstart = 0, v_lasta = 0, 
  v_clen = 0, v_ralen = 0, v_maxra = 0, v_lock = {lk_interlock = {
      lock_data = 0}, lk_flags = 1024, lk_sharecount = 0, 
    lk_exclusivecount = 1, lk_recurselevel = 0, lk_waitcount = 0, 
    lk_wmesg = 0xc02aa225 "vnlock", lk_un = {lk_un_sleep = {
        lk_sleep_lockholder = 156, lk_sleep_prio = 20, lk_sleep_timo = 0}, 
      lk_un_spin = {lk_spin_cpu = 156}}}, v_glock = {lk_interlock = {
      lock_data = 0}, lk_flags = 0, lk_sharecount = 0, lk_exclusivecount = 0, 
    lk_recurselevel = 0, lk_waitcount = 0, lk_wmesg = 0xc02aa22c "glock", 
    lk_un = {lk_un_sleep = {lk_sleep_lockholder = -1, lk_sleep_prio = 20, 
        lk_sleep_timo = 0}, lk_un_spin = {lk_spin_cpu = 4294967295}}}, 
  v_vnlock = 0xe309e75c, v_tag = VT_EXT2FS, v_data = 0xe30a8448}


>How-To-Repeat:
	See above.
>Fix:
	Unknown.
>Release-Note:
>Audit-Trail:
>Unformatted: