]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
Convert CONFIG_SYS_PMAN et al to Kconfig
authorTom Rini <trini@konsulko.com>
Wed, 16 Nov 2022 18:10:34 +0000 (13:10 -0500)
committerTom Rini <trini@konsulko.com>
Mon, 5 Dec 2022 21:06:07 +0000 (16:06 -0500)
This converts the following to Kconfig:
   CONFIG_NOBQFMAN
   CONFIG_SYS_DPAA_DCE
   CONFIG_SYS_DPAA_FMAN
   CONFIG_SYS_DPAA_PME
   CONFIG_SYS_DPAA_RMAN
   CONFIG_SYS_PMAN

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
16 files changed:
arch/Kconfig.nxp
arch/arm/cpu/armv8/fsl-layerscape/Kconfig
arch/arm/cpu/armv8/fsl-layerscape/fsl_lsch2_speed.c
arch/arm/cpu/armv8/fsl-layerscape/icid.c
arch/arm/cpu/armv8/fsl-layerscape/ls1043_ids.c
arch/arm/cpu/armv8/fsl-layerscape/ls1046_ids.c
arch/powerpc/cpu/mpc85xx/Kconfig
include/configs/P2041RDB.h
include/configs/T102xRDB.h
include/configs/T104xRDB.h
include/configs/T208xQDS.h
include/configs/T208xRDB.h
include/configs/T4240RDB.h
include/configs/kmcent2.h
include/configs/ls1043a_common.h
include/configs/ls1046a_common.h

index 8c5a6f63a9a5873367791e5238cd5b61752cd2d6..805fe934a1f50f82e8b3ee7cb322fabebfa7f136 100644 (file)
@@ -251,3 +251,6 @@ config QIXIS_I2C_ACCESS
 config HAS_FSL_DR_USB
        def_bool y
        depends on USB_EHCI_HCD && PPC
+
+config SYS_DPAA_FMAN
+       bool
index ebca11d17419106d64b79ce02ee1d810b3308cc6..2862257e1f2c5bd742a63a70d38f75982daa6543 100644 (file)
@@ -69,6 +69,7 @@ config ARCH_LS1043A
        select GICV2
        select HAS_FSL_XHCI_USB if USB_HOST
        select SKIP_LOWLEVEL_INIT
+       select SYS_DPAA_FMAN
        select SYS_FSL_SRDS_1
        select SYS_HAS_SERDES
        select SYS_FSL_DDR
@@ -106,6 +107,7 @@ config ARCH_LS1046A
        select GICV2
        select HAS_FSL_XHCI_USB if USB_HOST
        select SKIP_LOWLEVEL_INIT
+       select SYS_DPAA_FMAN
        select SYS_FSL_SRDS_1
        select SYS_HAS_SERDES
        select SYS_FSL_DDR
index 6440ce714fd19c257519b246fb784e04196547fd..f18407b6d3bb47a1d0ba0d84a45fe2c5d6a49896 100644 (file)
@@ -24,11 +24,7 @@ void get_sys_info(struct sys_info *sys_info)
 /* rcw_tmp is needed to get FMAN clock, or to get cluster group A
  * mux 2 clock for LS1043A/LS1046A.
  */
