summaryrefslogtreecommitdiffstats
path: root/src/kernel
diff options
context:
space:
mode:
authorPatrick Williams <iawillia@us.ibm.com>2011-04-11 14:42:20 -0500
committerPatrick Williams <iawillia@us.ibm.com>2011-04-11 14:42:20 -0500
commit55eaeb37070dc1f635dc5f02ed49c7c7bba4627a (patch)
tree21f95e00f4e6d305604e0f594be201e18b7aa0de /src/kernel
parent770f2f7e5d826b11c6e65d929dcc44a203833abc (diff)
downloadtalos-hostboot-55eaeb37070dc1f635dc5f02ed49c7c7bba4627a.tar.gz
talos-hostboot-55eaeb37070dc1f635dc5f02ed49c7c7bba4627a.zip
Fix dcbz to round up to nearest cache line.
Diffstat (limited to 'src/kernel')
-rw-r--r--src/kernel/kernel.C7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/kernel/kernel.C b/src/kernel/kernel.C
index f39290a09..5d16033d0 100644
--- a/src/kernel/kernel.C
+++ b/src/kernel/kernel.C
@@ -75,8 +75,11 @@ void Kernel::cppBootstrap()
void Kernel::memBootstrap()
{
- // Populate L3 cache lines after code space.
- uint64_t* cache_line = (uint64_t*) VFS_LAST_ADDRESS;
+ // Populate L3 cache lines after code space.
+ // Needs to be rounded up to nearest 256 bytes (cache line size).
+ uint64_t* cache_line = (uint64_t*) (VFS_LAST_ADDRESS +
+ ((VFS_LAST_ADDRESS % 256) ? (256 - (VFS_LAST_ADDRESS % 256)) : 0))
+ ;
uint64_t* end_cache_line = (uint64_t*) VmmManager::FULL_MEM_SIZE;
while (cache_line != end_cache_line)
{
OpenPOWER on IntegriCloud