Index: mips/mips/vm_machdep.c =================================================================== --- mips/mips/vm_machdep.c (revision 206103) +++ mips/mips/vm_machdep.c (working copy) @@ -214,18 +214,8 @@ { pt_entry_t *pte; int i; - vm_offset_t unused_kstack_page; /* - * Unmap the unused kstack page. - */ - unused_kstack_page = td->td_kstack; - if (td->td_md.md_realstack == td->td_kstack) - unused_kstack_page += (KSTACK_PAGES - 1) * PAGE_SIZE; - - pmap_kremove(unused_kstack_page); - - /* * The kstack may be at a different physical address now. * Cache the PTEs for the Kernel stack in the machine dependent * part of the thread struct so cpu_switch() can quickly map in @@ -249,19 +239,13 @@ void cpu_thread_alloc(struct thread *td) { - vm_offset_t unused_kstack_page; pt_entry_t *pte; int i; - if (td->td_kstack & (1 << PAGE_SHIFT)) { + if (td->td_kstack & (1 << PAGE_SHIFT)) td->td_md.md_realstack = td->td_kstack + PAGE_SIZE; - unused_kstack_page = td->td_kstack; - } else { + else td->td_md.md_realstack = td->td_kstack; - unused_kstack_page = td->td_kstack + - (KSTACK_PAGES - 1) * PAGE_SIZE; - } - pmap_kremove(unused_kstack_page); td->td_pcb = (struct pcb *)(td->td_md.md_realstack + (td->td_kstack_pages - 1) * PAGE_SIZE) - 1; Index: kern/vfs_mount.c =================================================================== --- kern/vfs_mount.c (revision 206103) +++ kern/vfs_mount.c (working copy) @@ -1649,6 +1649,8 @@ options = NULL; + pause("usbhack", hz*10); + root_mount_prepare(); mount_zone = uma_zcreate("Mountpoints", sizeof(struct mount), Index: dev/usb/usb_transfer.c =================================================================== --- dev/usb/usb_transfer.c (revision 206103) +++ dev/usb/usb_transfer.c (working copy) @@ -614,12 +614,14 @@ /* * check if we need to setup * a local buffer: + * XXXKAN aieeeee: CACHE LINE? MIPS weeps boody tears here. */ if (!xfer->flags.ext_buffer) { + uint32_t data_align = MAX(USB_HOST_ALIGN, 32) - 1; /* align data */ - parm->size[0] += ((-parm->size[0]) & (USB_HOST_ALIGN - 1)); + parm->size[0] += ((-parm->size[0]) & data_align); if (parm->buf) { @@ -635,7 +637,7 @@ parm->size[0] += parm->bufsize; /* align data again */ - parm->size[0] += ((-parm->size[0]) & (USB_HOST_ALIGN - 1)); + parm->size[0] += ((-parm->size[0]) & data_align); } /* * Compute maximum buffer size