]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
armv8: ls1012a: Convert CONFIG_LS1012A to Kconfig option ARCH_LS1021A
authorYork Sun <york.sun@nxp.com>
Mon, 26 Sep 2016 15:09:26 +0000 (08:09 -0700)
committerYork Sun <york.sun@nxp.com>
Mon, 26 Sep 2016 15:53:07 +0000 (08:53 -0700)
Move this config to Kconfig option and clean up existing uses.

Signed-off-by: York Sun <york.sun@nxp.com>
CC: Calvin Johnson <calvin.johnson@nxp.com>
CC: Prabhakar Kushwaha <prabhakar.kushwaha@nxp.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
arch/arm/Kconfig
arch/arm/cpu/armv8/fsl-layerscape/Kconfig
arch/arm/cpu/armv8/fsl-layerscape/Makefile
arch/arm/cpu/armv8/fsl-layerscape/fsl_lsch2_speed.c
arch/arm/include/asm/arch-fsl-layerscape/config.h
arch/arm/include/asm/arch-fsl-layerscape/immap_lsch2.h
include/configs/ls1012a_common.h
include/linux/usb/xhci-fsl.h

index aed89c953a56176b4a00a982c8d4f66e4d271659..c974db4ac1bccfacd63d4e3d5ee12e32912e8307 100644 (file)
@@ -788,6 +788,7 @@ config TARGET_HIKEY
 
 config TARGET_LS1012AQDS
        bool "Support ls1012aqds"
+       select ARCH_LS1012A
        select ARM64
        help
          Support for Freescale LS1012AQDS platform.
@@ -797,6 +798,7 @@ config TARGET_LS1012AQDS
 
 config TARGET_LS1012ARDB
        bool "Support ls1012ardb"
+       select ARCH_LS1012A
        select ARM64
        help
          Support for Freescale LS1012ARDB platform.
@@ -806,6 +808,7 @@ config TARGET_LS1012ARDB
 
 config TARGET_LS1012AFRDM
        bool "Support ls1012afrdm"
+       select ARCH_LS1012A
        select ARM64
        help
          Support for Freescale LS1012AFRDM platform.
index c234effa37d362ab2270efe6071749f9e1958e12..a823d393615dfa6476fe644b8cffa89ed7be5028 100644 (file)
@@ -1,2 +1,9 @@
+config ARCH_LS1012A
+       bool "Freescale Layerscape LS1012A SoC"
+       select SYS_FSL_MMDC
+
 config ARCH_LS1046A
        bool "Freescale Layerscape LS1046A SoC"
+
+config SYS_FSL_MMDC
+       bool "Freescale Multi Mode DDR Controller"
index f9590af9a5b3ac4d01b5d0ff1bb0aeb33fe4de80..51c1ceeb838e9e8bc7cd334fe0fd6b231078b508 100644 (file)
@@ -30,7 +30,7 @@ ifneq ($(CONFIG_LS1043A),)
 obj-$(CONFIG_SYS_HAS_SERDES) += ls1043a_serdes.o
 endif
 
-ifneq ($(CONFIG_LS1012A),)
+ifneq ($(CONFIG_ARCH_LS1012A),)
 obj-$(CONFIG_SYS_HAS_SERDES) += ls1012a_serdes.o
 endif
 
index 8922197d439666676371f4591bca5076527baf56..55005f042049b56c8b9c044717d56bb019d77bff 100644 (file)
@@ -60,7 +60,7 @@ void get_sys_info(struct sys_info *sys_info)
        sys_info->freq_ddrbus = sysclk;
 #endif
 
-#ifdef CONFIG_LS1012A
+#ifdef CONFIG_ARCH_LS1012A
        sys_info->freq_ddrbus *= (gur_in32(&gur->rcwsr[0]) >>
                        FSL_CHASSIS2_RCWSR0_SYS_PLL_RAT_SHIFT) &
                        FSL_CHASSIS2_RCWSR0_SYS_PLL_RAT_MASK;
@@ -91,7 +91,7 @@ void get_sys_info(struct sys_info *sys_info)
                        freq_c_pll[cplx_pll] / core_cplx_pll_div[c_pll_sel];
        }
 
-#ifdef CONFIG_LS1012A
+#ifdef CONFIG_ARCH_LS1012A
        sys_info->freq_systembus = sys_info->freq_ddrbus / 2;
        sys_info->freq_ddrbus *= 2;
 #endif
index e7c7d98af0341c41894f41d07125538432274d7c..a7fda1858b7ac0df7029325cb7d558249bfd23a2 100644 (file)
@@ -18,9 +18,7 @@
 #define CONFIG_SYS_FSL_DDRC_ARM_GEN3   /* Enable Freescale ARM DDR3 driver */
 #endif
 
-#ifdef CONFIG_LS1012A
-#define CONFIG_SYS_FSL_MMDC            /* Freescale MMDC driver */
-#else
+#ifndef CONFIG_ARCH_LS1012A
 #define CONFIG_SYS_FSL_DDR             /* Freescale DDR driver */
 #define CONFIG_SYS_FSL_DDR_VER         FSL_DDR_VER_5_0
 #endif
 #define CONFIG_SYS_FSL_ERRATUM_A009942
 #define CONFIG_SYS_FSL_ERRATUM_A009660
 #define CONFIG_SYS_FSL_MAX_NUM_OF_SEC          1
-#elif defined(CONFIG_LS1012A)
+#elif defined(CONFIG_ARCH_LS1012A)
 #define CONFIG_MAX_CPUS                         1
 #undef CONFIG_SYS_FSL_DDRC_ARM_GEN3
 
index 95a42935cac9c20b29f9c2e21802b1d264562b2c..df5187195df32bb19f5bb72a1e56b904db76d37a 100644 (file)
@@ -60,7 +60,7 @@
 #define CONFIG_SYS_PCIE2_PHYS_ADDR             0x4800000000ULL
 #define CONFIG_SYS_PCIE3_PHYS_ADDR             0x5000000000ULL
 /* LUT registers */
-#ifdef CONFIG_LS1012A
+#ifdef CONFIG_ARCH_LS1012A
 #define PCIE_LUT_BASE                          0xC0000
 #else
 #define PCIE_LUT_BASE                          0x10000
index fba2facfbde14a14b0b26fbd0b2d594ca7fdffea..5fb6c477b409f116d37fcf2e73f62fed1ba6c2dd 100644 (file)
@@ -9,7 +9,6 @@
 
 #define CONFIG_FSL_LAYERSCAPE
 #define CONFIG_FSL_LSCH2
-#define CONFIG_LS1012A
 #define CONFIG_GICV2
 
 #define        CONFIG_SYS_HAS_SERDES
index 199f3667eb4f4371d9813ba2a68defc7354f2c3c..d04e3cc95a57b00d5d4efd3d29afad63310e695f 100644 (file)
@@ -51,7 +51,7 @@ struct fsl_xhci {
        struct dwc3 *dwc3_reg;
 };
 
-#if defined(CONFIG_LS102XA) || defined(CONFIG_LS1012A)
+#if defined(CONFIG_LS102XA) || defined(CONFIG_ARCH_LS1012A)
 #define CONFIG_SYS_FSL_XHCI_USB1_ADDR CONFIG_SYS_XHCI_USB1_ADDR
 #define CONFIG_SYS_FSL_XHCI_USB2_ADDR 0
 #define CONFIG_SYS_FSL_XHCI_USB3_ADDR 0