From 286a5c44e6bda72e80f7f845f7c5b7fdd5cdf884 Mon Sep 17 00:00:00 2001 From: Adam Ford Date: Tue, 11 Dec 2018 07:41:03 -0600 Subject: ARM: davinci: Orphan Spectrum Digital AM18xx EVM I had requested the da850 boards because their previous maintainer had an invalid e-mail address. I work at Logic PD who makes the da850-evm kits, so I have access to various boards of theirs. The Spectrum Digital AM18xx board is based on the Logic PD da850 EVM, but it's not the same company. Since I don't have the hardware to test/verify changes, I would prefer to not be responsible for this board. Signed-off-by: Adam Ford --- board/davinci/da8xxevm/MAINTAINERS | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/board/davinci/da8xxevm/MAINTAINERS b/board/davinci/da8xxevm/MAINTAINERS index 59589867b3..b77a5f6622 100644 --- a/board/davinci/da8xxevm/MAINTAINERS +++ b/board/davinci/da8xxevm/MAINTAINERS @@ -1,13 +1,16 @@ -DA850_AM18XXEVM BOARD +DA850_EVM BOARD M: Adam Ford S: Maintained F: board/davinci/da8xxevm/ F: include/configs/da850evm.h -F: configs/da850_am18xxevm_defconfig F: configs/da850evm_defconfig F: configs/da850evm_nand_defconfig F: configs/da850evm_direct_nor_defconfig +AM18XXEVM BOARD +S: Orphan +F: configs/da850_am18xxevm_defconfig + OMAPL138_LCDK BOARD M: Peter Howard S: Maintained -- cgit From 5266db16eeba3318e2d0a6e27eb91c0b494d0de4 Mon Sep 17 00:00:00 2001 From: Sumit Garg Date: Tue, 13 Nov 2018 10:21:24 +0530 Subject: qemu-arm: Enable VirtIO distro target With -device virtio-blk-device,drive=hd0, it could detect distro boot target. Signed-off-by: Sumit Garg Reviewed-by: Alexander Graf --- include/configs/qemu-arm.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/configs/qemu-arm.h b/include/configs/qemu-arm.h index fedc4662fa..33dcce0f92 100644 --- a/include/configs/qemu-arm.h +++ b/include/configs/qemu-arm.h @@ -25,6 +25,7 @@ #define BOOT_TARGET_DEVICES(func) \ func(SCSI, scsi, 0) \ + func(VIRTIO, virtio, 0) \ func(DHCP, dhcp, na) #include -- cgit From 03fb0958c9090eb3add089cb9f5a8a5ecb30ddf6 Mon Sep 17 00:00:00 2001 From: Sumit Garg Date: Mon, 26 Nov 2018 16:50:17 +0530 Subject: qemu-arm: Add persistent environment support Currently on qemu-arm platforms environment is kept in RAM. Instead use pflash device 1 to provide persistent environment support across device reset. Also (optionally) provide support for persistent environment across qemu machine OFF/ON using following instructions: - Create envstore.img using qemu-img: qemu-img create -f raw envstore.img 64M - Add a pflash drive parameter to the command line: -drive if=pflash,format=raw,index=1,file=envstore.img Signed-off-by: Sumit Garg --- configs/qemu_arm64_defconfig | 7 +++++++ configs/qemu_arm_defconfig | 7 +++++++ doc/README.qemu-arm | 6 ++++++ include/configs/qemu-arm.h | 8 +++++++- 4 files changed, 27 insertions(+), 1 deletion(-) diff --git a/configs/qemu_arm64_defconfig b/configs/qemu_arm64_defconfig index f4502c9e9f..0f13716c2e 100644 --- a/configs/qemu_arm64_defconfig +++ b/configs/qemu_arm64_defconfig @@ -29,3 +29,10 @@ CONFIG_USB=y CONFIG_DM_USB=y CONFIG_USB_EHCI_HCD=y CONFIG_USB_EHCI_PCI=y +CONFIG_ENV_IS_IN_FLASH=y +CONFIG_MTD=y +CONFIG_MTD_NOR_FLASH=y +CONFIG_FLASH_CFI_DRIVER=y +CONFIG_CFI_FLASH=y +CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y +CONFIG_SYS_FLASH_CFI=y diff --git a/configs/qemu_arm_defconfig b/configs/qemu_arm_defconfig index acebdc5a4e..b75363e305 100644 --- a/configs/qemu_arm_defconfig +++ b/configs/qemu_arm_defconfig @@ -29,3 +29,10 @@ CONFIG_USB=y CONFIG_DM_USB=y CONFIG_USB_EHCI_HCD=y CONFIG_USB_EHCI_PCI=y +CONFIG_ENV_IS_IN_FLASH=y +CONFIG_MTD=y +CONFIG_MTD_NOR_FLASH=y +CONFIG_FLASH_CFI_DRIVER=y +CONFIG_CFI_FLASH=y +CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y +CONFIG_SYS_FLASH_CFI=y diff --git a/doc/README.qemu-arm b/doc/README.qemu-arm index 260165638a..e67bc13f70 100644 --- a/doc/README.qemu-arm +++ b/doc/README.qemu-arm @@ -47,6 +47,12 @@ The minimal QEMU command line to get U-Boot up and running is: Note that for some odd reason qemu-system-aarch64 needs to be explicitly told to use a 64-bit CPU or it will boot in 32-bit mode. +Additional persistent U-boot environment support can be added as follows: +- Create envstore.img using qemu-img: + qemu-img create -f raw envstore.img 64M +- Add a pflash drive parameter to the command line: + -drive if=pflash,format=raw,index=1,file=envstore.img + Additional peripherals that have been tested to work in both U-Boot and Linux can be enabled with the following command line parameters: diff --git a/include/configs/qemu-arm.h b/include/configs/qemu-arm.h index 33dcce0f92..0431a7982d 100644 --- a/include/configs/qemu-arm.h +++ b/include/configs/qemu-arm.h @@ -21,7 +21,8 @@ #define CONFIG_SYS_HZ 1000 /* Environment options */ -#define CONFIG_ENV_SIZE SZ_64K +#define CONFIG_ENV_ADDR 0x4000000 +#define CONFIG_ENV_SIZE SZ_256K #define BOOT_TARGET_DEVICES(func) \ func(SCSI, scsi, 0) \ @@ -43,4 +44,9 @@ #define CONFIG_SYS_CBSIZE 512 +#define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE +#define CONFIG_SYS_FLASH_BASE 0x0 +#define CONFIG_SYS_MAX_FLASH_BANKS 2 +#define CONFIG_SYS_MAX_FLASH_SECT 256 /* Sector: 256K, Bank: 64M */ + #endif /* __CONFIG_H */ -- cgit From b0b1768e1b138204ab07d46cbe7d24d3770f0a12 Mon Sep 17 00:00:00 2001 From: Simon Goldschmidt Date: Tue, 4 Dec 2018 21:30:08 +0100 Subject: test: hexdump: fix misplaced return One of the hexdump tests in test/lib/hexdump.c returns right at the start of the function without testing anything. Fix this by moving the 'return 0;' statement to the end of the function. Signed-off-by: Simon Goldschmidt Reviewed-by: Simon Glass --- test/lib/hexdump.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/lib/hexdump.c b/test/lib/hexdump.c index e8b3e566e0..567b57686a 100644 --- a/test/lib/hexdump.c +++ b/test/lib/hexdump.c @@ -11,8 +11,6 @@ static int lib_test_hex_to_bin(struct unit_test_state *uts) { - return 0; - ut_asserteq(0x0, hex_to_bin('0')); ut_asserteq(0x1, hex_to_bin('1')); ut_asserteq(0x2, hex_to_bin('2')); @@ -30,6 +28,8 @@ static int lib_test_hex_to_bin(struct unit_test_state *uts) ut_asserteq(0xe, hex_to_bin('e')); ut_asserteq(0xf, hex_to_bin('f')); ut_asserteq(-1, hex_to_bin('g')); + + return 0; } DM_TEST(lib_test_hex_to_bin, DM_TESTF_SCAN_PDATA | DM_TESTF_SCAN_FDT); -- cgit From 91ff6865629c81b8643b4ef6130e3e2130c60400 Mon Sep 17 00:00:00 2001 From: Tom Rini Date: Wed, 5 Dec 2018 08:23:38 -0500 Subject: blk: Rework guard around part_init call MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The function part_init() will only be built when we have both CONFIG_PARTITIONS and CONFIG_HAVE_BLOCK_DEVICE set. Protect the call to this function with both of these tests now. Cc: Simon Glass Cc: Philipp Tomsich Cc: Michal Simek Cc: York Sun Cc: Prabhakar Kushwaha Cc: Mingkai Hu Cc: Stefan Roese Cc: Marek BehĂșn Cc: Vanessa Maegima Cc: Eugen Hristev Cc: Adam Ford Cc: Jagan Teki Cc: Tom Warren Cc: Stephen Warren Cc: Vitaly Andrianov Signed-off-by: Tom Rini Reviewed-by: Simon Glass --- common/spl/Kconfig | 3 +++ configs/evb-rk3036_defconfig | 1 + configs/kylin-rk3036_defconfig | 1 + doc/driver-model/MIGRATION.txt | 4 +++- drivers/Makefile | 3 +-- drivers/block/Makefile | 2 ++ drivers/block/blk-uclass.c | 2 +- scripts/Makefile.spl | 4 +++- 8 files changed, 15 insertions(+), 5 deletions(-) diff --git a/common/spl/Kconfig b/common/spl/Kconfig index 0ddbffc7d1..cab7220c9a 100644 --- a/common/spl/Kconfig +++ b/common/spl/Kconfig @@ -449,6 +449,7 @@ config SPL_LIBCOMMON_SUPPORT config SPL_LIBDISK_SUPPORT bool "Support disk partitions" + select PARTITIONS help Enable support for disk partitions within SPL. 'Disk' is something of a misnomer as it includes non-spinning media such as flash (as @@ -480,6 +481,7 @@ config SPL_DM_MAILBOX config SPL_MMC_SUPPORT bool "Support MMC" depends on MMC + select HAVE_BLOCK_DEVICE help Enable support for MMC (Multimedia Card) within SPL. This enables the MMC protocol implementation and allows any enabled drivers to @@ -754,6 +756,7 @@ config SPL_THERMAL config SPL_USB_HOST_SUPPORT bool "Support USB host drivers" + select HAVE_BLOCK_DEVICE help Enable access to USB (Universal Serial Bus) host devices so that SPL can load U-Boot from a connected USB peripheral, such as a USB diff --git a/configs/evb-rk3036_defconfig b/configs/evb-rk3036_defconfig index 787d6f95c1..439e691386 100644 --- a/configs/evb-rk3036_defconfig +++ b/configs/evb-rk3036_defconfig @@ -32,6 +32,7 @@ CONFIG_SPL_PARTITION_UUIDS=y CONFIG_DEFAULT_DEVICE_TREE="rk3036-sdk" CONFIG_REGMAP=y CONFIG_SYSCON=y +# CONFIG_SPL_BLK is not set CONFIG_CLK=y CONFIG_FASTBOOT_FLASH=y CONFIG_FASTBOOT_FLASH_MMC_DEV=0 diff --git a/configs/kylin-rk3036_defconfig b/configs/kylin-rk3036_defconfig index eb305e02aa..765003095c 100644 --- a/configs/kylin-rk3036_defconfig +++ b/configs/kylin-rk3036_defconfig @@ -30,6 +30,7 @@ CONFIG_DEFAULT_DEVICE_TREE="rk3036-sdk" CONFIG_ENV_IS_IN_MMC=y CONFIG_REGMAP=y CONFIG_SYSCON=y +# CONFIG_SPL_BLK is not set CONFIG_CLK=y CONFIG_FASTBOOT_FLASH=y CONFIG_FASTBOOT_FLASH_MMC_DEV=0 diff --git a/doc/driver-model/MIGRATION.txt b/doc/driver-model/MIGRATION.txt index 6b691338b4..dce4aa3e1d 100644 --- a/doc/driver-model/MIGRATION.txt +++ b/doc/driver-model/MIGRATION.txt @@ -44,7 +44,9 @@ Deadline: 2019.07 In concert with maintainers migrating their block device usage to the appropriate DM driver, CONFIG_BLK needs to be set as well. The final deadline here coincides with the final deadline for migration of the various block -subsystems. +subsystems. At this point we will be able to audit and correct the logic in +Kconfig around using CONFIG_PARTITIONS and CONFIG_HAVE_BLOCK_DEVICE and make +use of CONFIG_BLK / CONFIG_SPL_BLK as needed. CONFIG_DM_SPI CONFIG_DM_SPI_FLASH diff --git a/drivers/Makefile b/drivers/Makefile index c425831b58..0538b50d01 100644 --- a/drivers/Makefile +++ b/drivers/Makefile @@ -53,8 +53,7 @@ obj-$(CONFIG_SPL_WATCHDOG_SUPPORT) += watchdog/ obj-$(CONFIG_SPL_USB_HOST_SUPPORT) += usb/host/ obj-$(CONFIG_OMAP_USB_PHY) += usb/phy/ obj-$(CONFIG_SPL_SATA_SUPPORT) += ata/ scsi/ -obj-$(CONFIG_SPL_USB_HOST_SUPPORT) += block/ -obj-$(CONFIG_SPL_MMC_SUPPORT) += block/ +obj-$(CONFIG_HAVE_BLOCK_DEVICE) += block/ obj-$(CONFIG_SPL_FPGA_SUPPORT) += fpga/ obj-$(CONFIG_SPL_THERMAL) += thermal/ diff --git a/drivers/block/Makefile b/drivers/block/Makefile index 055d42f7d4..3feb0aa997 100644 --- a/drivers/block/Makefile +++ b/drivers/block/Makefile @@ -9,6 +9,8 @@ ifndef CONFIG_$(SPL_)BLK obj-y += blk_legacy.o endif +ifndef CONFIG_SPL_BUILD obj-$(CONFIG_IDE) += ide.o +endif obj-$(CONFIG_SANDBOX) += sandbox.o obj-$(CONFIG_$(SPL_TPL_)BLOCK_CACHE) += blkcache.o diff --git a/drivers/block/blk-uclass.c b/drivers/block/blk-uclass.c index 65a766e586..baaf431e5e 100644 --- a/drivers/block/blk-uclass.c +++ b/drivers/block/blk-uclass.c @@ -639,7 +639,7 @@ int blk_unbind_all(int if_type) static int blk_post_probe(struct udevice *dev) { -#if !defined(CONFIG_SPL_BUILD) || defined(CONFIG_SPL_LIBDISK_SUPPORT) +#if defined(CONFIG_PARTITIONS) && defined(CONFIG_HAVE_BLOCK_DEVICE) struct blk_desc *desc = dev_get_uclass_platdata(dev); part_init(desc); diff --git a/scripts/Makefile.spl b/scripts/Makefile.spl index 22bd8f7c27..2ef19bf005 100644 --- a/scripts/Makefile.spl +++ b/scripts/Makefile.spl @@ -81,9 +81,11 @@ libs-$(CONFIG_TPL_LIBGENERIC_SUPPORT) += lib/ else libs-$(CONFIG_SPL_LIBCOMMON_SUPPORT) += common/ cmd/ env/ libs-$(CONFIG_SPL_LIBGENERIC_SUPPORT) += lib/ +ifdef CONFIG_SPL_FRAMEWORK +libs-$(CONFIG_PARTITIONS) += disk/ +endif endif -libs-$(CONFIG_SPL_LIBDISK_SUPPORT) += disk/ libs-y += drivers/ libs-$(CONFIG_SPL_USB_GADGET_SUPPORT) += drivers/usb/dwc3/ libs-y += dts/ -- cgit From 841d5fbae4e993476fa87d8933db0cd58d3c2d41 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Wed, 5 Dec 2018 06:57:08 -0700 Subject: fdt: Add warning about CONFIG_OF_EMBED This option has crept into use with some boards. Add a warning to try to prevent this. As an example: https://lists.denx.de/pipermail/u-boot/2017-September/304966.html Signed-off-by: Simon Glass Reviewed-by: Tom Rini --- Makefile | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Makefile b/Makefile index 0d11ff9797..05896598fe 100644 --- a/Makefile +++ b/Makefile @@ -947,6 +947,14 @@ ifeq ($(CONFIG_LIBATA)$(CONFIG_DM_SCSI)$(CONFIG_MVSATA_IDE),y) @echo "Failure to update by the deadline may result in board removal." @echo "See doc/driver-model/MIGRATION.txt for more info." @echo "====================================================" +endif +ifeq ($(CONFIG_OF_EMBED),y) + @echo "===================== WARNING ======================" + @echo "CONFIG_OF_EMBED is enabled. This option should only" + @echo "be used for debugging purposes. Please use" + @echo "CONFIG_OF_SEPARATE for boards in mainline." + @echo "See doc/README.fdt-control for more info." + @echo "====================================================" endif @# Check that this build does not use CONFIG options that we do not @# know about unless they are in Kconfig. All the existing CONFIG -- cgit From a6f6939e87c7d70f4844a73bc115caaf9c0a19e0 Mon Sep 17 00:00:00 2001 From: "Andrew F. Davis" Date: Wed, 5 Dec 2018 12:33:33 -0600 Subject: defconfigs: am335x_hs_evm: Sync HS and non-HS defconfigs Sync new additions to non-HS defconfig with HS defconfig. Signed-off-by: Andrew F. Davis Reviewed-by: Tom Rini --- configs/am335x_hs_evm_defconfig | 8 +++----- configs/am335x_hs_evm_uart_defconfig | 13 +++++++++++-- 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/configs/am335x_hs_evm_defconfig b/configs/am335x_hs_evm_defconfig index aa6e9665d2..1a7c5cfb17 100644 --- a/configs/am335x_hs_evm_defconfig +++ b/configs/am335x_hs_evm_defconfig @@ -1,6 +1,4 @@ CONFIG_ARM=y -# CONFIG_SPL_USE_ARCH_MEMCPY is not set -# CONFIG_SPL_USE_ARCH_MEMSET is not set CONFIG_ARCH_OMAP2PLUS=y CONFIG_TI_SECURE_DEVICE=y CONFIG_TI_COMMON_CMD_OPTIONS=y @@ -8,10 +6,11 @@ CONFIG_AM33XX=y CONFIG_ISW_ENTRY_ADDR=0x40300350 CONFIG_SPL=y CONFIG_DISTRO_DEFAULTS=y -CONFIG_ANDROID_BOOT_IMAGE=y CONFIG_FIT_IMAGE_POST_PROCESS=y CONFIG_SPL_LOAD_FIT=y CONFIG_SPL_FIT_IMAGE_POST_PROCESS=y +CONFIG_OF_BOARD_SETUP=y +CONFIG_BOOTCOMMAND="if test ${boot_fit} -eq 1; then run update_to_fit; fi; run findfdt; run init_console; run envboot; run distro_bootcmd" CONFIG_LOGLEVEL=3 CONFIG_SYS_CONSOLE_INFO_QUIET=y CONFIG_VERSION_VARIABLE=y @@ -47,9 +46,9 @@ CONFIG_NAND=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_WINBOND=y CONFIG_DM_ETH=y -CONFIG_DRIVER_TI_CPSW=y CONFIG_PHY_GIGE=y CONFIG_MII=y +CONFIG_DRIVER_TI_CPSW=y CONFIG_SPI=y CONFIG_OMAP3_SPI=y CONFIG_TIMER=y @@ -60,7 +59,6 @@ CONFIG_USB_MUSB_HOST=y CONFIG_USB_MUSB_GADGET=y CONFIG_USB_MUSB_TI=y CONFIG_USB_MUSB_DSPS=y -CONFIG_USB_STORAGE=y CONFIG_USB_GADGET=y CONFIG_USB_GADGET_MANUFACTURER="Texas Instruments" CONFIG_USB_GADGET_VENDOR_NUM=0x0451 diff --git a/configs/am335x_hs_evm_uart_defconfig b/configs/am335x_hs_evm_uart_defconfig index 419b41c1ee..147da80f0d 100644 --- a/configs/am335x_hs_evm_uart_defconfig +++ b/configs/am335x_hs_evm_uart_defconfig @@ -12,9 +12,13 @@ CONFIG_DISTRO_DEFAULTS=y CONFIG_FIT_IMAGE_POST_PROCESS=y CONFIG_SPL_LOAD_FIT=y CONFIG_SPL_FIT_IMAGE_POST_PROCESS=y +CONFIG_OF_BOARD_SETUP=y +CONFIG_BOOTCOMMAND="if test ${boot_fit} -eq 1; then run update_to_fit; fi; run findfdt; run init_console; run envboot; run distro_bootcmd" +CONFIG_LOGLEVEL=3 CONFIG_SYS_CONSOLE_INFO_QUIET=y CONFIG_VERSION_VARIABLE=y CONFIG_ARCH_MISC_INIT=y +CONFIG_SPL_FIT_IMAGE_TINY=y # CONFIG_SPL_ENV_SUPPORT is not set # CONFIG_SPL_EXT_SUPPORT is not set CONFIG_SPL_MTD_SUPPORT=y @@ -38,14 +42,15 @@ CONFIG_DFU_RAM=y CONFIG_DM_I2C=y CONFIG_MISC=y CONFIG_DM_MMC=y +# CONFIG_MMC_HW_PARTITIONING is not set CONFIG_MMC_OMAP_HS=y CONFIG_NAND=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_WINBOND=y CONFIG_DM_ETH=y -CONFIG_DRIVER_TI_CPSW=y CONFIG_PHY_GIGE=y CONFIG_MII=y +CONFIG_DRIVER_TI_CPSW=y CONFIG_SPI=y CONFIG_OMAP3_SPI=y CONFIG_TIMER=y @@ -56,8 +61,12 @@ CONFIG_USB_MUSB_HOST=y CONFIG_USB_MUSB_GADGET=y CONFIG_USB_MUSB_TI=y CONFIG_USB_MUSB_DSPS=y -CONFIG_USB_STORAGE=y CONFIG_USB_GADGET=y +CONFIG_USB_GADGET_MANUFACTURER="Texas Instruments" +CONFIG_USB_GADGET_VENDOR_NUM=0x0451 +CONFIG_USB_GADGET_PRODUCT_NUM=0xd022 CONFIG_USB_GADGET_DOWNLOAD=y +CONFIG_USB_ETHER=y +CONFIG_SPL_TINY_MEMSET=y CONFIG_RSA=y CONFIG_LZO=y -- cgit From d50d6817b583d20bf1c6e26c656d125bde5e4e4b Mon Sep 17 00:00:00 2001 From: Sekhar Nori Date: Thu, 6 Dec 2018 15:40:08 +0530 Subject: spl: fix build failure with !CONFIG_SPL_PCI_SUPPORT Building U-Boot with CONFIG_PCI and CONFIG_DM_PCI enabled, but CONFIG_SPL_PCI_SUPPORT disabled, results in following linker error: lib/built-in.o: In function `fdtdec_get_pci_bar32': lib/fdtdec.c:305: undefined reference to `dm_pci_read_bar32' fdtdec.c:305:(.text.fdtdec_get_pci_bar32+0x24): relocation truncated to fit: R_AARCH64_CALL26 against undefined symbol `dm_pci_read_bar32' This is because reference to dm_pci_read_bar32() remains in lib/fdtdec.c while SPL build does not descend into drivers/pci directory in drivers/Makefile if CONFIG_SPL_PCI_SUPPORT is not enabled. Fix this by applying appropriate #define guards in lib/fdtdec.c. It looks like ns16550.c has the same problem, so fixed that too. To simplify this, CONFIG_SPL_PCI_SUPPORT is renamed to CONFIG_SPL_PCI (enables use of CONFIG_IS_ENABLED() macro). Suggested-by: Vignesh R Signed-off-by: Sekhar Nori Reviewed-by: Lokesh Vutla Reviewed-by: Tom Rini --- Makefile | 1 - common/spl/Kconfig | 4 ++-- configs/chromebook_link64_defconfig | 2 +- configs/qemu-x86_64_defconfig | 2 +- drivers/Makefile | 2 +- drivers/serial/ns16550.c | 2 +- lib/fdtdec.c | 2 +- 7 files changed, 7 insertions(+), 8 deletions(-) diff --git a/Makefile b/Makefile index 05896598fe..5683714947 100644 --- a/Makefile +++ b/Makefile @@ -695,7 +695,6 @@ libs-$(CONFIG_CMD_UBI) += drivers/mtd/ubi/ libs-y += drivers/mtd/spi/ libs-y += drivers/net/ libs-y += drivers/net/phy/ -libs-y += drivers/pci/ libs-y += drivers/power/ \ drivers/power/domain/ \ drivers/power/fuel_gauge/ \ diff --git a/common/spl/Kconfig b/common/spl/Kconfig index cab7220c9a..953841ebe7 100644 --- a/common/spl/Kconfig +++ b/common/spl/Kconfig @@ -612,7 +612,7 @@ config SPL_PAYLOAD TPL, tpl/u-boot-with-tpl.bin. For new boards, suggest to use u-boot.img. -config SPL_PCI_SUPPORT +config SPL_PCI bool "Support PCI drivers" help Enable support for PCI in SPL. For platforms that need PCI to boot, @@ -1026,7 +1026,7 @@ config TPL_NAND_SUPPORT help Enable support for NAND in TPL. See SPL_NAND_SUPPORT for details. -config TPL_PCI_SUPPORT +config TPL_PCI bool "Support PCI drivers" help Enable support for PCI in TPL. For platforms that need PCI to boot, diff --git a/configs/chromebook_link64_defconfig b/configs/chromebook_link64_defconfig index 13b90a13f6..074d333dd4 100644 --- a/configs/chromebook_link64_defconfig +++ b/configs/chromebook_link64_defconfig @@ -33,7 +33,7 @@ CONFIG_SPL_CPU_SUPPORT=y CONFIG_SPL_ENV_SUPPORT=y CONFIG_SPL_I2C_SUPPORT=y CONFIG_SPL_NET_SUPPORT=y -CONFIG_SPL_PCI_SUPPORT=y +CONFIG_SPL_PCI=y CONFIG_SPL_PCH_SUPPORT=y CONFIG_SPL_RTC_SUPPORT=y CONFIG_HUSH_PARSER=y diff --git a/configs/qemu-x86_64_defconfig b/configs/qemu-x86_64_defconfig index 32922b84ff..8d43acd480 100644 --- a/configs/qemu-x86_64_defconfig +++ b/configs/qemu-x86_64_defconfig @@ -31,7 +31,7 @@ CONFIG_SPL_SYS_MALLOC_SIMPLE=y CONFIG_SPL_CPU_SUPPORT=y CONFIG_SPL_ENV_SUPPORT=y CONFIG_SPL_NET_SUPPORT=y -CONFIG_SPL_PCI_SUPPORT=y +CONFIG_SPL_PCI=y CONFIG_SPL_PCH_SUPPORT=y CONFIG_SPL_RTC_SUPPORT=y CONFIG_HUSH_PARSER=y diff --git a/drivers/Makefile b/drivers/Makefile index 0538b50d01..752caeae4e 100644 --- a/drivers/Makefile +++ b/drivers/Makefile @@ -10,7 +10,7 @@ obj-$(CONFIG_$(SPL_TPL_)LED) += led/ obj-$(CONFIG_$(SPL_TPL_)MMC_SUPPORT) += mmc/ obj-$(CONFIG_$(SPL_TPL_)NAND_SUPPORT) += mtd/nand/raw/ obj-$(CONFIG_$(SPL_TPL_)PCH_SUPPORT) += pch/ -obj-$(CONFIG_$(SPL_TPL_)PCI_SUPPORT) += pci/ +obj-$(CONFIG_$(SPL_TPL_)PCI) += pci/ obj-$(CONFIG_$(SPL_TPL_)PHY) += phy/ obj-$(CONFIG_$(SPL_TPL_)PINCTRL) += pinctrl/ obj-$(CONFIG_$(SPL_TPL_)RAM) += ram/ diff --git a/drivers/serial/ns16550.c b/drivers/serial/ns16550.c index f3bd8dbcdf..560ca2ae34 100644 --- a/drivers/serial/ns16550.c +++ b/drivers/serial/ns16550.c @@ -425,7 +425,7 @@ int ns16550_serial_ofdata_to_platdata(struct udevice *dev) /* try Processor Local Bus device first */ addr = dev_read_addr(dev); -#if defined(CONFIG_PCI) && defined(CONFIG_DM_PCI) +#if CONFIG_IS_ENABLED(PCI) && defined(CONFIG_DM_PCI) if (addr == FDT_ADDR_T_NONE) { /* then try pci device */ struct fdt_pci_addr pci_addr; diff --git a/lib/fdtdec.c b/lib/fdtdec.c index 7bbc6d445e..6f8ec0dbed 100644 --- a/lib/fdtdec.c +++ b/lib/fdtdec.c @@ -200,7 +200,7 @@ fdt_addr_t fdtdec_get_addr(const void *blob, int node, const char *prop_name) return fdtdec_get_addr_size(blob, node, prop_name, NULL); } -#if defined(CONFIG_PCI) && defined(CONFIG_DM_PCI) +#if CONFIG_IS_ENABLED(PCI) && defined(CONFIG_DM_PCI) int fdtdec_get_pci_addr(const void *blob, int node, enum fdt_pci_space type, const char *prop_name, struct fdt_pci_addr *addr) { -- cgit From bfaaacd3b2cb0d7841d9ae7d14ea5da130b8f482 Mon Sep 17 00:00:00 2001 From: Felix Brack Date: Fri, 7 Dec 2018 15:01:55 +0100 Subject: arm: am335x-pdu001: Move from embedded to separate DTB There is no need for an embedded device tree for this board so let the build process generate a separate u-boot.dtb file instead. Signed-off-by: Felix Brack --- arch/arm/mach-omap2/am33xx/Kconfig | 1 + configs/am335x_pdu001_defconfig | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/arm/mach-omap2/am33xx/Kconfig b/arch/arm/mach-omap2/am33xx/Kconfig index 3529607479..57284c4ae1 100644 --- a/arch/arm/mach-omap2/am33xx/Kconfig +++ b/arch/arm/mach-omap2/am33xx/Kconfig @@ -206,6 +206,7 @@ config TARGET_PDU001 bool "Support PDU001" select DM select DM_SERIAL + imply SPL_SEPARATE_BSS imply CMD_DM help Support for PDU001 platform developed by EETS GmbH. diff --git a/configs/am335x_pdu001_defconfig b/configs/am335x_pdu001_defconfig index dc8094e2b8..b69cee01e4 100644 --- a/configs/am335x_pdu001_defconfig +++ b/configs/am335x_pdu001_defconfig @@ -32,7 +32,7 @@ CONFIG_CMD_PMIC=y CONFIG_CMD_REGULATOR=y CONFIG_OF_CONTROL=y CONFIG_SPL_OF_CONTROL=y -CONFIG_OF_EMBED=y +CONFIG_OF_SEPARATE=y CONFIG_DEFAULT_DEVICE_TREE="am335x-pdu001" # CONFIG_NET is not set CONFIG_SPL_DM=y -- cgit From f99f4ebb548a7b3d266b12fe46ca08edd7f6b093 Mon Sep 17 00:00:00 2001 From: Adam Ford Date: Fri, 7 Dec 2018 14:38:33 -0600 Subject: ARM: omap3_logic/omap35_logic: Move to DM_USB The existing config is setup as a gadget but it doesn't use DM_USB. This patch converts all boards to DM_USB, but as host. As host, it is able to mount USB drives and browse them. Signed-off-by: Adam Ford --- configs/omap35_logic_defconfig | 13 ++++--------- configs/omap35_logic_somlv_defconfig | 13 ++++--------- configs/omap3_logic_defconfig | 13 ++++--------- configs/omap3_logic_somlv_defconfig | 13 ++++--------- 4 files changed, 16 insertions(+), 36 deletions(-) diff --git a/configs/omap35_logic_defconfig b/configs/omap35_logic_defconfig index 80219eeacf..82ddaa3a2b 100644 --- a/configs/omap35_logic_defconfig +++ b/configs/omap35_logic_defconfig @@ -9,6 +9,7 @@ CONFIG_TARGET_OMAP3_LOGIC=y CONFIG_SPL=y CONFIG_DISTRO_DEFAULTS=y CONFIG_NR_DRAM_BANKS=2 +CONFIG_ANDROID_BOOT_IMAGE=y # CONFIG_USE_BOOTCOMMAND is not set CONFIG_SYS_CONSOLE_INFO_QUIET=y CONFIG_VERSION_VARIABLE=y @@ -34,8 +35,6 @@ CONFIG_DEFAULT_DEVICE_TREE="logicpd-torpedo-35xx-devkit" # CONFIG_ENV_IS_IN_FAT is not set CONFIG_ENV_IS_IN_NAND=y CONFIG_SPL_DM=y -CONFIG_USB_FUNCTION_FASTBOOT=y -CONFIG_FASTBOOT_BUF_ADDR=0x82000000 CONFIG_DM_I2C=y CONFIG_DM_MMC=y CONFIG_MMC_OMAP_HS=y @@ -59,14 +58,10 @@ CONFIG_SPI=y CONFIG_DM_SPI=y CONFIG_OMAP3_SPI=y CONFIG_USB=y +CONFIG_DM_USB=y +# CONFIG_SPL_DM_USB is not set CONFIG_USB_EHCI_HCD=y -CONFIG_USB_MUSB_GADGET=y +CONFIG_USB_MUSB_HOST=y CONFIG_USB_MUSB_OMAP2PLUS=y CONFIG_TWL4030_USB=y -CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="TI" -CONFIG_USB_GADGET_VENDOR_NUM=0x0451 -CONFIG_USB_GADGET_PRODUCT_NUM=0xd022 -CONFIG_USB_ETHER=y CONFIG_BCH=y -# CONFIG_SPL_OF_LIBFDT is not set diff --git a/configs/omap35_logic_somlv_defconfig b/configs/omap35_logic_somlv_defconfig index 8a8c7147c3..94f86efe28 100644 --- a/configs/omap35_logic_somlv_defconfig +++ b/configs/omap35_logic_somlv_defconfig @@ -9,6 +9,7 @@ CONFIG_TARGET_OMAP3_LOGIC=y CONFIG_SPL=y CONFIG_DISTRO_DEFAULTS=y CONFIG_NR_DRAM_BANKS=2 +CONFIG_ANDROID_BOOT_IMAGE=y # CONFIG_USE_BOOTCOMMAND is not set CONFIG_SYS_CONSOLE_INFO_QUIET=y CONFIG_VERSION_VARIABLE=y @@ -34,8 +35,6 @@ CONFIG_DEFAULT_DEVICE_TREE="logicpd-som-lv-35xx-devkit" # CONFIG_ENV_IS_IN_FAT is not set CONFIG_ENV_IS_IN_NAND=y CONFIG_SPL_DM=y -CONFIG_USB_FUNCTION_FASTBOOT=y -CONFIG_FASTBOOT_BUF_ADDR=0x82000000 CONFIG_DM_I2C=y CONFIG_DM_MMC=y CONFIG_MMC_OMAP_HS=y @@ -65,14 +64,10 @@ CONFIG_SPI=y CONFIG_DM_SPI=y CONFIG_OMAP3_SPI=y CONFIG_USB=y +CONFIG_DM_USB=y +# CONFIG_SPL_DM_USB is not set CONFIG_USB_EHCI_HCD=y -CONFIG_USB_MUSB_GADGET=y +CONFIG_USB_MUSB_HOST=y CONFIG_USB_MUSB_OMAP2PLUS=y CONFIG_TWL4030_USB=y -CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="TI" -CONFIG_USB_GADGET_VENDOR_NUM=0x0451 -CONFIG_USB_GADGET_PRODUCT_NUM=0xd022 -CONFIG_USB_ETHER=y CONFIG_BCH=y -# CONFIG_SPL_OF_LIBFDT is not set diff --git a/configs/omap3_logic_defconfig b/configs/omap3_logic_defconfig index 31972598cb..cfb7fd2edc 100644 --- a/configs/omap3_logic_defconfig +++ b/configs/omap3_logic_defconfig @@ -9,6 +9,7 @@ CONFIG_TARGET_OMAP3_LOGIC=y CONFIG_SPL=y CONFIG_DISTRO_DEFAULTS=y CONFIG_NR_DRAM_BANKS=2 +CONFIG_ANDROID_BOOT_IMAGE=y # CONFIG_USE_BOOTCOMMAND is not set CONFIG_SYS_CONSOLE_INFO_QUIET=y CONFIG_VERSION_VARIABLE=y @@ -35,8 +36,6 @@ CONFIG_DEFAULT_DEVICE_TREE="logicpd-torpedo-37xx-devkit" CONFIG_ENV_IS_IN_NAND=y CONFIG_SPL_DM=y CONFIG_SPL_DM_SEQ_ALIAS=y -CONFIG_USB_FUNCTION_FASTBOOT=y -CONFIG_FASTBOOT_BUF_ADDR=0x82000000 CONFIG_DM_I2C=y CONFIG_DM_MMC=y CONFIG_MMC_OMAP_HS=y @@ -61,14 +60,10 @@ CONFIG_SPI=y CONFIG_DM_SPI=y CONFIG_OMAP3_SPI=y CONFIG_USB=y +CONFIG_DM_USB=y +# CONFIG_SPL_DM_USB is not set CONFIG_USB_EHCI_HCD=y -CONFIG_USB_MUSB_GADGET=y +CONFIG_USB_MUSB_HOST=y CONFIG_USB_MUSB_OMAP2PLUS=y CONFIG_TWL4030_USB=y -CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="TI" -CONFIG_USB_GADGET_VENDOR_NUM=0x0451 -CONFIG_USB_GADGET_PRODUCT_NUM=0xd022 -CONFIG_USB_ETHER=y CONFIG_BCH=y -# CONFIG_SPL_OF_LIBFDT is not set diff --git a/configs/omap3_logic_somlv_defconfig b/configs/omap3_logic_somlv_defconfig index 396543e56b..c30c43bbda 100644 --- a/configs/omap3_logic_somlv_defconfig +++ b/configs/omap3_logic_somlv_defconfig @@ -9,6 +9,7 @@ CONFIG_TARGET_OMAP3_LOGIC=y CONFIG_SPL=y CONFIG_DISTRO_DEFAULTS=y CONFIG_NR_DRAM_BANKS=2 +CONFIG_ANDROID_BOOT_IMAGE=y # CONFIG_USE_BOOTCOMMAND is not set CONFIG_SYS_CONSOLE_INFO_QUIET=y CONFIG_VERSION_VARIABLE=y @@ -33,8 +34,6 @@ CONFIG_DEFAULT_DEVICE_TREE="logicpd-som-lv-37xx-devkit" # CONFIG_ENV_IS_IN_FAT is not set CONFIG_ENV_IS_IN_NAND=y CONFIG_SPL_DM=y -CONFIG_USB_FUNCTION_FASTBOOT=y -CONFIG_FASTBOOT_BUF_ADDR=0x82000000 CONFIG_DM_I2C=y CONFIG_DM_MMC=y CONFIG_MMC_OMAP_HS=y @@ -65,14 +64,10 @@ CONFIG_SPI=y CONFIG_DM_SPI=y CONFIG_OMAP3_SPI=y CONFIG_USB=y +CONFIG_DM_USB=y +# CONFIG_SPL_DM_USB is not set CONFIG_USB_EHCI_HCD=y -CONFIG_USB_MUSB_GADGET=y +CONFIG_USB_MUSB_HOST=y CONFIG_USB_MUSB_OMAP2PLUS=y CONFIG_TWL4030_USB=y -CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="TI" -CONFIG_USB_GADGET_VENDOR_NUM=0x0451 -CONFIG_USB_GADGET_PRODUCT_NUM=0xd022 -CONFIG_USB_ETHER=y CONFIG_BCH=y -# CONFIG_SPL_OF_LIBFDT is not set -- cgit From 76f6d52e61a1968702af69d6cea463b9d9332a96 Mon Sep 17 00:00:00 2001 From: Adam Ford Date: Fri, 7 Dec 2018 17:28:03 -0600 Subject: ARM: omap3logic: Remove legacy USB code in favor of DM_USB With the defconfig options enabling DM_USB, the legacy code can be removed. Signed-off-by: Adam Ford --- board/logicpd/omap3som/omap3logic.c | 61 ------------------------------------- 1 file changed, 61 deletions(-) diff --git a/board/logicpd/omap3som/omap3logic.c b/board/logicpd/omap3som/omap3logic.c index 691d38fdf2..144e6f68a4 100644 --- a/board/logicpd/omap3som/omap3logic.c +++ b/board/logicpd/omap3som/omap3logic.c @@ -164,61 +164,6 @@ void spl_board_prepare_for_linux(void) } #endif -#if !CONFIG_IS_ENABLED(DM_USB) -#ifdef CONFIG_USB_MUSB_OMAP2PLUS -static struct musb_hdrc_config musb_config = { - .multipoint = 1, - .dyn_fifo = 1, - .num_eps = 16, - .ram_bits = 12, -}; - -static struct omap_musb_board_data musb_board_data = { - .interface_type = MUSB_INTERFACE_ULPI, -}; - -static struct musb_hdrc_platform_data musb_plat = { -#if defined(CONFIG_USB_MUSB_HOST) - .mode = MUSB_HOST, -#elif defined(CONFIG_USB_MUSB_GADGET) - .mode = MUSB_PERIPHERAL, -#else -#error "Please define either CONFIG_USB_MUSB_HOST or CONFIG_USB_MUSB_GADGET" -#endif - .config = &musb_config, - .power = 100, - .platform_ops = &omap2430_ops, - .board_data = &musb_board_data, -}; -#endif - -#if defined(CONFIG_USB_EHCI_HCD) && !defined(CONFIG_SPL_BUILD) -/* Call usb_stop() before starting the kernel */ -void show_boot_progress(int val) -{ - if (val == BOOTSTAGE_ID_RUN_OS) - usb_stop(); -} - -static struct omap_usbhs_board_data usbhs_bdata = { - .port_mode[0] = OMAP_EHCI_PORT_MODE_PHY, - .port_mode[1] = OMAP_EHCI_PORT_MODE_PHY, - .port_mode[2] = OMAP_USBHS_PORT_MODE_UNUSED -}; - -int ehci_hcd_init(int index, enum usb_init_type init, - struct ehci_hccr **hccr, struct ehci_hcor **hcor) -{ - return omap_ehci_hcd_init(index, &usbhs_bdata, hccr, hcor); -} - -int ehci_hcd_stop(int index) -{ - return omap_ehci_hcd_stop(); -} - -#endif /* CONFIG_USB_EHCI_HCD */ -#endif /* !DM_USB*/ /* * Routine: misc_init_r * Description: Configure board specific parts @@ -227,12 +172,6 @@ int misc_init_r(void) { twl4030_power_init(); omap_die_id_display(); - -#if !CONFIG_IS_ENABLED(DM_USB) -#ifdef CONFIG_USB_MUSB_OMAP2PLUS - musb_register(&musb_plat, &musb_board_data, (void *)MUSB_BASE); -#endif -#endif return 0; } -- cgit From 3cc137616d0aed8990f9cd10cc07dba79df99cd6 Mon Sep 17 00:00:00 2001 From: Heinrich Schuchardt Date: Sat, 8 Dec 2018 09:53:05 +0100 Subject: test: overlay: NULL passed as fdt The uts created in do_ut_overlay() is not the one used in cmd_ut_category(). Currently all tests are therefore called with uts->priv = NULL and fail. Using a static variable is the easiest fix here. Fixes: e93232e15ec9 ("test: overlay: Use cmd_ut_category()") Signed-off-by: Heinrich Schuchardt --- test/overlay/cmd_ut_overlay.c | 28 +++++++++------------------- 1 file changed, 9 insertions(+), 19 deletions(-) diff --git a/test/overlay/cmd_ut_overlay.c b/test/overlay/cmd_ut_overlay.c index 3d34c8ab53..fc2491d0b4 100644 --- a/test/overlay/cmd_ut_overlay.c +++ b/test/overlay/cmd_ut_overlay.c @@ -23,6 +23,8 @@ extern u32 __dtb_test_fdt_base_begin; extern u32 __dtb_test_fdt_overlay_begin; extern u32 __dtb_test_fdt_overlay_stacked_begin; +static void *fdt; + static int ut_fdt_getprop_u32_by_index(void *fdt, const char *path, const char *name, int index, u32 *out) @@ -67,7 +69,6 @@ static int fdt_getprop_str(void *fdt, const char *path, const char *name, static int fdt_overlay_change_int_property(struct unit_test_state *uts) { - void *fdt = uts->priv; u32 val = 0; ut_assertok(ut_fdt_getprop_u32(fdt, "/test-node", "test-int-property", @@ -80,7 +81,6 @@ OVERLAY_TEST(fdt_overlay_change_int_property, 0); static int fdt_overlay_change_str_property(struct unit_test_state *uts) { - void *fdt = uts->priv; const char *val = NULL; ut_assertok(fdt_getprop_str(fdt, "/test-node", "test-str-property", @@ -93,7 +93,6 @@ OVERLAY_TEST(fdt_overlay_change_str_property, 0); static int fdt_overlay_add_str_property(struct unit_test_state *uts) { - void *fdt = uts->priv; const char *val = NULL; ut_assertok(fdt_getprop_str(fdt, "/test-node", "test-str-property-2", @@ -106,7 +105,6 @@ OVERLAY_TEST(fdt_overlay_add_str_property, 0); static int fdt_overlay_add_node_by_phandle(struct unit_test_state *uts) { - void *fdt = uts->priv; int off; off = fdt_path_offset(fdt, "/test-node/new-node"); @@ -120,7 +118,6 @@ OVERLAY_TEST(fdt_overlay_add_node_by_phandle, 0); static int fdt_overlay_add_node_by_path(struct unit_test_state *uts) { - void *fdt = uts->priv; int off; off = fdt_path_offset(fdt, "/new-node"); @@ -134,7 +131,6 @@ OVERLAY_TEST(fdt_overlay_add_node_by_path, 0); static int fdt_overlay_add_subnode_property(struct unit_test_state *uts) { - void *fdt = uts->priv; int off; off = fdt_path_offset(fdt, "/test-node/sub-test-node"); @@ -150,7 +146,6 @@ OVERLAY_TEST(fdt_overlay_add_subnode_property, 0); static int fdt_overlay_local_phandle(struct unit_test_state *uts) { uint32_t local_phandle; - void *fdt = uts->priv; u32 val = 0; int off; @@ -175,7 +170,6 @@ OVERLAY_TEST(fdt_overlay_local_phandle, 0); static int fdt_overlay_local_phandles(struct unit_test_state *uts) { uint32_t local_phandle, test_phandle; - void *fdt = uts->priv; u32 val = 0; int off; @@ -205,7 +199,6 @@ OVERLAY_TEST(fdt_overlay_local_phandles, 0); static int fdt_overlay_stacked(struct unit_test_state *uts) { - void *fdt = uts->priv; u32 val = 0; ut_assertok(ut_fdt_getprop_u32(fdt, "/new-local-node", @@ -225,7 +218,7 @@ int do_ut_overlay(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) void *fdt_base = &__dtb_test_fdt_base_begin; void *fdt_overlay = &__dtb_test_fdt_overlay_begin; void *fdt_overlay_stacked = &__dtb_test_fdt_overlay_stacked_begin; - void *fdt_base_copy, *fdt_overlay_copy, *fdt_overlay_stacked_copy; + void *fdt_overlay_copy, *fdt_overlay_stacked_copy; int ret = -ENOMEM; uts = calloc(1, sizeof(*uts)); @@ -235,10 +228,9 @@ int do_ut_overlay(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) ut_assertok(fdt_check_header(fdt_base)); ut_assertok(fdt_check_header(fdt_overlay)); - fdt_base_copy = malloc(FDT_COPY_SIZE); - if (!fdt_base_copy) + fdt = malloc(FDT_COPY_SIZE); + if (!fdt) goto err1; - uts->priv = fdt_base_copy; fdt_overlay_copy = malloc(FDT_COPY_SIZE); if (!fdt_overlay_copy) @@ -254,7 +246,7 @@ int do_ut_overlay(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) * (and relocate it since the memory might be mapped * read-only) */ - ut_assertok(fdt_open_into(fdt_base, fdt_base_copy, FDT_COPY_SIZE)); + ut_assertok(fdt_open_into(fdt_base, fdt, FDT_COPY_SIZE)); /* * Resize the overlay to 4k so that we have room to operate on @@ -275,10 +267,10 @@ int do_ut_overlay(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) FDT_COPY_SIZE)); /* Apply the overlay */ - ut_assertok(fdt_overlay_apply(fdt_base_copy, fdt_overlay_copy)); + ut_assertok(fdt_overlay_apply(fdt, fdt_overlay_copy)); /* Apply the stacked overlay */ - ut_assertok(fdt_overlay_apply(fdt_base_copy, fdt_overlay_stacked_copy)); + ut_assertok(fdt_overlay_apply(fdt, fdt_overlay_stacked_copy)); ret = cmd_ut_category("overlay", tests, n_ents, argc, argv); @@ -286,9 +278,7 @@ int do_ut_overlay(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) err3: free(fdt_overlay_copy); err2: - free(fdt_base_copy); + free(fdt); err1: - free(uts); - return ret; } -- cgit From cdd7486616d03e1642ba1dacea6f05c10fc97863 Mon Sep 17 00:00:00 2001 From: Peng Fan Date: Sun, 9 Dec 2018 12:45:45 +0000 Subject: firmware: psci: introduce SPL_ARM_PSCI_FW Introduce a new macro SPL_ARM_PSCI_FW Signed-off-by: Peng Fan Reviewed-by: Stefano Babic --- drivers/firmware/Kconfig | 4 ++++ drivers/firmware/Makefile | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/firmware/Kconfig b/drivers/firmware/Kconfig index feaea8130f..7d8f161b26 100644 --- a/drivers/firmware/Kconfig +++ b/drivers/firmware/Kconfig @@ -1,6 +1,10 @@ config FIRMWARE bool "Enable Firmware driver support" +config SPL_ARM_PSCI_FW + bool + select FIRMWARE + config ARM_PSCI_FW bool select FIRMWARE diff --git a/drivers/firmware/Makefile b/drivers/firmware/Makefile index 6cb83582b9..6c3e129685 100644 --- a/drivers/firmware/Makefile +++ b/drivers/firmware/Makefile @@ -1,4 +1,4 @@ obj-$(CONFIG_FIRMWARE) += firmware-uclass.o -obj-$(CONFIG_ARM_PSCI_FW) += psci.o +obj-$(CONFIG_$(SPL_)ARM_PSCI_FW) += psci.o obj-$(CONFIG_TI_SCI_PROTOCOL) += ti_sci.o obj-$(CONFIG_SANDBOX) += firmware-sandbox.o -- cgit From dda9af3ad156c5b765d31a0646d01bfbb1977d9a Mon Sep 17 00:00:00 2001 From: Adam Ford Date: Mon, 10 Dec 2018 14:56:36 -0600 Subject: am3517_evm: Use ttyS2 instead of ttyO2 The serial driver in the kernel moved from ttyOx to ttySx a while ago. This patch updates the console parameter to align with the kernel change. Signed-off-by: Adam Ford --- include/configs/am3517_evm.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/configs/am3517_evm.h b/include/configs/am3517_evm.h index 4e7e5209d4..eb50012ff7 100644 --- a/include/configs/am3517_evm.h +++ b/include/configs/am3517_evm.h @@ -88,7 +88,7 @@ #define CONFIG_EXTRA_ENV_SETTINGS \ "loadaddr=0x82000000\0" \ - "console=ttyO2,115200n8\0" \ + "console=ttyS2,115200n8\0" \ "fdtfile=am3517-evm.dtb\0" \ "fdtaddr=0x82C00000\0" \ "vram=16M\0" \ -- cgit