summaryrefslogtreecommitdiff
path: root/src/arch/arm64/armv8
diff options
context:
space:
mode:
authorAaron Durbin <adurbin@chromium.org>2014-09-06 01:07:41 -0500
committerPatrick Georgi <pgeorgi@google.com>2015-03-27 08:04:44 +0100
commit8ff6c215a1c759ed4506a0bdbe4aa6a2fe9bd74f (patch)
treebea3bcaf942fe7030aeb7a385ea27d02d67d7b15 /src/arch/arm64/armv8
parent4da4d3c9448a40a6e97d56cd6dc5db8d416e40b4 (diff)
arm64: remove printk() before console_init()
printk() shouldn't be called until the consoles have been initialized. This just so happened to work by luck. Once CONFIG_SMP is enabled that breaks because of spinlock usage in uncached memory. BUG=chrome-os-partner:31761 BRANCH=None TEST=Built with CONFIG_SMP and ramstage doesn't hang early. Change-Id: I54231db3c811c0d19c5c7fbaa406cacd1ff019ec Signed-off-by: Patrick Georgi <pgeorgi@chromium.org> Original-Commit-Id: 31c3f972ac5c89472009b5b2cb7dbc0f02cfd9a0 Original-Change-Id: I6091b1e949e648b3435231946e5924260bf1807f Original-Signed-off-by: Aaron Durbin <adurbin@chromium.org> Original-Reviewed-on: https://chromium-review.googlesource.com/216920 Original-Reviewed-by: Furquan Shaikh <furquan@chromium.org> Reviewed-on: http://review.coreboot.org/9037 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Diffstat (limited to 'src/arch/arm64/armv8')
-rw-r--r--src/arch/arm64/armv8/mmu.c24
1 files changed, 0 insertions, 24 deletions
diff --git a/src/arch/arm64/armv8/mmu.c b/src/arch/arm64/armv8/mmu.c
index 8045cc0e54..2c1555c808 100644
--- a/src/arch/arm64/armv8/mmu.c
+++ b/src/arch/arm64/armv8/mmu.c
@@ -31,9 +31,6 @@
#include <stdint.h>
#include <string.h>
-#include <cbmem.h>
-#include <console/console.h>
-
#include <memrange.h>
#include <arch/mmu.h>
#include <arch/lib_helpers.h>
@@ -110,7 +107,6 @@ static uint64_t *get_new_table(void)
uint64_t *new;
if (free_idx >= max_tables) {
- printk(BIOS_ERR,"ARM64 MMU: No free table\n");
return NULL;
}
@@ -233,7 +229,6 @@ static void init_mmap_entry(struct range_entry *r)
uint64_t ret;
if (sanity_check(base_addr,temp_size)) {
- printk(BIOS_ERR, "ARM64 MMU: sanity check failed\n");
return;
}
@@ -259,7 +254,6 @@ void mmu_init(struct memranges *mmap_ranges,
struct range_entry *mmap_entry;
if (sanity_check((uint64_t)ttb_buffer, ttb_size)) {
- printk(BIOS_ERR, "ARM64: Sanity failed for ttb\n");
return;
}
@@ -267,22 +261,9 @@ void mmu_init(struct memranges *mmap_ranges,
max_tables = (ttb_size >> GRANULE_SIZE_SHIFT);
xlat_addr = ttb_buffer;
- printk(BIOS_DEBUG, "ARM64: TTB_BUFFER: 0x%p Max Tables: %d\n",
- (void*)xlat_addr, max_tables);
-
memranges_each_entry(mmap_entry, mmap_ranges) {
init_mmap_entry(mmap_entry);
}
- printk(BIOS_DEBUG, "ARM64: MMU init done\n");
-}
-
-static uint32_t is_mmu_enabled(void)
-{
- uint32_t sctlr;
-
- sctlr = raw_read_sctlr_el3();
-
- return (sctlr & SCTLR_M);
}
void mmu_enable(void)
@@ -313,9 +294,4 @@ void mmu_enable(void)
raw_write_sctlr_el3(sctlr);
isb();
-
- if (is_mmu_enabled())
- printk(BIOS_DEBUG, "ARM64: MMU enable done\n");
- else
- printk(BIOS_DEBUG, "ARM64: MMU enable failed\n");
}