summaryrefslogtreecommitdiffstats
path: root/sys/sparc64
diff options
context:
space:
mode:
authormdf <mdf@FreeBSD.org>2011-05-13 19:35:01 +0000
committermdf <mdf@FreeBSD.org>2011-05-13 19:35:01 +0000
commit3d3b036f9541230485c7edd1fafaec6e4345641a (patch)
treea7b19af758b87ed8c5280b36452735563a1afd59 /sys/sparc64
parent9465c340011c0f0d939dc79a97cb31b7b974f015 (diff)
downloadFreeBSD-src-3d3b036f9541230485c7edd1fafaec6e4345641a.zip
FreeBSD-src-3d3b036f9541230485c7edd1fafaec6e4345641a.tar.gz
Move the ZERO_REGION_SIZE to a machine-dependent file, as on many
architectures (i386, for example) the virtual memory space may be constrained enough that 2MB is a large chunk. Use 64K for arches other than amd64 and ia64, with special handling for sparc64 due to differing hardware. Also commit the comment changes to kmem_init_zero_region() that I missed due to not saving the file. (Darn the unfamiliar development environment). Arch maintainers, please feel free to adjust ZERO_REGION_SIZE as you see fit. Requested by: alc MFC after: 1 week MFC with: r221853
Diffstat (limited to 'sys/sparc64')
-rw-r--r--sys/sparc64/include/vmparam.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/sparc64/include/vmparam.h b/sys/sparc64/include/vmparam.h
index 0638d0d..1b9e537 100644
--- a/sys/sparc64/include/vmparam.h
+++ b/sys/sparc64/include/vmparam.h
@@ -240,4 +240,11 @@
extern vm_offset_t vm_max_kernel_address;
+/*
+ * Older sparc64 machines have a virtually indexed L1 data cache of 16KB.
+ * Consequently, mapping the same physical page multiple times may have
+ * caching disabled.
+ */
+#define ZERO_REGION_SIZE PAGE_SIZE
+
#endif /* !_MACHINE_VMPARAM_H_ */
OpenPOWER on IntegriCloud