mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Antony Pavlov <antonynpavlov@gmail.com>
To: barebox@lists.infradead.org
Subject: [RFC 5/7] MIPS: malta: make KSEG0 uncached
Date: Fri, 20 Jul 2012 12:47:37 +0400	[thread overview]
Message-ID: <1342774059-2169-6-git-send-email-antonynpavlov@gmail.com> (raw)
In-Reply-To: <1342774059-2169-1-git-send-email-antonynpavlov@gmail.com>

On MIPS as usual KSEG0 segment used for cached memory access,
and Linux kernel linked to KSEG0.

As just now we don't have cache memory support on MIPS,
we can change the KSEG0 mode (make it uncached) and
use it without any danger.

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
---
 arch/mips/mach-malta/lowlevel_init.S |    4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/mips/mach-malta/lowlevel_init.S b/arch/mips/mach-malta/lowlevel_init.S
index a0134f8..368c2fe 100644
--- a/arch/mips/mach-malta/lowlevel_init.S
+++ b/arch/mips/mach-malta/lowlevel_init.S
@@ -62,6 +62,10 @@ LEAF(mach_init_lowlevel)
 	lui	t0, 0x5e00
 	sw	t0, 136(t1) /* GT_PCI0M1HD */
 
+	/* make KSEG0 uncached */
+	li	t0, CONF_CM_UNCACHED
+	mtc0	t0, CP0_CONFIG
+
 	/* return */
 	b	mach_init_lowlevel_return
 	 nop
-- 
1.7.10


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  parent reply	other threads:[~2012-07-20  8:48 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-20  8:47 [WIP] add very basic ELF support on MIPS Antony Pavlov
2012-07-20  8:47 ` [RFC 1/7] MIPS: move start.S code to .text_entry section Antony Pavlov
2012-07-20  8:47 ` [RFC 2/7] MIPS: add the initial support for lowlevel init Antony Pavlov
2012-07-20  8:47 ` [RFC 3/7] MIPS: malta: add bogus " Antony Pavlov
2012-07-20  8:47 ` [RFC 4/7] MIPS: malta: add YAMON-style GT64120 memory map Antony Pavlov
2012-07-20 10:01   ` Antony Pavlov
2012-07-20  8:47 ` Antony Pavlov [this message]
2012-07-20  8:47 ` [RFC 6/7] MIPS: qemu-malta: add KSEG0 memory region Antony Pavlov
2012-07-20  8:47 ` [RFC 7/7] bootm: add very basic ELF support on MIPS (stealed from kexec) Antony Pavlov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1342774059-2169-6-git-send-email-antonynpavlov@gmail.com \
    --to=antonynpavlov@gmail.com \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox