mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Antony Pavlov <antonynpavlov@gmail.com>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH 1/4] MIPS: introduce ram0 regions register function
Date: Sun, 27 Jan 2013 12:23:30 +0100	[thread overview]
Message-ID: <20130127112330.GZ1906@pengutronix.de> (raw)
In-Reply-To: <1359219160-18500-2-git-send-email-antonynpavlov@gmail.com>

On Sat, Jan 26, 2013 at 08:52:37PM +0400, Antony Pavlov wrote:
> On MIPS there are two segments in CPU address space that
> can be used for untranslated memory access: KSEG0 and KSEG1.
> KSEG0 is used for cached access and KSEG1 is used for
> uncached one.
> 
> The instroduced mips_add_ram0() function registers two
> address regions for memory access: one in KSEG0 and
> the other one in KSEG1.
> 
> Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
> ---
>  arch/mips/include/asm/memory.h |   12 ++++++++++++
>  1 file changed, 12 insertions(+)
>  create mode 100644 arch/mips/include/asm/memory.h
> 
> diff --git a/arch/mips/include/asm/memory.h b/arch/mips/include/asm/memory.h
> new file mode 100644
> index 0000000..2aa28b7
> --- /dev/null
> +++ b/arch/mips/include/asm/memory.h
> @@ -0,0 +1,12 @@
> +#ifndef __ASM_MIPS_MEMORY_H
> +#define __ASM_MIPS_MEMORY_H
> +
> +#include <memory.h>
> +#include <asm/addrspace.h>
> +
> +static inline void mips_add_ram0(resource_size_t size)
> +{
> +	barebox_add_memory_bank("kseg0_ram0", KSEG0, size);
> +	barebox_add_memory_bank("kseg1_ram0", KSEG1, size);
> +}

Is kseg0/1 a common name under MIPS, or in other words, do users know
what they have here?

Why should I use the uncached RAM as a user? Is this for debugging or
does it have apractical usecase?

Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

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

  reply	other threads:[~2013-01-27 11:23 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-26 16:52 [PATCH 0/4] " Antony Pavlov
2013-01-26 16:52 ` [PATCH 1/4] " Antony Pavlov
2013-01-27 11:23   ` Sascha Hauer [this message]
     [not found]     ` <CAA4bVAFEMoEheftB=qJ7d1+yVOJDGMJG9+1xbGpPsQFTetWa_w@mail.gmail.com>
2013-01-28  9:10       ` Fwd: " Antony Pavlov
2013-01-26 16:52 ` [PATCH 2/4] MIPS: qemu-malta: use mips_add_ram0() Antony Pavlov
2013-01-26 16:52 ` [PATCH 3/4] MIPS: rzx50: " Antony Pavlov
2013-01-26 16:52 ` [PATCH 4/4] MIPS: dlink-dir-320: " Antony Pavlov
2013-01-28  7:30 ` [PATCH 0/4] MIPS: introduce ram0 regions register function Sascha Hauer

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=20130127112330.GZ1906@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=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