summaryrefslogtreecommitdiff
path: root/arch/powerpc/include/asm
AgeCommit message (Collapse)AuthorFilesLines
2022-01-18common: board_r: move init_addr_map() to init.hOvidiu Panait1-4/+0
asm/mmu.h include is currently guarded by CONFIG_ADDR_MAP ifdef because the header is only present on arm and powerpc. In order to remove the dependency on this header and the associated ifdef, move init_addr_map() declaration to init.h, since it is only called during the common init sequence. Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com>
2022-01-18common: board_r: drop initr_addr_map wrapperOvidiu Panait1-1/+1
Add a return value to init_addr_map and use it directly in the post-relocation init sequence, rather than using a wrapper stub. Reviewed-by: Matthias Brugger <mbrugger@suse.com> Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com>
2021-12-05ide: Drop unused CONFIG optionsSimon Glass1-3/+0
CONFIG_SYS_ATA_PORT_ADDR is not used in the code anymore. Drop it and use ATA_PORT_ADDR() locally instead. Drop CONFIG_IDE_RESET_ROUTINE and CONFIG_IDE_SWAP_IO which are also unused. Signed-off-by: Simon Glass <sjg@chromium.org>
2021-10-06Convert CONFIG_NAND_FSL_ELBC et al to KconfigTom Rini1-2/+0
This converts the following to Kconfig: CONFIG_NAND_FSL_ELBC CONFIG_NAND_FSL_IFC Note that a number of PowerPC platforms had previously enabled CONFIG_NAND_FSL_ELBC without CONFIG_MTD_RAW_NAND, and now they no longer enable the option, reducing the size of a few functions. Signed-off-by: Tom Rini <trini@konsulko.com>
2021-09-30WS cleanup: remove SPACE(s) followed by TABWolfgang Denk3-5/+5
Signed-off-by: Wolfgang Denk <wd@denx.de>
2021-09-01Finish converting CONFIG_SYS_CACHELINE_SIZE to KconfigTom Rini1-7/+0
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-09-01nxp: Migrate a number of DDR related symbols to KconfigTom Rini1-8/+0
- 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-31global: Remove unused or unnecessary CONFIG symbols related to DDRTom Rini1-2/+1
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-4/+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-07-08ppc: Remove T4160RDB boardTom Rini3-7/+3
This board has not been converted to CONFIG_DM_PCI by the deadline and is also missing conversion to CONFIG_DM. Remove it. As this is the last ARCH_T4160 platform, remove that support as well. Signed-off-by: Tom Rini <trini@konsulko.com>
2021-07-08ppc: Remove MPC8315ERDB boardTom Rini4-52/+2
This board has not been converted to CONFIG_DM_PCI by the deadline and is also missing conversion to CONFIG_DM. Remove it. As this is the last ARCH_MPC8315 platform, remove that support as well. Signed-off-by: Tom Rini <trini@konsulko.com>
2021-07-08ppc: Remove sbc8641d boardTom Rini6-1246/+1
This board has not been converted to CONFIG_DM_PCI by the deadline and is also missing conversion to CONFIG_DM. Remove it. This is also the last of the ARCH_MPC8641/MPC8610 platforms, so remove that support as well. Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: Priyanka Jain <priyanka.jain@nxp.com> Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2021-07-08ppc: Remove xpedite boardsTom Rini2-3/+3
These boards have not been converted to CONFIG_DM_PCI by the deadline and is also missing conversion to CONFIG_DM. Remove them. As this includes the last ARCH_MPC8572 platform, remove that as well. Cc: Peter Tyser <ptyser@xes-inc.com> Signed-off-by: Tom Rini <trini@konsulko.com> Acked-by: Peter Tyser <ptyser@xes-inc.com>
2021-07-08ppc: Remove MPC8568MDS boardTom Rini2-15/+1
This board has not been converted to CONFIG_DM_PCI by the deadline and is also missing conversion to CONFIG_DM. Remove it. As this is the last ARCH_MPC8568 platform, remove that support as well. Cc: Priyanka Jain <priyanka.jain@nxp.com> Signed-off-by: Tom Rini <trini@konsulko.com>
2021-07-08ppc: Remove T1023RBD boards and T1024RDB_SECURE_BOOTTom Rini3-4/+3
These boards have not been converted to CONFIG_DM_PCI by the deadline and is also missing conversion to CONFIG_DM. Remove them. As this is the only ARCH_T1023 platform left, remove that support as well. Cc: Priyanka Jain <priyanka.jain@nxp.com> Signed-off-by: Tom Rini <trini@konsulko.com>
2021-07-08ppc: Remove MPC8555CDS boardsTom Rini3-8/+2
These boards have not been converted to CONFIG_DM_PCI by the deadline and is also missing conversion to CONFIG_DM. Remove them. As this is the only ARCH_MPC8555 platform left, remove that support as well. Cc: Priyanka Jain <priyanka.jain@nxp.com> Signed-off-by: Tom Rini <trini@konsulko.com>
2021-07-08ppc: Remove MPC8541CDS boardTom Rini3-4/+2
This board has not been converted to CONFIG_DM_PCI by the deadline and is also missing conversion to CONFIG_DM. Remove it. As this is the only MPC8541 target left, remove that architecture support as well. Cc: Priyanka Jain <priyanka.jain@nxp.com> Signed-off-by: Tom Rini <trini@konsulko.com>
2021-07-08ppc: Remove many T104x boardsTom Rini1-2/+0
These boards have not been converted to CONFIG_DM_PCI, CONFIG_DM_USB or in some cases CONFIG_DM itself by the deadline. Remove them. Cc: Priyanka Jain <priyanka.jain@nxp.com> Cc: Ruchika Gupta <ruchika.gupta@nxp.com> Signed-off-by: Tom Rini <trini@konsulko.com>
2021-06-23powerpc: Don't use relative include for config.h in global_data.hTom Rini1-1/+1
As there is an arch/powerpc/include/asm/config.h file using "" to get config.h here can lead to using that rather than include/config.h. This in turn can lead to a mismatch in the size of gd. Cc: Matt Merhar <mattmerhar@protonmail.com> Signed-off-by: Tom Rini <trini@konsulko.com> Tested-by: Matt Merhar <mattmerhar@protonmail.com>
2021-05-24treewide: Convert macro and uses of __section(foo) to __section("foo")Marek BehĂșn1-2/+2
This commit does the same thing as Linux commit 33def8498fdd. Use a more generic form for __section that requires quotes to avoid complications with clang and gcc differences. Remove the quote operator # from compiler_attributes.h __section macro. Convert all unquoted __section(foo) uses to quoted __section("foo"). Also convert __attribute__((section("foo"))) uses to __section("foo") even if the __attribute__ has multiple list entry forms. Signed-off-by: Marek BehĂșn <marek.behun@nic.cz> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2021-04-22lmb: move CONFIG_LMB in KconfigPatrick Delaunay1-1/+0
Migrate CONFIG_LMB in Kconfig. Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
2021-04-10ppc: Remove Cyrus_P5020 and P5040 boardsTom Rini3-20/+1
These boards have not been converted to CONFIG_DM_MMC by the deadline. Remove them. As the P5020 is the last ARCH_P5020 platform, remove that support as well. Cc: Andy Fleming <afleming@gmail.com> Cc: Priyanka Jain <priyanka.jain@nxp.com> Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2021-04-10ppc: Remove ARCH_P1022 supportTom Rini2-18/+1
With the last of the ARCH_P1022 platforms removed, finish removing the rest of the platform support. Cc: Priyanka Jain <priyanka.jain@nxp.com> Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2021-04-10ppc: Remove T2081QDS board and ARCH_T2081 supportTom Rini2-6/+3
This board has not been converted to CONFIG_DM_MMC by the deadline. Remove it. It is also the only ARCH_T2081 board so remove that support as well. Cc: Shengzhou Liu <Shengzhou.Liu@nxp.com> Cc: Ruchika Gupta <ruchika.gupta@nxp.com> Signed-off-by: Tom Rini <trini@konsulko.com>
2021-04-10ppc: Remove TARGET_T1040QDS referencesTom Rini1-1/+0
The TARGET_T1040QDS platforms have been removed already, drop some remaining references in the code. Signed-off-by: Tom Rini <trini@konsulko.com>
2021-03-05gpio: mpc8xxx: Support controller register physical address beyond 32-bitBin Meng1-1/+1
dev_read_addr_size_index() returns fdt_addr_t which might be a 64-bit physical address. This might be true for some 85xx SoCs whose CCSBAR is mapped beyond 4 GiB. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2021-03-05ppc: mpc85xx: Add 'gpibe' register to 'struct ccsr_gpio'Bin Meng1-0/+1
Without this, the DM GPIO driver for MPC8xxx does not compile for MPC85xx SoCs. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2021-03-05ppc: io.h: Use addrmap_ translation APIs only in post-relocation phaseBin Meng1-6/+9
In phys_to_virt() and virt_to_phys(), if CONFIG_ADDR_MAP is defined, they use addrmap_ translation APIs to do the address translation. However these APIs only work in post-relocation phase. Update the code logic to fall back to use the default one when in pre-relocation phase. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2021-02-25ppc: Remove MPC8569MDS boardTom Rini2-18/+1
This board has not been converted to CONFIG_DM_MMC by the deadline. Remove it. As this is the last ARCH_MPC8569 board, remove that support as well. Cc: Priyanka Jain <priyanka.jain@nxp.com> Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2021-02-21dm: i2c: use CONFIG_IS_ENABLED macro for DM_I2C/DM_I2C_GPIOIgor Opaniuk1-1/+1
Use CONFIG_IS_ENABLED() macro, which provides more convenient way to check $(SPL)DM_I2C/$(SPL)DM_I2C_GPIO configs for both SPL and U-Boot proper. CONFIG_IS_ENABLED(DM_I2C) expands to: - 1 if CONFIG_SPL_BUILD is undefined and CONFIG_DM_I2C is set to 'y', - 1 if CONFIG_SPL_BUILD is defined and CONFIG_SPL_DM_I2C is set to 'y', - 0 otherwise. All occurences were replaced automatically using these bash cmds: $ find . -type f -exec sed -i 's/ifndef CONFIG_DM_I2C/if !CONFIG_IS_ENABLED(DM_I2C)/g' {} + $ find . -type f -exec sed -i 's/ifdef CONFIG_DM_I2C/if CONFIG_IS_ENABLED(DM_I2C)/g' {} + $ find . -type f -exec sed -i 's/defined(CONFIG_DM_I2C)/CONFIG_IS_ENABLED(DM_I2C)/g' {} + $ find . -type f -exec sed -i 's/ifndef CONFIG_DM_I2C_GPIO/if !CONFIG_IS_ENABLED(DM_I2C_GPIO)/g' {} + $ find . -type f -exec sed -i 's/ifdef CONFIG_DM_I2C_GPIO/if CONFIG_IS_ENABLED(DM_I2C_GPIO)/g' {} + $ find . -type f -exec sed -i 's/defined(CONFIG_DM_I2C_GPIO)/CONFIG_IS_ENABLED(DM_I2C_GPIO)/g' {} + Reviewed-by: Heiko Schocher <hs@denx.de> Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Igor Opaniuk <igor.opaniuk@foundries.io> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2021-02-08gpio: mpc8xxx_gpio: Fix for litte endianBiwen Li1-0/+13
Update gpio driver to use same logic for big-endian and little-endian Signed-off-by: Biwen Li <biwen.li@nxp.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2020-12-10powerpc: mpc85xx: Allow boards to override CONFIG_USB_MAX_CONTROLLER_COUNTChris Packham1-0/+2
If the board isn't strapped to enable USB1 then attempting to access it will result in a hang. Avoid this by allowing boards to define CONFIG_USB_MAX_CONTROLLER_COUNT. Signed-off-by: Chris Packham <judge.packham@gmail.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2020-07-27Drop global data sdhc_adapter for powerpcYangbo Lu1-3/+1
The sdhc_adapter of global data has not been used, and we do not have to use it as global data even we may need it in the future. Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com> Reviewed-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2020-06-03powerpc/mpc85xx: Fix compiling error with DM_GPIOMadalin Bucur1-1/+2
P4080DS compilation fails with DM_GPIO enabled: drivers/gpio/gpio-uclass.c:355:5: error: redefinition of 'gpio_request' int gpio_request(unsigned gpio, const char *label) ^~~~~~~~~~~~ In file included from ./arch/powerpc/include/asm/arch/gpio.h:17:0, from ./arch/powerpc/include/asm/gpio.h:1, from drivers/gpio/gpio-uclass.c:16: ./arch/powerpc/include/asm/mpc85xx_gpio.h:68:19: note: previous definition of 'gpio_request' was here static inline int gpio_request(unsigned gpio, const char *label) ^~~~~~~~~~~~ Signed-off-by: Madalin Bucur <madalin.bucur@oss.nxp.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2020-05-19common: Drop linux/bitops.h from common headerSimon Glass2-0/+3
Move this uncommon header out of the common header. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-05-19common: Drop image.h from common headerSimon Glass1-0/+1
Move this uncommon header out of the common header. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-02-20dma-mapping: add <asm/dma-mapping.h> for all architecturesMasahiro Yamada1-0/+1
To avoid "asm/dma-mapping.h: No such file or directory" error, we need something. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2020-01-17common: Move upmconfig() to ppc.hSimon Glass1-0/+1
This file is only used by PowerPC so move it to an arch-specific header file. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-01-16Add global variable sdhc_per_clk for arm/powerpcYangbo Lu1-0/+1
The QorIQ eSDHC controller supports two reference clocks. They are platform clock and periperhal clock. The global variable sdhc_clk has already been used for platform clock. This patch is to add another global variable sdhc_per_clk for periperhal clock, which provides higher frequency and is required to be used for SD UHS and eMMC HS200/HS400 speed modes. Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
2020-01-16powerpc/mpc85xx: drop eSDHC periperhal clock codeYangbo Lu1-8/+0
The below patch added eSDHC periperhal clock code initially. 2d9ca2c mmc: fsl_esdhc: Add peripheral clock support The purpose was to fix up device tree properties "peripheral-frequency" so that linux could get the periperhal clock by it. However the implementation on both u-boot and linux was only for a Freescale SDK release. The linux part implementation had never been upstreamed. These code should not have been exist on u-boot mainline. Let's remove the powerpc part changes but keep the changes in fsl_esdhc driver. The changes in fsl_esdhc driver could be utilized to support SD UHS and eMMC HS200/HS400 speed modes for current Layerscape ARM platforms. Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
2020-01-08mpc83xx: set MPC83XX_GPIO_CTRLRS to 2 for MPC8309Rasmus Villemoes1-1/+2
The MPC8309 has two gpio controllers (which is already correctly reflected in its struct immap definition). Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk> Reviewed-by: Mario Six <mario.six@gdsys.cc>
2020-01-08mpc83xx: immap_83xx: add spi8xxx_t in immap for mpc8309Rasmus Villemoes2-2/+2
Allow drivers/spi/mpc8xxx_spi.c to be built for an mpc8309 target. Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk> Reviewed-by: Mario Six <mario.six@gdsys.cc>
2019-11-27mpc83xx: remove unused clock.hYangbo Lu1-22/+0
The clock.h was to define mxc_get_clock() providing clock value to fsl_esdhc driver. Since fsl_esdhc driver is using global data gd->arch.sdhc_clk directly now, we can remove this file. Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2019-11-08freescale/powerpc: Rename the config CONFIG_SECURE_BOOT nameUdit Agarwal1-2/+2
Rename the CONFIG_SECURE_BOOT name to CONFIG_NXP_ESBC to avoid conflicts with UEFI secure boot. Signed-off-by: Udit Agarwal <udit.agarwal@nxp.com> Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>
2019-06-20powerpc: mpc85xx: Move CONFIG_FSL_PCIE_DISABLE_ASPM to KconfigHou Zhiqiang1-5/+0
Use the Kconfig option to select the PCIe ASPM errata. Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com> Reviewed-by: Prabhakar Kushwaha <prabhakar.kushwaha@nxp.com>
2019-05-21powerpc: Simplify processor.hMario Six1-120/+0
Lots of stuff in processor.h was taken verbatim from the Linux kernel. It was never synced, so most of it was removed or changed in the kernel since it was imported. Remove all the stuff that is unused in the current U-Boot sources; should anybody feel the need to re-sync with the kernel, they can do it later on. Signed-off-by: Mario Six <mario.six@gdsys.cc>
2019-05-21mpc83xx: Add arch clock.h to make SDHC workMario Six1-0/+22
The fsl-esdhc driver can be used for the SDHC functionality on MPC83xx, but it needs some additional definitions. Add a clock.h file, so we can use the driver for MPC83xx. Signed-off-by: Mario Six <mario.six@gdsys.cc>
2019-05-21mpc83xx: Prepare usage of DM gpio driverMario Six1-0/+8
The MPC85xx GPIO driver was converted to handle a broader range of SoCs. Prepare the MPC83xx code for usage of this driver. Signed-off-by: Mario Six <mario.six@gdsys.cc>
2019-05-21powerpc: mpc83xx: Fix MPC8308 IMMR memory layoutMario Six1-3/+39
The MPC8308 has two I2C controllers, but no PCI controller. Fix the register map layout for this SoC. Signed-off-by: Mario Six <mario.six@gdsys.cc>
2019-05-20powerpc: Add LSDMR config valuesMario Six1-0/+3
The LSDMR_* macros are used to configure the system bus on MPC83xx. A few of the possible LSDMR_* macros were never defined in the respective include files. This renders the SDRAM support on the MPC8349EMDS unusable, because it uses these undefined macros. To make the SDRAM option work, introduce these macros into the proper config file. Signed-off-by: Mario Six <mario.six@gdsys.cc>