aboutsummaryrefslogtreecommitdiff
path: root/sys/i386
diff options
context:
space:
mode:
authorAdrian Chadd <adrian@FreeBSD.org>2009-08-31 23:30:39 +0000
committerAdrian Chadd <adrian@FreeBSD.org>2009-08-31 23:30:39 +0000
commit0ad6375395f8bab40563033c23801112bd014ffc (patch)
treed1f7c12e10fb771295cc136239c58d7b6f009b9b /sys/i386
parent54d1bac5bb90a835bf60c9452a116abaf8d92d7a (diff)
downloadsrc-0ad6375395f8bab40563033c23801112bd014ffc.tar.gz
src-0ad6375395f8bab40563033c23801112bd014ffc.zip
Shuffle pagezero() into the same location as in sys/i386/i386/pmap.c.
Notes
Notes: svn path=/head/; revision=196723
Diffstat (limited to 'sys/i386')
-rw-r--r--sys/i386/xen/locore.s2
-rw-r--r--sys/i386/xen/pmap.c32
2 files changed, 16 insertions, 18 deletions
diff --git a/sys/i386/xen/locore.s b/sys/i386/xen/locore.s
index a2c4a8db7b74..95d2afae8411 100644
--- a/sys/i386/xen/locore.s
+++ b/sys/i386/xen/locore.s
@@ -148,9 +148,7 @@ IdlePDPT: .long 0 /* phys addr of kernel PDPT */
.globl KPTphys
#endif
KPTphys: .long 0 /* phys addr of kernel page tables */
-#ifdef SMP
.globl gdtset
-#endif
gdtset: .long 0 /* GDT is valid */
.globl proc0kstack
diff --git a/sys/i386/xen/pmap.c b/sys/i386/xen/pmap.c
index 9dc077f8803e..52b41e99d682 100644
--- a/sys/i386/xen/pmap.c
+++ b/sys/i386/xen/pmap.c
@@ -328,22 +328,6 @@ CTASSERT(KERNBASE % (1 << 24) == 0);
-static __inline void
-pagezero(void *page)
-{
-#if defined(I686_CPU)
- if (cpu_class == CPUCLASS_686) {
-#if defined(CPU_ENABLE_SSE)
- if (cpu_feature & CPUID_SSE2)
- sse2_pagezero(page);
- else
-#endif
- i686_pagezero(page);
- } else
-#endif
- bzero(page, PAGE_SIZE);
-}
-
void
pd_set(struct pmap *pmap, int ptepindex, vm_paddr_t val, int type)
{
@@ -3343,6 +3327,22 @@ pmap_copy(pmap_t dst_pmap, pmap_t src_pmap, vm_offset_t dst_addr, vm_size_t len,
PMAP_UNLOCK(dst_pmap);
}
+static __inline void
+pagezero(void *page)
+{
+#if defined(I686_CPU)
+ if (cpu_class == CPUCLASS_686) {
+#if defined(CPU_ENABLE_SSE)
+ if (cpu_feature & CPUID_SSE2)
+ sse2_pagezero(page);
+ else
+#endif
+ i686_pagezero(page);
+ } else
+#endif
+ bzero(page, PAGE_SIZE);
+}
+
/*
* pmap_zero_page zeros the specified hardware page by mapping
* the page into KVM and using bzero to clear its contents.