aboutsummaryrefslogtreecommitdiff
path: root/arch/powerpc/cpu/mpc83xx
AgeCommit message (Collapse)AuthorFilesLines
2023-11-07powerpc: mpc83xx: Rework includes slightlyTom Rini2-0/+3
In order to not rely on common.h providing a number of common includes, cleanup what we include directly in order to be able to drop common.h later. Signed-off-by: Tom Rini <trini@konsulko.com>
2023-11-07fsl_qe: Drop common.hTom Rini1-1/+0
In both include/fsl_qe.h and then also remove common.h from the files which had included fsl_qe.h Signed-off-by: Tom Rini <trini@konsulko.com>
2023-10-06spl: Use SYS_MALLOC_F instead of SYS_MALLOC_F_LENSimon Glass1-1/+1
Use the new SPL/TPL/VPL_SYS_MALLOC_F symbols to determine whether the malloc pool exists. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Sean Anderson <sean.anderson@seco.com>
2023-05-01mpc83xx: Don't allow W and G bits in IBATsChristophe Leroy1-176/+32
The "Programming Environments Manual for 32-Bit Implementations of the PowerPC™ Architecture" says "W and G bits are not defined for IBAT registers. Attempting to write to these bits causes boundedly-undefined results" The "e300 Power Architecture™ Core Family Reference Manual" says the same: "Neither the W or G bits of the IBAT registers should be set. Attempting to write to these bits causes boundedly-undefined results." Remove the possibility to set those bytes. Fixes: 30915ab95d9 ("mpc83xx: Migrate BATS config to Kconfig") Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu> Cc: Mario Six <mario.six@gdsys.cc>
2023-04-28board: cssi: Add CPU board CMPCPROChristophe Leroy1-0/+5
CSSI has another CPU board, similar to the CMPC885 board that get plugged on the two base boards MCR3000_2G and MIAE. That CPU board is called CMPCPRO because it has a MPC8321E CPU, also known as Power QUICC II PRO. Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
2023-04-06powerpc: mpc83xx: Don't activate MMU when not necessaryChristophe Leroy1-1/+1
At startup, some RAM is needed (for instance for stack) before DRAM is initialised. One way to offer such RAM, used by mpc83xx, is to lock some entries in the cache. To do that, MMU needs to be activated. On mpc83xx having a QUICC Engine an alternative is to user some part of from the Multi User RAM, like done on mpc8xx for instance. For that, the MMU is not needed. Activating the MMU is problematic because exception vectors are not setup yet so in case of ISI or DSI that CPU will crash and reboot. At the time being, MMU is activated regardless. Only activate it when locking cache entries to provide initial RAM. Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
2023-04-06powerpc: mpc832x: Fix reset wordChristophe Leroy1-2/+1
According to the reference manual, the Reset Configuration Word Low Register bits 2-3 must be set to 0b10. Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
2023-04-06watchdog: mpc8xxx: Add support for mpc83xxChristophe Leroy2-1/+3
Introduce a new compatible "fsl,pq2pro-wdt" On mpc83xx, the prescaling factor is 0x10000. Don't write the watchdog configuration register in start.S as it can be written only once. Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
2023-03-29mpc83xx: Remove CONFIG_SYS_GPIO{1/2}_PRELIM and relatedChristophe Leroy1-8/+0
Last use of CONFIG_SYS_GPIO1_PRELIM was removed by commit fae2ea5951 ("ppc: Remove MPC8349EMDS board and ARCH_MPC8349 support"). Last use of CONFIG_SYS_GPIO2_PRELIM was removed even before by commit 6843862342 ("ppc: Remove caddy2 / vme8349 boards") Those two items were removed from whitelist by commit 8cca60a2cb ("Kconfig: Remove some symbols from the whitelist") Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu> Fixes: fae2ea5951 ("ppc: Remove MPC8349EMDS board and ARCH_MPC8349 support")
2023-03-29mpc83xx: Remove stale CONFIG_SYS_LBLAWBAR{4/5/6/7}_PRELIMChristophe Leroy1-16/+0
Last (incorrect) use of those CONFIG items was removed by commit 9fd9abedcc ("TQM834x: remove defines causing gcc4.4 warnings") Those items are invalid and should have been removed at the same time because lblaw[] has only 4 elements. And they were removed from the whitelist by commit 9c5df7a2a9 ("mpc83xx: Migrate LBLAW_* to Kconfig") Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu> Fixes: 9fd9abedcc ("TQM834x: remove defines causing gcc4.4 warnings")
2023-03-06powerpc, mpc83xx: Remove CONFIG_ELBC_BRx_ORxChristophe Leroy6-3671/+0
Commit fe7d654d04 ("mpc83xx: Migrate CONFIG_SYS_{BR, OR}*_PRELIM to Kconfig") converted CONFIG_SYS_{BRx/ORx}_PRELIM to Kconfig by implementing a fine-grained selection of every bit in Kconfig. But commit c7fad78ec0 ("Convert CONFIG_SYS_BR0_PRELIM et al to Kconfig") reworked it so that you now just have to provide the raw value of each register in Kconfig. However, all fine-grained Kconfig items remained allthough they are not used anymore. Remove them all. Fixes: c7fad78ec0 ("Convert CONFIG_SYS_BR0_PRELIM et al to Kconfig") Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
2023-01-20global: Finish CONFIG -> CFG migrationTom Rini8-186/+186
At this point, the remaining places where we have a symbol that is defined as CONFIG_... are in fairly odd locations. While as much dead code has been removed as possible, some of these locations are simply less obvious at first. In other cases, this code is used, but was defined in such a way as to have been missed by earlier checks. Perform a rename of all such remaining symbols to be CFG_... rather than CONFIG_... Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2022-12-23Convert CONFIG_NEVER_ASSERT_ODT_TO_CPU to KconfigTom Rini1-0/+3
This converts the following to Kconfig: CONFIG_NEVER_ASSERT_ODT_TO_CPU Signed-off-by: Tom Rini <trini@konsulko.com>
2022-12-22net: Remove more legacy functionsTom Rini1-18/+0
Remove some of the board and arch specific non-DM_ETH helper code. Signed-off-by: Tom Rini <trini@konsulko.com>
2022-12-05Convert CONFIG_FSL_SERDES to KconfigTom Rini2-4/+4
This converts the following to Kconfig: CONFIG_FSL_SERDES Signed-off-by: Tom Rini <trini@konsulko.com>
2022-12-05global: Move remaining CONFIG_SYS_* to CFG_SYS_*Tom Rini5-62/+62
The rest of the unmigrated CONFIG symbols in the CONFIG_SYS namespace do not easily transition to Kconfig. In many cases they likely should come from the device tree instead. Move these out of CONFIG namespace and in to CFG namespace. Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2022-12-05global: Move remaining CONFIG_SYS_SDRAM_* to CFG_SYS_SDRAM_*Tom Rini1-1/+1
The rest of the unmigrated CONFIG symbols in the CONFIG_SYS_SDRAM namespace do not easily transition to Kconfig. In many cases they likely should come from the device tree instead. Move these out of CONFIG namespace and in to CFG namespace. Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2022-12-05global: Move remaining CONFIG_SYS_PCI* to CFG_SYS_PCI*Tom Rini1-5/+5
The rest of the unmigrated CONFIG symbols in the CONFIG_SYS_PCI and CONFIG_SYS_PCIE namespace do not easily transition to Kconfig. In many cases they likely should come from the device tree instead. Move these out of CONFIG namespace and in to CFG namespace. Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2022-12-05global: Move remaining CONFIG_SYS_NAND_* to CFG_SYS_NAND_*Tom Rini2-15/+15
The rest of the unmigrated CONFIG symbols in the CONFIG_SYS_NAND namespace do not easily transition to Kconfig. In many cases they likely should come from the device tree instead. Move these out of CONFIG namespace and in to CFG namespace. Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2022-08-20powerpc: remove support for kmtergr1 and MPC8309Holger Brunck4-45/+1
The kmtegr1 board is out of maintenance and can be removed. As it is the only board in the tree using MPC8309 the support for this CPU is dropped completely. Signed-off-by: Holger Brunck <holger.brunck@hitachienergy.com>
2022-08-12ppc: Remove ids8313 boardTom Rini1-7/+0
This board is behind on several mandatory DM migrations and is missing OF_CONTROL support that makes other conversions impossible. Remove it. Cc: Heiko Schocher <hs@denx.de> Signed-off-by: Tom Rini <trini@konsulko.com> Acked-by: Heiko Schocher <hs@denx.de>
2022-07-07Convert CONFIG_SYS_83XX_DDR_USES_CS0 to KconfigTom Rini1-0/+6
This converts the following to Kconfig: CONFIG_SYS_83XX_DDR_USES_CS0 Signed-off-by: Tom Rini <trini@konsulko.com>
2022-06-28usb: ehci-fsl: Remove non-DM codeTom Rini1-13/+0
The deadline for DM_USB migration has passed and all users have been migrated. Remove now unused code. Signed-off-by: Tom Rini <trini@konsulko.com>
2022-06-23linker_lists: Rename sections to remove . prefixAndrew Scull1-2/+2
Rename the sections used to implement linker lists so they begin with '__u_boot_list' rather than '.u_boot_list'. The double underscore at the start is still distinct from the single underscore used by the symbol names. Having a '.' in the section names conflicts with clang's ASAN instrumentation which tries to add redzones between the linker list elements, causing expected accesses to fail. However, clang doesn't try to add redzones to user sections, which are names with all alphanumeric and underscore characters. Signed-off-by: Andrew Scull <ascull@google.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2022-06-06Migrate CUSTOM_SYS_INIT_SP_ADDR to Kconfig using system-constants.hTom Rini3-4/+7
- Make all users of CUSTOM_SYS_INIT_SP_ADDR reference SYS_INIT_SP_ADDR - Introduce HAS_CUSTOM_SYS_INIT_SP_ADDR to allow for setting the stack pointer directly, otherwise we use the common calculation. - On some platforms that were using the standard calculation but did not set CONFIG_SYS_INIT_RAM_SIZE / CONFIG_SYS_INIT_RAM_ADDR, set them. - On a small number of platforms that were not subtracting GENERATED_GBL_DATA_SIZE do so now via the standard calculation. - CONFIG_SYS_INIT_SP_OFFSET is now widely unused, so remove it from most board config header files. Signed-off-by: Tom Rini <trini@konsulko.com>
2022-06-06powerpc: Switch to using CONFIG_SYS_INIT_SP_OFFSET from ↵Tom Rini3-4/+4
CONFIG_SYS_GBL_DATA_OFFSET In the places where PowerPC references CONFIG_SYS_GBL_DATA_OFFSET it does so as (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_GBL_DATA_OFFSET). And it defines CONFIG_SYS_GBL_DATA_OFFSET in the same manner that other architectures define CONFIG_SYS_INIT_SP_OFFSET. Other architectures define CONFIG_SYS_INIT_SP_ADDR as (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET) typically. Rename things within PowerPC for consistency with other architectures. Signed-off-by: Tom Rini <trini@konsulko.com>
2022-06-06Convert CONFIG_SPL_INIT_MINIMAL et al to KconfigTom Rini2-1/+3
This converts the following to Kconfig: CONFIG_SPL_INIT_MINIMAL CONFIG_SPL_FLUSH_IMAGE CONFIG_SPL_SKIP_RELOCATE Signed-off-by: Tom Rini <trini@konsulko.com>
2022-04-08powerpc: mpc83xx: Migrate DEFAULT_IMMR to KconfigTom Rini1-0/+4
As no platforms override this value, set it for all mpc83xx platforms. Cc: Mario Six <mario.six@gdsys.cc> Cc: Wolfgang Denk <wd@denx.de> Signed-off-by: Tom Rini <trini@konsulko.com>
2022-04-01Convert CONFIG_E300 et al to KconfigTom Rini1-0/+3
This converts the following to Kconfig: CONFIG_E300 CONFIG_E5500 Signed-off-by: Tom Rini <trini@konsulko.com>
2022-04-01keymile: Move sourcing of common KconfigTom Rini1-1/+0
The way board/keymile/Kconfig is written protects the options there from being parsed on non-keymile platforms. We cannot however safely source this file from multiple locations. This does not manifest as a problem currently as there are no choice statements inside of this file (nor the sub-Kconfig files it sources). However, moving some target selection to one of these files exposes the underlying problem. Rework things so that we have this file sourced in arch/Kconfig. Cc: Holger Brunck <holger.brunck@hitachienergy.com> Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Holger Brunck <holger.brunck@hitachienergy.com>
2022-03-18Remove CONFIG_HAS_ETH0 et al symbolsTom Rini1-8/+0
This converts removes the following symbols: CONFIG_HAS_ETH0 CONFIG_HAS_ETH1 CONFIG_HAS_ETH2 CONFIG_HAS_ETH3 This is because at this point, only the ids8313 platform was using the code which was controlled by these symbols. In turn, this code already performs error checking on being able to perform the device tree fixup. Rather than convert these to Kconfig for a single platform, update the code to not need these checks and remove them from all the platforms they were unused on. Reviewed-by: Heiko Schocher <hs@denx.de> Signed-off-by: Tom Rini <trini@konsulko.com>
2022-01-18common: remove bedbug debugger supportOvidiu Panait1-7/+0
Commit 98f705c9cefd ("powerpc: remove 4xx support") removed (in 2017) the last code that made use of bedbug debugger support. Since there aren't any boards left that define either CONFIG_CMD_BEDBUG or a real bedbug_init(), drop this feature from u-boot. Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com> Reviewed-by: Thomas Huth <thuth@redhat.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2021-12-27ppc: mpc83xx: Remove unused CONFIG symbolsTom Rini1-2/+0
Neither of these symbols are referenced anywhere else, so remove them. Signed-off-by: Tom Rini <trini@konsulko.com>
2021-12-27Convert CONFIG_83XX_PCICLK to KconfigTom Rini1-0/+7
This converts the following to Kconfig: CONFIG_83XX_PCICLK Signed-off-by: Tom Rini <trini@konsulko.com>
2021-12-27Finish conversion of CONFIG_SYS_CLK_FREQ to KconfigTom Rini3-4/+5
In order to finish moving this symbol to Kconfig for all platforms, we need to do a few more things. First, for all platforms that define this to a function, introduce CONFIG_DYNAMIC_SYS_CLK_FREQ, similar to CONFIG_DYNAMIC_DDR_CLK_FREQ and populate clock_legacy.h. This entails also switching all users from CONFIG_SYS_CLK_FREQ to get_board_sys_clk() and updating a few preprocessor tests. With that done, all platforms that define a value here can be converted to Kconfig, and a fall-back of zero is sufficiently safe to use (and what is used today in cases where code may or may not have this available). Make sure that code which calls this function includes <clock_legacy.h> to get the prototype. Signed-off-by: Tom Rini <trini@konsulko.com>
2021-12-27Convert CONFIG_SYS_IMMR to KconfigTom Rini2-10/+0
This converts the following to Kconfig: CONFIG_SYS_IMMR We do this by consolidating the SYS_IMMR options we have and providing defaults. We also, in the few places where M68K was also sharing code with these platforms, define it within the file to CONFIG_SYS_MBAR to match usage. This should be cleaned up longer term. Signed-off-by: Tom Rini <trini@konsulko.com>
2021-12-01Convert CONFIG_SYS_BR0_PRELIM et al to KconfigTom Rini1-170/+0
This converts the following to Kconfig: CONFIG_SYS_BR0_PRELIM CONFIG_SYS_OR1_PRELIM CONFIG_SYS_BR1_PRELIM CONFIG_SYS_OR2_PRELIM CONFIG_SYS_BR2_PRELIM CONFIG_SYS_OR2_PRELIM CONFIG_SYS_BR3_PRELIM CONFIG_SYS_OR3_PRELIM CONFIG_SYS_BR4_PRELIM CONFIG_SYS_OR4_PRELIM CONFIG_SYS_BR5_PRELIM CONFIG_SYS_OR5_PRELIM CONFIG_SYS_BR6_PRELIM CONFIG_SYS_OR6_PRELIM CONFIG_SYS_BR7_PRELIM CONFIG_SYS_OR7_PRELIM This also introduces CONFIG_SYS_BR0_PRELIM_BOOL as not all platforms that can set these values do so. Add the relevant SYS_BRx_PRELIM_BOOL to platforms that had not been previously migrated. Signed-off-by: Tom Rini <trini@konsulko.com>
2021-10-01ppc: Remove MPC8349EMDS board and ARCH_MPC8349 supportTom Rini10-214/+45
This board has not been converted to CONFIG_DM by the deadline. Remove it. Cc: Priyanka Jain <priyanka.jain@nxp.com> Signed-off-by: Tom Rini <trini@konsulko.com>
2021-09-17powerpc: Drop version_string placement optimizationTom Rini1-7/+0
As explained by Wolfgang, historically PowerPC would do a number of things to hand-optimize placement of the binary on NOR flash in order to maximize utilization of very scarce resources. These days, we simply aren't optimizing our binary layout for NOR flash placement and it's quite likely this wasn't working as intended. Furthermore, this level of optimization makes it difficult to have version_string be a global, instead of a weak and overridden value, and so make more progress on reproducible builds, which is a current concern. Move to having PowerPC no longer store version_string in the early part of text so that it might be part of the first page of NOR and instead use the same declaration everyone else does. Link: https://lore.kernel.org/r/96716.1629798400@gemini.denx.de/ Signed-off-by: Tom Rini <trini@konsulko.com>
2021-09-04sata: Rename SATA_SUPPORT to SATASimon Glass1-2/+2
Rename this options so that CONFIG_IS_ENABLED can be used with it. Signed-off-by: Simon Glass <sjg@chromium.org>
2021-08-31Finish converting CONFIG_SYS_CACHELINE_SIZE to KconfigTom Rini1-0/+6
We move the SYS_CACHE_SHIFT_N options from arch/arm/Kconfig to arch/Kconfig, and introduce SYS_CACHE_SHIFT_4 to provide a size of 16. Introduce select statements for other architectures based on current usage. For MIPS, we take the existing arch-specific symbol and migrate to the generic symbol. This lets us remove a little bit of otherwise unused code. Cc: Alexey Brodkin <alexey.brodkin@synopsys.com> Cc: Anup Patel <anup.patel@wdc.com> Cc: Atish Patra <atish.patra@wdc.com> Cc: Bin Meng <bmeng.cn@gmail.com> Cc: Leo <ycliang@andestech.com> Cc: Palmer Dabbelt <palmer@dabbelt.com> Cc: Paul Walmsley <paul.walmsley@sifive.com> Cc: Sean Anderson <seanga2@gmail.com> Cc: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Rini <trini@konsulko.com> Acked-by: Sean Anderson <seanga2@gmail.com> Reviewed-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com> Reviewed-by: Rick Chen <rick@andestech.com>
2021-08-31nxp: Migrate a number of DDR related symbols to KconfigTom Rini2-3/+1
- Guard most of the options in drivers/ddr/fsl/Kconfig with SYS_FSL_DDR || SYS_FSL_MMDC. - Migrate FSL_DMA, DDR_ECC, DDR_ECC_CMD, and ECC_INIT_VIA_DDRCONTROLLER to Kconfig. - Clean up the logic for including the DDR_ECC_CMD code. Signed-off-by: Tom Rini <trini@konsulko.com>
2021-08-30global: Remove unused or unnecessary CONFIG symbols related to DDRTom Rini1-10/+0
These symbols are now either unused or were only used within the config file to determine other logic, which could be done in a way that doesn't further pollute the CONFIG namespace. Signed-off-by: Tom Rini <trini@konsulko.com>
2021-08-30global: Remove dead code that starts with CONFIG_[0-9A]Tom Rini1-144/+0
This removes a number of spots of dead code based on symbols that start with CONFIG_[0-9] or CONFIG_A. Signed-off-by: Tom Rini <trini@konsulko.com>
2021-08-05pci: powerpc: Drop old codeSimon Glass1-160/+0
Drop the old pre-driver model code from these drivers. Signed-off-by: Simon Glass <sjg@chromium.org>
2021-08-02global: Convert simple_strtoul() with decimal to dectoul()Simon Glass1-2/+2
It is a pain to have to specify the value 10 in each call. Add a new dectoul() function and update the code to use it. Signed-off-by: Simon Glass <sjg@chromium.org>
2021-08-02global: Convert simple_strtoul() with hex to hextoul()Simon Glass1-7/+7
It is a pain to have to specify the value 16 in each call. Add a new hextoul() function and update the code to use it. Add a proper comment to simple_strtoul() while we are here. Signed-off-by: Simon Glass <sjg@chromium.org>
2021-07-28i2c: Rename SPL/TPL_I2C_SUPPORT to I2CSimon Glass1-7/+7
Rename these options so that CONFIG_IS_ENABLED can be used with them. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Heiko Schocher <hs@denx.de>
2021-07-07ppc: Remove MPC832XEMDS boardsTom Rini1-6/+0
These boards have not been converted to CONFIG_DM_PCI by the deadline and is also missing conversion to CONFIG_DM. Remove them. Signed-off-by: Tom Rini <trini@konsulko.com>
2021-07-07ppc: Remove MPC8323ERDB boardTom Rini1-5/+0
This board has not been converted to CONFIG_DM_PCI by the deadline and is also missing conversion to CONFIG_DM. Remove it. Signed-off-by: Tom Rini <trini@konsulko.com>