From: Scott Wood <scottwood@freescale.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] powerpc/85xx: Add P1023RDB board support
Date: Tue, 16 Apr 2013 18:27:59 -0500 [thread overview]
Message-ID: <1366154879.23030.23@snotra> (raw)
In-Reply-To: <1366102846-7045-1-git-send-email-Chunhe.Lan@freescale.com> (from Chunhe.Lan@freescale.com on Tue Apr 16 04:00:46 2013)
On 04/16/2013 04:00:46 AM, Chunhe Lan wrote:
> +struct fsl_e_tlb_entry tlb_table[] = {
> + /* TLB 0 - for temp stack in cache */
> + SET_TLB_ENTRY(0, CONFIG_SYS_INIT_RAM_ADDR,
> CONFIG_SYS_INIT_RAM_ADDR,
> + MAS3_SX|MAS3_SW|MAS3_SR, 0,
> + 0, 0, BOOKE_PAGESZ_4K, 0),
> + SET_TLB_ENTRY(0, CONFIG_SYS_INIT_RAM_ADDR + 4 * 1024,
> + CONFIG_SYS_INIT_RAM_ADDR + 4 * 1024,
> + MAS3_SX|MAS3_SW|MAS3_SR, 0,
> + 0, 0, BOOKE_PAGESZ_4K, 0),
> + SET_TLB_ENTRY(0, CONFIG_SYS_INIT_RAM_ADDR + 8 * 1024,
> + CONFIG_SYS_INIT_RAM_ADDR + 8 * 1024,
> + MAS3_SX|MAS3_SW|MAS3_SR, 0,
> + 0, 0, BOOKE_PAGESZ_4K, 0),
> + SET_TLB_ENTRY(0, CONFIG_SYS_INIT_RAM_ADDR + 12 * 1024,
> + CONFIG_SYS_INIT_RAM_ADDR + 12 * 1024,
> + MAS3_SX|MAS3_SW|MAS3_SR, 0,
> + 0, 0, BOOKE_PAGESZ_4K, 0),
> +
> + /* TLB 1 */
> + /* *I*** - Covers boot page */
> + SET_TLB_ENTRY(1, 0xfffff000, 0xfffff000,
> + MAS3_SX|MAS3_SW|MAS3_SR, MAS2_I,
> + 0, 0, BOOKE_PAGESZ_4K, 1),
> +
> + /* *I*G* - CCSRBAR */
> + SET_TLB_ENTRY(1, CONFIG_SYS_CCSRBAR, CONFIG_SYS_CCSRBAR_PHYS,
> + MAS3_SX|MAS3_SW|MAS3_SR, MAS2_I|MAS2_G,
> + 0, 1, BOOKE_PAGESZ_4M, 1),
> +
> + /* W**G* - Flash/promjet, localbus */
> + /* This will be changed to *I*G* after relocation to RAM. */
> + SET_TLB_ENTRY(1, CONFIG_SYS_FLASH_BASE,
> CONFIG_SYS_FLASH_BASE_PHYS,
> + MAS3_SX|MAS3_SW|MAS3_SR, MAS2_W|MAS2_G,
> + 0, 2, BOOKE_PAGESZ_256M, 1),
> +
> + /* *I*G* - PCI */
> + SET_TLB_ENTRY(1, CONFIG_SYS_PCIE3_MEM_VIRT,
> CONFIG_SYS_PCIE3_MEM_PHYS,
> + MAS3_SX|MAS3_SW|MAS3_SR, MAS2_I|MAS2_G,
> + 0, 3, BOOKE_PAGESZ_1G, 1),
> +
> + /* *I*G* - PCI */
> + SET_TLB_ENTRY(1, CONFIG_SYS_PCIE3_MEM_VIRT + 0x40000000,
> + CONFIG_SYS_PCIE3_MEM_PHYS + 0x40000000,
> + MAS3_SX|MAS3_SW|MAS3_SR, MAS2_I|MAS2_G,
> + 0, 4, BOOKE_PAGESZ_256M, 1),
> +
> + SET_TLB_ENTRY(1, CONFIG_SYS_PCIE3_MEM_VIRT + 0x50000000,
> + CONFIG_SYS_PCIE3_MEM_PHYS + 0x50000000,
> + MAS3_SX|MAS3_SW|MAS3_SR, MAS2_I|MAS2_G,
> + 0, 5, BOOKE_PAGESZ_256M, 1),
Do not use MAS3_SX on I/O mappings. The G bit does not prevent
speculative instruction fetches.
> + /* *I*G - NAND */
> + SET_TLB_ENTRY(1, CONFIG_SYS_NAND_BASE,
> CONFIG_SYS_NAND_BASE_PHYS,
> + MAS3_SX|MAS3_SW|MAS3_SR, MAS2_I|MAS2_G,
> + 0, 11, BOOKE_PAGESZ_1M, 1),
Why do you need 1M for NAND? There's only 8K of stuff there.
> +/*
> + * Memory map
> + *
> + * 0x0000_0000 0x1fff_ffff DDR 500M
> Cacheable
> + * 0x8000_0000 0xbfff_ffff PCI Express Mem 1G
> non-cacheable
> + * 0xc000_0000 0xdfff_ffff PCI 512M
> non-cacheable
> + * 0xe100_0000 0xe3ff_ffff PCI IO range 4M
> non-cacheable
> + *
> + * Localbus non-cacheable
> + *
> + * 0xec00_0000 0xefff_ffff NOR flash 64M NOR
> flash
> + * 0xff00_0000 0xff3f_ffff DPAA_QBMAN 4M
> + * 0xff60_0000 0xff7f_ffff CCSR 2M
> non-cacheable
> + * 0xffa0_0000 0xffaf_ffff NAND 1M
> non-cacheable
> + * 0xffd0_0000 0xffd0_3fff L1 for stack 16K
> Cacheable TLB0
> + */
L1 for stack is neither "localbus" nor "non-cacheable". If you don't
want to distinguish that category, remove the comment.
[snip hundreds of lines of board config file]
Can we please refactor these board config headers to focus only on
what's different from board to board? These patches are very hard to
effectively review as is.
-Scott
prev parent reply other threads:[~2013-04-16 23:27 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-16 9:00 [U-Boot] [PATCH] powerpc/85xx: Add P1023RDB board support Chunhe Lan
2013-04-16 11:35 ` Timur Tabi
2013-04-16 12:42 ` Tom Rini
2013-04-16 13:57 ` Sinan Akman
2013-04-17 3:10 ` Chunhe Lan
2013-04-16 23:27 ` Scott Wood [this message]
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=1366154879.23030.23@snotra \
--to=scottwood@freescale.com \
--cc=u-boot@lists.denx.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.