aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWojtek Kosior <kwojtus@protonmail.com>2019-10-22 16:30:15 +0200
committerWojtek Kosior <kwojtus@protonmail.com>2019-10-22 16:30:15 +0200
commitc68891456e3b3c4ad37c36293413405151b87951 (patch)
treef37a73f14f7c68d046529ed6cdaeac29b24d893d
parentf2f81de9973b5a3028eb6cbbaf3942cc68446f9b (diff)
downloadrpi-MMU-example-c68891456e3b3c4ad37c36293413405151b87951.tar.gz
rpi-MMU-example-c68891456e3b3c4ad37c36293413405151b87951.zip
check actual 4 bits that indicate paging support (3 were being checed b4)
-rw-r--r--kernel.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel.c b/kernel.c
index b387a10..76b314d 100644
--- a/kernel.c
+++ b/kernel.c
@@ -25,7 +25,7 @@ void kernel_main(uint32_t r0, uint32_t r1, uint32_t atags)
char *paging;
- switch(ID_MMFR0 & 7) /* lowest 4 bits indicate VMSA support */ {
+ switch(ID_MMFR0 & 0xf) /* lowest 4 bits indicate VMSA support */ {
case 0 : paging = "no paging\n\r"; break;
case 1 : paging = "implementation defined paging\n\r"; break;
case 2 : paging = "VMSAv6, with cache and TLB type registers\n\r"; break;