-#if defined(CONFIG_SYS_DPAA_FMAN) || \
-           defined(CONFIG_ARCH_LS1046A) || \
-           defined(CONFIG_ARCH_LS1043A)
-       u32 rcw_tmp;
-#endif
+       __maybe_unused u32 rcw_tmp;
        struct ccsr_clk *clk = (void *)(CFG_SYS_FSL_CLK_ADDR);
        unsigned int cpu;
        const u8 core_cplx_pll[8] = {
@@ -96,7 +92,7 @@ void get_sys_info(struct sys_info *sys_info)
 
 #define HWA_CGA_M1_CLK_SEL     0xe0000000
 #define HWA_CGA_M1_CLK_SHIFT   29
-#ifdef CONFIG_SYS_DPAA_FMAN
+#if defined(CONFIG_SYS_DPAA_FMAN) && !defined(CONFIG_SPL_BUILD)
        rcw_tmp = in_be32(&gur->rcwsr[7]);
        switch ((rcw_tmp & HWA_CGA_M1_CLK_SEL) >> HWA_CGA_M1_CLK_SHIFT) {
        case 2:
index e972603f24f8fef49223a7043bdddb7b7f651f95..ad20d71717b34ceb220255e8f7be588327a9c95d 100644 (file)
@@ -41,7 +41,7 @@ void set_icids(void)
        /* setup general icid offsets */
        set_icid(icid_tbl, icid_tbl_sz);
 
-#ifdef CONFIG_SYS_DPAA_FMAN
+#if defined(CONFIG_SYS_DPAA_FMAN) && !defined(CONFIG_SPL_BUILD)
        set_fman_icids(fman_icid_tbl, fman_icid_tbl_sz);
 #endif
 }
index 3bd993bebfbc0ee85cca479a53f29ebf8a5e6dd8..4880a313ea6adb920ff233e7e9441eed39a92f76 100644 (file)
@@ -59,7 +59,7 @@ struct icid_id_table icid_tbl[] = {
 
 int icid_tbl_sz = ARRAY_SIZE(icid_tbl);
 
-#ifdef CONFIG_SYS_DPAA_FMAN
+#if defined(CONFIG_SYS_DPAA_FMAN) && !defined(CONFIG_SPL_BUILD)
 struct fman_icid_id_table fman_icid_tbl[] = {
        /* port id, icid */
        SET_FMAN_ICID_ENTRY(0x02, FSL_DPAA1_STREAM_ID_END),
index abd847b5be025e1aa182b9ea36750a1adc18d0cb..e47d3af85e07fd7266af0d2e23208045f62ab379 100644 (file)
@@ -58,7 +58,7 @@ struct icid_id_table icid_tbl[] = {
 
 int icid_tbl_sz = ARRAY_SIZE(icid_tbl);
 
-#ifdef CONFIG_SYS_DPAA_FMAN
+#if defined(CONFIG_SYS_DPAA_FMAN) && !defined(CONFIG_SPL_BUILD)
 struct fman_icid_id_table fman_icid_tbl[] = {
        /* port id, icid */
        SET_FMAN_ICID_ENTRY(0x02, FSL_DPAA1_STREAM_ID_END),
index 24d3f1f20c2530d57f94cee76c536ab65190f28b..f2361560e9ade62c4e3608c954c1dc9b60d8bd3d 100644 (file)
@@ -252,6 +252,8 @@ config TARGET_KMCENT2
        bool "Support kmcent2"
        select VENDOR_KM
        select FSL_CORENET
+       select SYS_DPAA_FMAN
+       select SYS_DPAA_PME
        select SYS_L3_SIZE_256KB
 
 endchoice
@@ -618,6 +620,9 @@ config ARCH_P2041
        select E500MC
        select FSL_LAW
        select SYS_CACHE_SHIFT_6
+       select SYS_DPAA_FMAN
+       select SYS_DPAA_PME
+       select SYS_DPAA_RMAN
        select SYS_FSL_ERRATUM_A004510
        select SYS_FSL_ERRATUM_A004849
        select SYS_FSL_ERRATUM_A005275
@@ -762,6 +767,7 @@ config ARCH_T1024
        select FSL_CORENET
        select FSL_LAW
        select SYS_CACHE_SHIFT_6
+       select SYS_DPAA_FMAN
        select SYS_FSL_DDR_VER_50
        select SYS_FSL_ERRATUM_A008378
        select SYS_FSL_ERRATUM_A008109
@@ -792,6 +798,8 @@ config ARCH_T1040
        select FSL_CORENET
        select FSL_LAW
        select SYS_CACHE_SHIFT_6
+       select SYS_DPAA_FMAN
+       select SYS_DPAA_PME
        select SYS_FSL_DDR_VER_50
        select SYS_FSL_ERRATUM_A008044
        select SYS_FSL_ERRATUM_A008378
@@ -822,6 +830,8 @@ config ARCH_T1042
        select FSL_CORENET
        select FSL_LAW
        select SYS_CACHE_SHIFT_6
+       select SYS_DPAA_FMAN
+       select SYS_DPAA_PME
        select SYS_FSL_DDR_VER_50
        select SYS_FSL_ERRATUM_A008044
        select SYS_FSL_ERRATUM_A008378
@@ -851,6 +861,10 @@ config ARCH_T2080
        select FSL_CORENET
        select FSL_LAW
        select SYS_CACHE_SHIFT_6
+       select SYS_DPAA_DCE if !NOBQFMAN
+       select SYS_DPAA_FMAN if !NOBQFMAN
+       select SYS_DPAA_PME if !NOBQFMAN
+       select SYS_DPAA_RMAN if !NOBQFMAN
        select SYS_FSL_DDR_VER_47
        select SYS_FSL_ERRATUM_A006379
        select SYS_FSL_ERRATUM_A006593
@@ -871,6 +885,7 @@ config ARCH_T2080
        select SYS_FSL_SRIO_LIODN
        select SYS_FSL_QMAN_V3 if SYS_DPAA_QBMAN
        select SYS_FSL_USB_DUAL_PHY_ENABLE
+       select SYS_PMAN if !NOBQFMAN
        select SYS_PPC64
        select FSL_IFC
        imply CMD_SATA
@@ -886,6 +901,10 @@ config ARCH_T4240
        select FSL_CORENET
        select FSL_LAW
        select SYS_CACHE_SHIFT_6
+       select SYS_DPAA_DCE if !NOBQFMAN
+       select SYS_DPAA_FMAN if !NOBQFMAN
+       select SYS_DPAA_PME if !NOBQFMAN
+       select SYS_DPAA_RMAN if !NOBQFMAN
        select SYS_FSL_DDR_VER_47
        select SYS_FSL_ERRATUM_A004468
        select SYS_FSL_ERRATUM_A005871
@@ -907,6 +926,7 @@ config ARCH_T4240
        select SYS_FSL_SRIO_LIODN
        select SYS_FSL_QMAN_V3 if SYS_DPAA_QBMAN
        select SYS_FSL_USB_DUAL_PHY_ENABLE
+       select SYS_PMAN if !NOBQFMAN
        select SYS_PPC64
        select FSL_IFC
        imply CMD_SATA
@@ -947,6 +967,9 @@ config E6500
        help
                Enable PowerPC E6500 core
 
+config NOBQFMAN
+       bool
+
 config FSL_LAW
        bool
        help
@@ -1019,6 +1042,15 @@ config SYS_CCSRBAR_DEFAULT
                if changed by pre-boot regime. The value here must match
                the current value in SoC. If not sure, do not change.
 
+config SYS_DPAA_PME
+       bool
+
+config SYS_DPAA_DCE
+       bool
+
+config SYS_DPAA_RMAN
+       bool
+
 config A003399_NOR_WORKAROUND
        bool
        help
@@ -1195,6 +1227,9 @@ config FSL_PCIE_DISABLE_ASPM
 config FSL_PCIE_RESET
        bool
 
+config SYS_PMAN
+       bool
+
 config SYS_FSL_RAID_ENGINE
        bool
 
index e996dbaa4de71537dee0c4a691cbb14680aeac63..8c7b877bfb925dedb766f4eace1873f37765c61d 100644 (file)
@@ -36,7 +36,6 @@
 #define CONFIG_SRIO1                   /* SRIO port 1 */
 #define CONFIG_SRIO2                   /* SRIO port 2 */
 #define CONFIG_SRIO_PCIE_BOOT_MASTER
-#define CONFIG_SYS_DPAA_RMAN           /* RMan */
 
 #ifndef __ASSEMBLY__
 #include <linux/stringify.h>
 #define CONFIG_SYS_QMAN_CINH_SIZE       (CONFIG_SYS_QMAN_MEM_SIZE >> 1)
 #define CONFIG_SYS_QMAN_SWP_ISDR_REG   0xE08
 
-#define CONFIG_SYS_DPAA_FMAN
-#define CONFIG_SYS_DPAA_PME
-
 #ifdef CONFIG_FMAN_ENET
 #define CONFIG_SYS_FM1_DTSEC1_PHY_ADDR 0x2
 #define CONFIG_SYS_FM1_DTSEC2_PHY_ADDR 0x3
index 6d6e334bf00fa5a35d05f0708e28b06c201be39b..154b2f174afb00f7122605700fa001caa948a64d 100644 (file)
                                        CONFIG_SYS_QMAN_CENA_SIZE)
 #define CONFIG_SYS_QMAN_CINH_SIZE       (CONFIG_SYS_QMAN_MEM_SIZE >> 1)
 #define CONFIG_SYS_QMAN_SWP_ISDR_REG   0xE08
-
-#define CONFIG_SYS_DPAA_FMAN
 #endif /* CONFIG_NOBQFMAN */
 
 #ifdef CONFIG_SYS_DPAA_FMAN
index 423ba8161702ace6a7daca11672ff2294bf1c365..847cf65b4092f2663a101f48a468c621db36d2ed 100644 (file)
                                        CONFIG_SYS_QMAN_CENA_SIZE)
 #define CONFIG_SYS_QMAN_CINH_SIZE       (CONFIG_SYS_QMAN_MEM_SIZE >> 1)
 #define CONFIG_SYS_QMAN_SWP_ISDR_REG   0xE08
-
-#define CONFIG_SYS_DPAA_FMAN
-#define CONFIG_SYS_DPAA_PME
 #endif /* CONFIG_NOBQFMAN */
 
 #ifdef CONFIG_FMAN_ENET
index 2efc2eb95c47b3485791e0ec539b93215b8ed8f0..b49c26477684fb68520820c9471f84c4629247c7 100644 (file)
                                        CONFIG_SYS_QMAN_CENA_SIZE)
 #define CONFIG_SYS_QMAN_CINH_SIZE       (CONFIG_SYS_QMAN_MEM_SIZE >> 1)
 #define CONFIG_SYS_QMAN_SWP_ISDR_REG   0xE08
-
-#define CONFIG_SYS_DPAA_FMAN
-#define CONFIG_SYS_DPAA_PME
-#define CONFIG_SYS_PMAN
-#define CONFIG_SYS_DPAA_DCE
-#define CONFIG_SYS_DPAA_RMAN           /* RMan */
 #endif /* CONFIG_NOBQFMAN */
 
 #ifdef CONFIG_SYS_DPAA_FMAN
index ca8bfac0c69d58fd0a29da4e93135ae049ca308e..aae41a339254ca5f26bcc59df9b271ffaa2c3106 100644 (file)
                                        CONFIG_SYS_QMAN_CENA_SIZE)
 #define CONFIG_SYS_QMAN_CINH_SIZE       (CONFIG_SYS_QMAN_MEM_SIZE >> 1)
 #define CONFIG_SYS_QMAN_SWP_ISDR_REG   0xE08
-
-#define CONFIG_SYS_DPAA_FMAN
-#define CONFIG_SYS_DPAA_PME
-#define CONFIG_SYS_PMAN
-#define CONFIG_SYS_DPAA_DCE
-#define CONFIG_SYS_DPAA_RMAN           /* RMan */
 #endif /* CONFIG_NOBQFMAN */
 
 #ifdef CONFIG_SYS_DPAA_FMAN
index 091920dccfe62a26ccd9516b66cb88da3a1a63fe..9dc45e397f9ba85ae03515c2ff48e18374f0da32 100644 (file)
                                        CONFIG_SYS_QMAN_CENA_SIZE)
 #define CONFIG_SYS_QMAN_CINH_SIZE       (CONFIG_SYS_QMAN_MEM_SIZE >> 1)
 #define CONFIG_SYS_QMAN_SWP_ISDR_REG   0xE08
