From: Andrew Liu <shengping.liu@windriver.com>
To: paulus@samba.org
Cc: linuxppc-dev@ozlabs.org
Subject: [PATCH] [POWERPC] Uniformly use memstart_addr variable as the start address of physical memory in powerpc branch
Date: Wed, 21 May 2008 10:38:36 +0900 [thread overview]
Message-ID: <48337D1C.2070108@windriver.com> (raw)
[POWERPC]: Uniformly use memstart_addr as the start address of RAM
The variable: memstart_addr whose initial value is got from dts file
is used as the start address of physical memory in PowerPC ARCH,
although it is used in functions: mapin_ram(pgtable_32.c) and
cam_mapin_ram(fsl_booke_mmu.c), however, in function: mmu_mapin_ram
(ppc_mmu_32.c), use 0 as the start address of physical memory, so
it is necessary to unify them: in mmu_mapin_ram, use memstart_addr
as the start address of physical memory, instead of 0.
Signed-off-by: Andrew Liu <shengping.liu@windriver.com>
---
b/arch/powerpc/mm/ppc_mmu_32.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/powerpc/mm/ppc_mmu_32.c b/arch/powerpc/mm/ppc_mmu_32.c
index cef9f15..f133c6e 100644
--- a/arch/powerpc/mm/ppc_mmu_32.c
+++ b/arch/powerpc/mm/ppc_mmu_32.c
@@ -98,7 +98,7 @@ unsigned long __init mmu_mapin_ram(void)
break;
}
- setbat(2, KERNELBASE, 0, bl, _PAGE_RAM);
+ setbat(2, KERNELBASE, memstart_addr, bl, _PAGE_RAM);
done = (unsigned long)bat_addrs[2].limit - KERNELBASE + 1;
if ((done < tot) && !bat_addrs[3].limit) {
/* use BAT3 to cover a bit more */
@@ -106,7 +106,7 @@ unsigned long __init mmu_mapin_ram(void)
for (bl = 128<<10; bl < max_size; bl <<= 1)
if (bl * 2 > tot)
break;
- setbat(3, KERNELBASE+done, done, bl, _PAGE_RAM);
+ setbat(3, KERNELBASE+done, memstart_addr+done, bl, _PAGE_RAM);
done = (unsigned long)bat_addrs[3].limit - KERNELBASE + 1;
}
next reply other threads:[~2008-05-21 2:43 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-21 1:38 Andrew Liu [this message]
2008-05-21 3:11 ` [PATCH] [POWERPC] Uniformly use memstart_addr variable as the start address of physical memory in powerpc branch Kumar Gala
2008-05-21 2:22 ` Andrew Liu
2008-05-21 4:14 ` Paul Mackerras
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=48337D1C.2070108@windriver.com \
--to=shengping.liu@windriver.com \
--cc=linuxppc-dev@ozlabs.org \
--cc=paulus@samba.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