Date: Mon, 19 Jan 2009 05:20:52 +0000 (UTC) From: Alan Cox <alc@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org Subject: svn commit: r187420 - in stable/7/sys/amd64: amd64 include Message-ID: <200901190520.n0J5KqTp098763@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: alc Date: Mon Jan 19 05:20:52 2009 New Revision: 187420 URL: http://svn.freebsd.org/changeset/base/187420 Log: MFC partial merge of rev 179886 Make preparations for increasing the size of the kernel virtual address space on the amd64 architecture. Modified: stable/7/sys/amd64/amd64/mem.c stable/7/sys/amd64/amd64/pmap.c stable/7/sys/amd64/amd64/trap.c stable/7/sys/amd64/include/stack.h Modified: stable/7/sys/amd64/amd64/mem.c ============================================================================== --- stable/7/sys/amd64/amd64/mem.c Mon Jan 19 04:31:18 2009 (r187419) +++ stable/7/sys/amd64/amd64/mem.c Mon Jan 19 05:20:52 2009 (r187420) @@ -119,7 +119,7 @@ kmemphys: addr = trunc_page(v); eaddr = round_page(v + c); - if (addr < (vm_offset_t)KERNBASE) + if (addr < VM_MIN_KERNEL_ADDRESS) return (EFAULT); for (; addr < eaddr; addr += PAGE_SIZE) if (pmap_extract(kernel_pmap, addr) == 0) Modified: stable/7/sys/amd64/amd64/pmap.c ============================================================================== --- stable/7/sys/amd64/amd64/pmap.c Mon Jan 19 04:31:18 2009 (r187419) +++ stable/7/sys/amd64/amd64/pmap.c Mon Jan 19 05:20:52 2009 (r187420) @@ -1493,7 +1493,7 @@ pmap_release(pmap_t pmap) static int kvm_size(SYSCTL_HANDLER_ARGS) { - unsigned long ksize = VM_MAX_KERNEL_ADDRESS - KERNBASE; + unsigned long ksize = VM_MAX_KERNEL_ADDRESS - VM_MIN_KERNEL_ADDRESS; return sysctl_handle_long(oidp, &ksize, 0, req); } @@ -1523,7 +1523,7 @@ pmap_growkernel(vm_offset_t addr) mtx_assert(&kernel_map->system_mtx, MA_OWNED); if (kernel_vm_end == 0) { - kernel_vm_end = KERNBASE; + kernel_vm_end = VM_MIN_KERNEL_ADDRESS; nkpt = 0; while ((*pmap_pde(kernel_pmap, kernel_vm_end) & PG_V) != 0) { kernel_vm_end = (kernel_vm_end + PAGE_SIZE * NPTEPG) & ~(PAGE_SIZE * NPTEPG - 1); Modified: stable/7/sys/amd64/amd64/trap.c ============================================================================== --- stable/7/sys/amd64/amd64/trap.c Mon Jan 19 04:31:18 2009 (r187419) +++ stable/7/sys/amd64/amd64/trap.c Mon Jan 19 05:20:52 2009 (r187420) @@ -610,7 +610,7 @@ trap_pfault(frame, usermode) vm_offset_t eva = frame->tf_addr; va = trunc_page(eva); - if (va >= KERNBASE) { + if (va >= VM_MIN_KERNEL_ADDRESS) { /* * Don't allow user-mode faults in kernel address space. */ Modified: stable/7/sys/amd64/include/stack.h ============================================================================== --- stable/7/sys/amd64/include/stack.h Mon Jan 19 04:31:18 2009 (r187419) +++ stable/7/sys/amd64/include/stack.h Mon Jan 19 05:20:52 2009 (r187420) @@ -33,7 +33,7 @@ * Stack trace. */ #define INKERNEL(va) (((va) >= DMAP_MIN_ADDRESS && (va) < DMAP_MAX_ADDRESS) \ - || ((va) >= KERNBASE && (va) < VM_MAX_KERNEL_ADDRESS)) + || ((va) >= VM_MIN_KERNEL_ADDRESS && (va) < VM_MAX_KERNEL_ADDRESS)) struct amd64_frame { struct amd64_frame *f_frame;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200901190520.n0J5KqTp098763>