-
-#define CONFIG_SYS_DPAA_FMAN
-#define CONFIG_SYS_DPAA_PME
-#define CONFIG_SYS_PMAN
-#define CONFIG_SYS_DPAA_DCE
-#define CONFIG_SYS_DPAA_RMAN
 #endif /* CONFIG_NOBQFMAN */
 
 #ifdef CONFIG_SYS_DPAA_FMAN
index 1df90def6733989e0f8cc56087cb6e80c7df0342..c8423fdfb0ab683d3852a25c2e071a070f43bdaf 100644 (file)
@@ -372,9 +372,6 @@ int get_scl(void);
 #define CONFIG_SYS_QMAN_CINH_SIZE       (CONFIG_SYS_QMAN_MEM_SIZE >> 1)
 #define CONFIG_SYS_QMAN_SWP_ISDR_REG   0xE08
 
-#define CONFIG_SYS_DPAA_FMAN
-#define CONFIG_SYS_DPAA_PME
-
 /* Qman / Bman */
 /* RGMII (FM1@DTESC5) is local managemant interface */
 #define CONFIG_SYS_RGMII2_PHY_ADDR             0x11
index 6fc509af232c961648fc7ce19afcfa816b33e83d..df6338298b48bccbf34cc892df2fb4b32750f9e9 100644 (file)
 
 /* FMan ucode */
 #ifndef SPL_NO_FMAN
-#define CONFIG_SYS_DPAA_FMAN
 #ifdef CONFIG_SYS_DPAA_FMAN
 #define CONFIG_SYS_FM_MURAM_SIZE       0x60000
 #endif
index 3934fbbb41d1dc3781c2e22f50a3b9bbba3df8a3..b09588f4796d02e3394fa0e41a3916486a967afb 100644 (file)
@@ -67,7 +67,6 @@
 
 /* FMan ucode */
 #ifndef SPL_NO_FMAN
-#define CONFIG_SYS_DPAA_FMAN
 #ifdef CONFIG_SYS_DPAA_FMAN
 #define CONFIG_SYS_FM_MURAM_SIZE       0x60000
 #endif