Message ID | 20180124004454.5759-4-miquel.raynal@free-electrons.com |
---|---|
State | Changes Requested |
Delegated to: | Jagannadha Sutradharudu Teki |
Headers | show |
Series | Bring NAND support to Nintendo NES Classic | expand |
Hi, On Wed, Jan 24, 2018 at 01:44:49AM +0100, Miquel Raynal wrote: > Add some clocks/PLL definitions and the dependency on MACH_SUN8I in > Kconfig so the SPL could be compiled to boards using A33 SoCs. > > Signed-off-by: Miquel Raynal <miquel.raynal@free-electrons.com> The SPL can already be compiled for these platforms. What you're doing is allowing the NAND support to be compiled in the SPL. Maxime
Hi Maxime, On Wed, 24 Jan 2018 08:49:10 +0100 Maxime Ripard <maxime.ripard@free-electrons.com> wrote: > Hi, > > On Wed, Jan 24, 2018 at 01:44:49AM +0100, Miquel Raynal wrote: > > Add some clocks/PLL definitions and the dependency on MACH_SUN8I in > > Kconfig so the SPL could be compiled to boards using A33 SoCs. > > > > Signed-off-by: Miquel Raynal <miquel.raynal@free-electrons.com> > > The SPL can already be compiled for these platforms. What you're doing > is allowing the NAND support to be compiled in the SPL. Corrected. Thanks, Miquèl > > Maxime >
diff --git a/arch/arm/include/asm/arch-sunxi/clock_sun6i.h b/arch/arm/include/asm/arch-sunxi/clock_sun6i.h index d328df9597..d35aa479f7 100644 --- a/arch/arm/include/asm/arch-sunxi/clock_sun6i.h +++ b/arch/arm/include/asm/arch-sunxi/clock_sun6i.h @@ -192,6 +192,7 @@ struct sunxi_ccm_reg { #define ATB_DIV_1 0 #define ATB_DIV_2 1 #define ATB_DIV_4 2 +#define AHB_DIV_1 0 #define CPU_CLK_SRC_OSC24M 1 #define CPU_CLK_SRC_PLL1 2 @@ -317,6 +318,11 @@ struct sunxi_ccm_reg { #define AHB_GATE_OFFSET_LCD0 3 #endif +#define CCM_NAND_CTRL_M(x) ((x) - 1) +#define CCM_NAND_CTRL_N(x) ((x) << 16) +#define CCM_NAND_CTRL_PLL6 (0x1 << 24) +#define CCM_NAND_CTRL_ENABLE (0x1 << 31) + #define CCM_MMC_CTRL_M(x) ((x) - 1) #define CCM_MMC_CTRL_OCLK_DLY(x) ((x) << 8) #define CCM_MMC_CTRL_N(x) ((x) << 16) diff --git a/drivers/mtd/nand/Kconfig b/drivers/mtd/nand/Kconfig index 85b26d6088..2f37a8014d 100644 --- a/drivers/mtd/nand/Kconfig +++ b/drivers/mtd/nand/Kconfig @@ -78,7 +78,7 @@ config NAND_PXA3XX config NAND_SUNXI bool "Support for NAND on Allwinner SoCs" - depends on MACH_SUN4I || MACH_SUN5I || MACH_SUN7I + depends on MACH_SUN4I || MACH_SUN5I || MACH_SUN7I || MACH_SUN8I select SYS_NAND_SELF_INIT select SYS_NAND_U_BOOT_LOCATIONS imply CMD_NAND
Add some clocks/PLL definitions and the dependency on MACH_SUN8I in Kconfig so the SPL could be compiled to boards using A33 SoCs. Signed-off-by: Miquel Raynal <miquel.raynal@free-electrons.com> --- arch/arm/include/asm/arch-sunxi/clock_sun6i.h | 6 ++++++ drivers/mtd/nand/Kconfig | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-)