]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
ppc/85xx: Make flash TLB entry determined at runtime on FSL boards
authorKumar Gala <galak@kernel.crashing.org>
Fri, 13 Nov 2009 15:25:07 +0000 (09:25 -0600)
committerKumar Gala <galak@kernel.crashing.org>
Tue, 5 Jan 2010 19:49:08 +0000 (13:49 -0600)
Rather than hard coding which TLB entry the FLASH is mapped with we can
use find_tlb_idx to determine the entry.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
board/freescale/mpc8536ds/mpc8536ds.c
board/freescale/mpc8572ds/mpc8572ds.c
board/freescale/p1_p2_rdb/p1_p2_rdb.c
board/freescale/p2020ds/p2020ds.c

index ce40cdb6f1f62932083cd84acf61e99af3aad4d5..f8292cf378953df96d101995286686f86b574c94 100644 (file)
@@ -313,7 +313,7 @@ void pci_init_board(void)
 int board_early_init_r(void)
 {
        const unsigned int flashbase = CONFIG_SYS_FLASH_BASE;
-       const u8 flash_esel = 1;
+       const u8 flash_esel = find_tlb_idx((void *)flashbase, 1);
 
        /*
         * Remap Boot flash + PROMJET region to caching-inhibited
index 556846a42978b92f30a1b58ed6d8fcb010502c91..64e164b1a0d93e458f7b0bf5e96ce716c46e994f 100644 (file)
@@ -264,7 +264,7 @@ void pci_init_board(void)
 int board_early_init_r(void)
 {
        const unsigned int flashbase = CONFIG_SYS_FLASH_BASE;
-       const u8 flash_esel = 2;
+       const u8 flash_esel = find_tlb_idx((void *)flashbase, 1);
 
        /*
         * Remap Boot flash + PROMJET region to caching-inhibited
index 4c03468a2453533f96c10662f9fb67231dff1798..3af660e775306710682a233e20512160f858368a 100644 (file)
@@ -131,7 +131,7 @@ int checkboard (void)
 int board_early_init_r(void)
 {
        const unsigned int flashbase = CONFIG_SYS_FLASH_BASE;
-       const u8 flash_esel = 2;
+       const u8 flash_esel = find_tlb_idx((void *)flashbase, 1);
 
        /*
         * Remap Boot flash region to caching-inhibited
index aecb7aa71ad29212cf19da5b9e9a339b7f2c6b0d..599caa235d182e03348c0b4abe957b995eadce06 100644 (file)
@@ -298,7 +298,7 @@ void pci_init_board(void)
 int board_early_init_r(void)
 {
        const unsigned int flashbase = CONFIG_SYS_FLASH_BASE;
-       const u8 flash_esel = 2;
+       const u8 flash_esel = find_tlb_idx((void *)flashbase, 1);
 
        /*
         * Remap Boot flash + PROMJET region to caching-inhibited