Commit 323d1f9d authored by Masahiro Yamada's avatar Masahiro Yamada

ARM: uniphier: allow to enable multiple SoCs

Before this commit, the Kconfig menu in mach-uniphier only allowed us
to choose one SoC to be compiled.  Each SoC has its own defconfig file
for the build-test coverage.  Consequently, some defconfig files are
duplicated with only the difference in CONFIG_DEFAULT_DEVICE_TREE and
CONFIG_{SOC_NAME}=y.

Now, most of board-specific parameters have been moved to device trees,
so it makes sense to include init code of multiple SoCs into a single
image as long as the SoCs have similar architecture.  In fact, some
SoCs of UniPhier family are very similar:
 - PH1-LD4 and PH1-sLD8
 - PH1-LD6b and ProXstream2 (will be added in the upcoming commit)

This commit will be helpful to merge some defconfig files for better
maintainability.
Signed-off-by: default avatarMasahiro Yamada <yamada.masahiro@socionext.com>
parent 5451b777
......@@ -6,25 +6,32 @@ config SYS_CONFIG_NAME
config UNIPHIER_SMP
bool
choice
prompt "UniPhier SoC select"
default ARCH_UNIPHIER_PH1_PRO4
config ARCH_UNIPHIER_PH1_SLD3
bool "PH1-sLD3"
bool "UniPhier PH1-sLD3 SoC"
select UNIPHIER_SMP
help
This enables support for UniPhier PH1-sLD3 SoC.
config ARCH_UNIPHIER_PH1_LD4
bool "PH1-LD4"
bool "UniPhier PH1-LD4 SoC"
depends on !ARCH_UNIPHIER_PH1_SLD3
help
This enables support for UniPhier PH1-LD4 SoC.
config ARCH_UNIPHIER_PH1_PRO4
bool "PH1-Pro4"
bool "UniPhier PH1-Pro4 SoC"
select UNIPHIER_SMP
depends on !ARCH_UNIPHIER_PH1_SLD3 && \
!ARCH_UNIPHIER_PH1_LD4 && \
!ARCH_UNIPHIER_PH1_SLD8
help
This enables support for UniPhier PH1-Pro4 SoC.
config ARCH_UNIPHIER_PH1_SLD8
bool "PH1-sLD8"
endchoice
bool "UniPhier PH1-sLD8 SoC"
depends on !ARCH_UNIPHIER_PH1_SLD3
help
This enables support for UniPhier PH1-sLD8 SoC.
config MICRO_SUPPORT_CARD
bool "Use Micro Support Card"
......@@ -48,22 +55,4 @@ config CMD_DDRPHY_DUMP
The command "ddrphy" shows the resulting parameters of DDR PHY
training; it is useful for the evaluation of DDR PHY training.
choice
prompt "DDR3 Frequency select"
config DDR_FREQ_1600
bool "DDR3 1600"
depends on ARCH_UNIPHIER_PH1_SLD3 || ARCH_UNIPHIER_PH1_LD4 || ARCH_UNIPHIER_PH1_PRO4
config DDR_FREQ_1333
bool "DDR3 1333"
depends on ARCH_UNIPHIER_PH1_SLD3 || ARCH_UNIPHIER_PH1_LD4 || ARCH_UNIPHIER_PH1_SLD8
endchoice
config DDR_FREQ
int
default 1333 if DDR_FREQ_1333
default 1600 if DDR_FREQ_1600
endif
......@@ -6,9 +6,10 @@ ifdef CONFIG_SPL_BUILD
obj-y += lowlevel_init.o
obj-y += init_page_table.o
obj-y += spl.o
obj-y += memconf.o
obj-y += ddrphy_training.o
obj-y += boards.o
obj-y += init/ bcu/ memconf/ pll/ early-clk/ early-pinctrl/ umc/ ddrphy/
obj-$(CONFIG_MICRO_SUPPORT_CARD) += sbc/
obj-$(CONFIG_DEBUG_LL) += debug_ll.o
......@@ -27,13 +28,12 @@ obj-y += cache_uniphier.o
obj-$(CONFIG_CMD_PINMON) += cmd_pinmon.o
obj-$(CONFIG_CMD_DDRPHY_DUMP) += cmd_ddrphy.o
obj-y += pinctrl/ clk/
endif
obj-y += timer.o
obj-y += soc_info.o
obj-y += boot-mode/
obj-$(CONFIG_MICRO_SUPPORT_CARD) += micro-support-card.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD3) += ph1-sld3/
obj-$(CONFIG_ARCH_UNIPHIER_PH1_LD4) += ph1-ld4/
obj-$(CONFIG_ARCH_UNIPHIER_PH1_PRO4) += ph1-pro4/
obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD8) += ph1-sld8/
obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD3) += bcu-ph1-sld3.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_LD4) += bcu-ph1-ld4.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD8) += bcu-ph1-ld4.o
......@@ -4,13 +4,13 @@
* SPDX-License-Identifier: GPL-2.0+
*/
#include <common.h>
#include <linux/io.h>
#include <mach/bcu-regs.h>
#include <mach/init.h>
#define ch(x) ((x) >= 32 ? 0 : (x) < 0 ? 0x11111111 : 0x11111111 << (x))
void bcu_init(void)
int ph1_ld4_bcu_init(const struct uniphier_board_data *bd)
{
int shift;
......@@ -21,7 +21,7 @@ void bcu_init(void)
writel(0x11111111, BCSCR5); /* 0xe0000000-0Xffffffff: IPPC/IPPD-bus */
/* Specify DDR channel */
shift = (CONFIG_SDRAM1_BASE - CONFIG_SDRAM0_BASE) / 0x04000000 * 4;
shift = (bd->dram_ch1_base - bd->dram_ch0_base) / 0x04000000 * 4;
writel(ch(shift), BCIPPCCHR2); /* 0x80000000-0x9fffffff */
shift -= 32;
......@@ -29,4 +29,6 @@ void bcu_init(void)
shift -= 32;
writel(ch(shift), BCIPPCCHR4); /* 0xc0000000-0xdfffffff */
return 0;
}
......@@ -4,13 +4,13 @@
* SPDX-License-Identifier: GPL-2.0+
*/
#include <common.h>
#include <linux/io.h>
#include <mach/bcu-regs.h>
#include <mach/init.h>
#define ch(x) ((x) >= 32 ? 0 : (x) < 0 ? 0x11111111 : 0x11111111 << (x))
void bcu_init(void)
int ph1_sld3_bcu_init(const struct uniphier_board_data *bd)
{
int shift;
......@@ -25,7 +25,7 @@ void bcu_init(void)
writel(0x24440000, BCSCR5);
/* Specify DDR channel */
shift = (CONFIG_SDRAM1_BASE - CONFIG_SDRAM0_BASE) / 0x04000000 * 4;
shift = (bd->dram_ch1_base - bd->dram_ch0_base) / 0x04000000 * 4;
writel(ch(shift), BCIPPCCHR2); /* 0x80000000-0x9fffffff */
shift -= 32;
......@@ -33,4 +33,6 @@ void bcu_init(void)
shift -= 32;
writel(ch(shift), BCIPPCCHR4); /* 0xc0000000-0xdfffffff */
return 0;
}
......@@ -4,20 +4,46 @@
* SPDX-License-Identifier: GPL-2.0+
*/
#include <mach/init.h>
#include <mach/micro-support-card.h>
void pin_init(void);
void clkrst_init(void);
#include <mach/soc_info.h>
int board_early_init_f(void)
{
led_puts("U0");
pin_init();
led_puts("U1");
clkrst_init();
switch (uniphier_get_soc_type()) {
#if defined(CONFIG_ARCH_UNIPHIER_PH1_SLD3)
case SOC_UNIPHIER_PH1_SLD3:
ph1_sld3_pin_init();
led_puts("U1");
ph1_ld4_clk_init();
break;
#endif
#if defined(CONFIG_ARCH_UNIPHIER_PH1_LD4)
case SOC_UNIPHIER_PH1_LD4:
ph1_ld4_pin_init();
led_puts("U1");
ph1_ld4_clk_init();
break;
#endif
#if defined(CONFIG_ARCH_UNIPHIER_PH1_PRO4)
case SOC_UNIPHIER_PH1_PRO4:
ph1_pro4_pin_init();
led_puts("U1");
ph1_pro4_clk_init();
break;
#endif
#if defined(CONFIG_ARCH_UNIPHIER_PH1_SLD8)
case SOC_UNIPHIER_PH1_SLD8:
ph1_sld8_pin_init();
led_puts("U1");
ph1_ld4_clk_init();
break;
#endif
default:
break;
}
led_puts("U2");
......
/*
* Copyright (C) 2015 Masahiro Yamada <yamada.masahiro@socionext.com>
*
* SPDX-License-Identifier: GPL-2.0+
*/
#include <libfdt.h>
#include <linux/kernel.h>
#include <mach/init.h>
#if defined(CONFIG_ARCH_UNIPHIER_PH1_SLD3)
static const struct uniphier_board_data ph1_sld3_data = {
.dram_ch0_base = 0x80000000,
.dram_ch0_size = 0x20000000,
.dram_ch0_width = 32,
.dram_ch1_base = 0xc0000000,
.dram_ch1_size = 0x20000000,
.dram_ch1_width = 16,
.dram_ch2_base = 0xc0000000,
.dram_ch2_size = 0x10000000,
.dram_ch2_width = 16,
.dram_freq = 1600,
};
#endif
#if defined(CONFIG_ARCH_UNIPHIER_PH1_LD4)
static const struct uniphier_board_data ph1_ld4_data = {
.dram_ch0_base = 0x80000000,
.dram_ch0_size = 0x10000000,
.dram_ch0_width = 16,
.dram_ch1_base = 0x90000000,
.dram_ch1_size = 0x10000000,
.dram_ch1_width = 16,
.dram_freq = 1600,
};
#endif
#if defined(CONFIG_ARCH_UNIPHIER_PH1_PRO4)
static const struct uniphier_board_data ph1_pro4_data = {
.dram_ch0_base = 0x80000000,
.dram_ch0_size = 0x20000000,
.dram_ch0_width = 32,
.dram_ch1_base = 0xa0000000,
.dram_ch1_size = 0x20000000,
.dram_ch1_width = 32,
.dram_freq = 1600,
};
#endif
#if defined(CONFIG_ARCH_UNIPHIER_PH1_SLD8)
static const struct uniphier_board_data ph1_sld8_data = {
.dram_ch0_base = 0x80000000,
.dram_ch0_size = 0x10000000,
.dram_ch0_width = 16,
.dram_ch1_base = 0x90000000,
.dram_ch1_size = 0x10000000,
.dram_ch1_width = 16,
.dram_freq = 1333,
};
#endif
struct uniphier_board_id {
const char *compatible;
const struct uniphier_board_data *param;
};
static const struct uniphier_board_id uniphier_boards[] = {
#if defined(CONFIG_ARCH_UNIPHIER_PH1_SLD3)
{ "socionext,ph1-sld3", &ph1_sld3_data, },
#endif
#if defined(CONFIG_ARCH_UNIPHIER_PH1_LD4)
{ "socionext,ph1-ld4", &ph1_ld4_data, },
#endif
#if defined(CONFIG_ARCH_UNIPHIER_PH1_PRO4)
{ "socionext,ph1-pro4", &ph1_pro4_data, },
#endif
#if defined(CONFIG_ARCH_UNIPHIER_PH1_SLD8)
{ "socionext,ph1-sld8", &ph1_sld8_data, },
#endif
};
const struct uniphier_board_data *uniphier_get_board_param(const void *fdt)
{
int i;
for (i = 0; i < ARRAY_SIZE(uniphier_boards); i++) {
if (!fdt_node_check_compatible(fdt, 0,
uniphier_boards[i].compatible))
return uniphier_boards[i].param;
}
return NULL;
}
obj-y += boot-mode.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD3) += boot-mode-ph1-sld3.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_LD4) += boot-mode-ph1-ld4.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_PRO4) += boot-mode-ph1-ld4.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD8) += boot-mode-ph1-ld4.o
......@@ -44,22 +44,31 @@ struct boot_device_info boot_device_table[] = {
{BOOT_DEVICE_NONE, "Reserved"},
{BOOT_DEVICE_NONE, "Reserved"},
{BOOT_DEVICE_NONE, "Reserved"},
{ /* sentinel */ }
};
int get_boot_mode_sel(void)
static int get_boot_mode_sel(void)
{
return (readl(SG_PINMON0) >> 1) & 0x1f;
}
u32 spl_boot_device(void)
u32 ph1_ld4_boot_device(void)
{
int boot_mode;
if (boot_is_swapped())
return BOOT_DEVICE_NOR;
boot_mode = get_boot_mode_sel();
return boot_device_table[boot_mode].type;
}
void ph1_ld4_boot_mode_show(void)
{
int mode_sel, i;
mode_sel = get_boot_mode_sel();
puts("Boot Mode Pin:\n");
for (i = 0; i < ARRAY_SIZE(boot_device_table); i++)
printf(" %c %02x %s\n", i == mode_sel ? '*' : ' ', i,
boot_device_table[i].info);
}
......@@ -11,7 +11,7 @@
#include <mach/sg-regs.h>
#include <mach/sbc-regs.h>
struct boot_device_info boot_device_table[] = {
static struct boot_device_info boot_device_table[] = {
{BOOT_DEVICE_NONE, "Reserved"},
{BOOT_DEVICE_NONE, "External Master"},
{BOOT_DEVICE_NONE, "Reserved"},
......@@ -76,22 +76,31 @@ struct boot_device_info boot_device_table[] = {
{BOOT_DEVICE_NONE, "Reserved"},
{BOOT_DEVICE_NONE, "Reserved"},
{BOOT_DEVICE_NONE, "Reserved"},
{ /* sentinel */ }
};
int get_boot_mode_sel(void)
static int get_boot_mode_sel(void)
{
return readl(SG_PINMON0) & 0x3f;
}
u32 spl_boot_device(void)
u32 ph1_sld3_boot_device(void)
{
int boot_mode;
if (boot_is_swapped())
return BOOT_DEVICE_NOR;
boot_mode = get_boot_mode_sel();
return boot_device_table[boot_mode].type;
}
void ph1_sld3_boot_mode_show(void)
{
int mode_sel, i;
mode_sel = get_boot_mode_sel();
puts("Boot Mode Pin:\n");
for (i = 0; i < ARRAY_SIZE(boot_device_table); i++)
printf(" %c %02x %s\n", i == mode_sel ? '*' : ' ', i,
boot_device_table[i].info);
}
/*
* Copyright (C) 2015 Masahiro Yamada <yamada.masahiro@socionext.com>
*
* SPDX-License-Identifier: GPL-2.0+
*/
#include <common.h>
#include <spl.h>
#include <linux/io.h>
#include <mach/boot-device.h>
#include <mach/sbc-regs.h>
#include <mach/soc_info.h>
u32 spl_boot_device(void)
{
if (boot_is_swapped())
return BOOT_DEVICE_NOR;
switch (uniphier_get_soc_type()) {
#if defined(CONFIG_ARCH_UNIPHIER_PH1_SLD3)
case SOC_UNIPHIER_PH1_SLD3:
return ph1_sld3_boot_device();
#endif
#if defined(CONFIG_ARCH_UNIPHIER_PH1_LD4) || \
defined(CONFIG_ARCH_UNIPHIER_PH1_PRO4) || \
defined(CONFIG_ARCH_UNIPHIER_PH1_SLD8)
case SOC_UNIPHIER_PH1_LD4:
case SOC_UNIPHIER_PH1_PRO4:
case SOC_UNIPHIER_PH1_SLD8:
return ph1_ld4_boot_device();
#endif
default:
return BOOT_DEVICE_NONE;
}
}
obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD3) += clk-ph1-ld4.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_LD4) += clk-ph1-ld4.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_PRO4) += clk-ph1-pro4.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD8) += clk-ph1-ld4.o
......@@ -5,9 +5,10 @@
*/
#include <linux/io.h>
#include <mach/init.h>
#include <mach/sc-regs.h>
void clkrst_init(void)
void ph1_ld4_clk_init(void)
{
u32 tmp;
......
......@@ -5,9 +5,10 @@
*/
#include <linux/io.h>
#include <mach/init.h>
#include <mach/sc-regs.h>
void clkrst_init(void)
void ph1_pro4_clk_init(void)
{
u32 tmp;
......
/*
* Copyright (C) 2014 Panasonic Corporation
* Author: Masahiro Yamada <yamada.m@jp.panasonic.com>
* Copyright (C) 2014-2015 Masahiro Yamada <yamada.masahiro@socionext.com>
*
* SPDX-License-Identifier: GPL-2.0+
*/
......@@ -8,20 +7,30 @@
#include <common.h>
#include <mach/boot-device.h>
#include <mach/sbc-regs.h>
#include <mach/soc_info.h>
static int do_pinmon(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
{
int mode_sel, i;
printf("Boot Swap: %s\n\n", boot_is_swapped() ? "ON" : "OFF");
mode_sel = get_boot_mode_sel();
puts("Boot Mode Pin:\n");
for (i = 0; boot_device_table[i].info; i++)
printf(" %c %02x %s\n", i == mode_sel ? '*' : ' ', i,
boot_device_table[i].info);
switch (uniphier_get_soc_type()) {
#if defined(CONFIG_ARCH_UNIPHIER_PH1_SLD3)
case SOC_UNIPHIER_PH1_SLD3:
ph1_sld3_boot_mode_show();
break;
#endif
#if defined(CONFIG_ARCH_UNIPHIER_PH1_LD4) || \
defined(CONFIG_ARCH_UNIPHIER_PH1_PRO4) || \
defined(CONFIG_ARCH_UNIPHIER_PH1_SLD8)
case SOC_UNIPHIER_PH1_LD4:
case SOC_UNIPHIER_PH1_PRO4:
case SOC_UNIPHIER_PH1_SLD8:
ph1_ld4_boot_mode_show();
break;
#endif
default:
break;
}
return 0;
}
......
obj-$(CONFIG_ARCH_UNIPHIER_PH1_LD4) += ddrphy-training.o ddrphy-ph1-ld4.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_PRO4) += ddrphy-training.o ddrphy-ph1-pro4.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD8) += ddrphy-training.o ddrphy-ph1-sld8.o
......@@ -8,7 +8,7 @@
#include <linux/io.h>
#include <mach/ddrphy-regs.h>
void ddrphy_init(struct ddrphy __iomem *phy, int freq, int size)
int ph1_ld4_ddrphy_init(struct ddrphy __iomem *phy, int freq, int size)
{
u32 tmp;
......@@ -67,4 +67,6 @@ void ddrphy_init(struct ddrphy __iomem *phy, int freq, int size)
writel(0x0300C473, &phy->pgcr[1]);
writel(0x0000005D, &phy->zq[0].cr[1]);
return 0;
}
......@@ -8,7 +8,7 @@
#include <linux/io.h>
#include <mach/ddrphy-regs.h>
void ddrphy_init(struct ddrphy __iomem *phy, int freq, int size)
int ph1_pro4_ddrphy_init(struct ddrphy __iomem *phy, int freq, int size)
{
u32 tmp;
......@@ -67,4 +67,6 @@ void ddrphy_init(struct ddrphy __iomem *phy, int freq, int size)
writel(0x0300C473, &phy->pgcr[1]);
writel(0x0000005D, &phy->zq[0].cr[1]);
return 0;
}
......@@ -9,7 +9,7 @@
#include <linux/io.h>
#include <mach/ddrphy-regs.h>
void ddrphy_init(struct ddrphy __iomem *phy, int freq, int size)
int ph1_sld8_ddrphy_init(struct ddrphy __iomem *phy, int freq, int size)
{
u32 tmp;
......@@ -72,4 +72,6 @@ void ddrphy_init(struct ddrphy __iomem *phy, int freq, int size)
writel(0x0300C473, &phy->pgcr[1]);
writel(0x0000005D, &phy->zq[0].cr[1]);
return 0;
}
obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD3) += early-clk-ph1-ld4.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_LD4) += early-clk-ph1-ld4.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_PRO4) += early-clk-ph1-ld4.o
obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD8) += early-clk-ph1-ld4.o
......@@ -7,9 +7,10 @@
#include <common.h>
#include <spl.h>
#include <linux/io.h>
#include <mach/init.h>
#include <mach/sc-regs.h>
void early_clkrst_init(void)
int ph1_ld4_early_clk_init(const struct uniphier_board_data *bd)
{
u32 tmp;
......@@ -27,4 +28,6 @@ void early_clkrst_init(void)
tmp |= SC_CLKCTRL_CEN_UMC | SC_CLKCTRL_CEN_SBC | SC_CLKCTRL_CEN_PERI;
writel(tmp, SC_CLKCTRL);
readl(SC_CLKCTRL); /* dummy read */
return 0;
}
obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD3) += early-pinctrl-ph1-sld3.o
......@@ -4,9 +4,10 @@
* SPDX-License-Identifier: GPL-2.0+
*/
#include <mach/init.h>
#include <mach/sg-regs.h>
void early_pin_init(void)
int ph1_sld3_early_pin_init(const struct uniphier_board_data *bd)
{
/* Comment format: PAD Name -> Function Name */
......@@ -20,4 +21,6 @@ void early_pin_init(void)
sg_set_pinsel(96, 2, 4, 4); /* RXD2 */
sg_set_pinsel(102, 2, 4, 4); /* TXD2 */
#endif
return 0;
}
/*
* Copyright (C) 2011-2014 Panasonic Corporation
* Author: Masahiro Yamada <yamada.m@jp.panasonic.com>
* Copyright (C) 2011-2015 Masahiro Yamada <yamada.masahiro@socionext.com>
*
* SPDX-License-Identifier: GPL-2.0+
*/
......@@ -8,13 +7,15 @@
#ifndef _ASM_BOOT_DEVICE_H_
#define _ASM_BOOT_DEVICE_H_
int get_boot_mode_sel(void);
struct boot_device_info {
u32 type;
char *info;
};
extern struct boot_device_info boot_device_table[];
u32 ph1_sld3_boot_device(void);
u32 ph1_ld4_boot_device(void);
void ph1_sld3_boot_mode_show(void);
void ph1_ld4_boot_mode_show(void);
#endif /* _ASM_BOOT_DEVICE_H_ */
......@@ -168,7 +168,9 @@ struct ddrphy {
#define DDRPHY_BASE(ch, phy) (0x5bc01000 + 0x200000 * (ch) + 0x1000 * (phy))
#ifndef __ASSEMBLY__
void ddrphy_init(struct ddrphy __iomem *phy, int freq, int size);
int ph1_ld4_ddrphy_init(struct ddrphy __iomem *phy, int freq, int size);
int ph1_pro4_ddrphy_init(struct ddrphy __iomem *phy, int freq, int size);
int ph1_sld8_ddrphy_init(struct ddrphy __iomem *phy, int freq, int size);
void ddrphy_prepare_training(struct ddrphy __iomem *phy, int rank);
int ddrphy_training(struct ddrphy __iomem *phy);
#endif
......
/*
* Copyright (C) 2015 Masahiro Yamada <yamada.masahiro@socionext.com>
*
* SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __MACH_INIT_H
#define __MACH_INIT_H
struct uniphier_board_data {
unsigned long dram_ch0_base;
unsigned long dram_ch0_size;
unsigned long dram_ch0_width;
unsigned long dram_ch1_base;
unsigned long dram_ch1_size;
unsigned long dram_ch1_width;
unsigned long dram_ch2_base;
unsigned long dram_ch2_size;
unsigned long dram_ch2_width;
unsigned int dram_freq;
};
const struct uniphier_board_data *uniphier_get_board_param(const void *fdt);
int ph1_sld3_init(const struct uniphier_board_data *bd);
int ph1_ld4_init(const struct uniphier_board_data *bd);
int ph1_pro4_init(const struct uniphier_board_data *bd);
int ph1_sld8_init(const struct uniphier_board_data *bd);
#if defined(CONFIG_MICRO_SUPPORT_CARD)