X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=board%2Fsocrates%2Fsocrates.c;h=f9e1bc6316489219f258a20f59b2be9b7f8b0810;hb=b8e09898919e23c5d7f1934be7bf9a3a6f0deb0e;hp=25bc664328aa09f923974620a2da554fb099ea45;hpb=1c4b5038afcc7cdb1064713f65571da05aa0de0e;p=platform%2Fkernel%2Fu-boot.git diff --git a/board/socrates/socrates.c b/board/socrates/socrates.c index 25bc664..f9e1bc6 100644 --- a/board/socrates/socrates.c +++ b/board/socrates/socrates.c @@ -16,6 +16,7 @@ #include #include #include +#include #include #include #include @@ -25,15 +26,10 @@ #include #include #include -#include -#include #include "upm_table.h" DECLARE_GLOBAL_DATA_PTR; -extern flash_info_t flash_info[]; /* FLASH chips info */ -extern GraphicDevice mb862xx; - void local_bus_init (void); ulong flash_get_size (ulong base, int banknum); @@ -54,14 +50,15 @@ int checkboard (void) } putc('\n'); -#if defined(CONFIG_PCI) || defined(CONFIG_DM_PCI) +#if defined(CONFIG_PCI) /* Check the PCI_clk sel bit */ if (in_be32(&gur->porpllsr) & (1<<15)) { src = "SYSCLK"; - f = CONFIG_SYS_CLK_FREQ; + f = get_board_sys_clk(); } else { src = "PCI_CLK"; - f = CONFIG_PCI_CLK_FREQ; + /* PCI is clocked by the external source at 33 MHz */ + f = 33000000; } printf ("PCI1: 32 bit, %d MHz (%s)\n", f/1000000, src); #else @@ -131,9 +128,7 @@ int misc_init_r (void) &flash_info[CONFIG_SYS_MAX_FLASH_BANKS - 1]); } -#if defined(CONFIG_DM_PCI) pci_init(); -#endif return 0; } @@ -206,16 +201,6 @@ int ft_board_setup(void *blob, struct bd_info *bd) val[i++] = gd->bd->bi_flashstart; val[i++] = gd->bd->bi_flashsize; -#if defined(CONFIG_VIDEO_MB862xx) - if (mb862xx.frameAdrs == CONFIG_SYS_LIME_BASE) { - /* Fixup LIME mapping */ - val[i++] = 2; /* chip select number */ - val[i++] = 0; /* always 0 */ - val[i++] = CONFIG_SYS_LIME_BASE; - val[i++] = CONFIG_SYS_LIME_SIZE; - } -#endif - /* Fixup FPGA mapping */ val[i++] = 3; /* chip select number */ val[i++] = 0; /* always 0 */ @@ -233,13 +218,15 @@ int ft_board_setup(void *blob, struct bd_info *bd) #endif /* CONFIG_OF_BOARD_SETUP */ #if defined(CONFIG_OF_SEPARATE) -void *board_fdt_blob_setup(void) +void *board_fdt_blob_setup(int *err) { void *fw_dtb; + *err = 0; fw_dtb = (void *)(CONFIG_SYS_TEXT_BASE - CONFIG_ENV_SECT_SIZE); if (fdt_magic(fw_dtb) != FDT_MAGIC) { printf("DTB is not passed via %x\n", (u32)fw_dtb); + *err = -ENXIO; return NULL; }