summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Convert CONFIG_PHYLIB et al to KconfigWIP/migrate-various-PHY-optionsTom Rini2020-04-24562-191/+1970
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This converts the following to Kconfig: CONFIG_PHYLIB CONFIG_BITBANGMII CONFIG_MV88E6352_SWITCH CONFIG_MV88E61XX_SWITCH CONFIG_PHYLIB_10G CONFIG_PHY_AQUANTIA CONFIG_PHY_ATHEROS CONFIG_PHY_BROADCOM CONFIG_PHY_CORTINA CONFIG_PHY_DAVICOM CONFIG_PHY_ET1011C CONFIG_PHY_LXT CONFIG_PHY_MARVELL CONFIG_PHY_MICREL CONFIG_PHY_NATSEMI CONFIG_PHY_REALTEK CONFIG_RTL8211X_PHY_FORCE_MASTER CONFIG_PHY_SMSC CONFIG_PHY_TERANETICS CONFIG_PHY_TI CONFIG_PHY_VITESSE CONFIG_PHY_XILINX Signed-off-by: Tom Rini <trini@konsulko.com>
* sunxi: Fix PHY regression on A20-OLinuXino-Lime2 and A20-Olimex-SOM-EVBTom Rini2020-04-242-0/+4
| | | | | | | | | | | | | | | | | When moving the PHYLIB PHY drivers around in Kconfig we did not at the same time perform a careful migration of the related drivers and sub-options. This lead to the case where previously Kconfig-enabled driver choices were now disabled on some platforms. Correct this by enabling both the PHY driver and sub-option on the above referenced platforms. Fixes: af2cbfd6b982 ("drivers: net: Provide Kconfig menu for PHYLIB") Fixes: 8728c97eff5b ("configs: Re-sync") Reported-by: Dario <dario86@tutamail.com> Signed-off-by: Tom Rini <trini@konsulko.com> --- After checking back on the original commit I can see that these are the only two platforms to have been broken in the change.
* configs: Resync with savedefconfigTom Rini2020-04-24538-775/+695
| | | | | | Rsync all defconfig files using moveconfig.py Signed-off-by: Tom Rini <trini@konsulko.com>
* Revert "sunxi: Fix PHY regression on A20-OLinuXino-Lime2 and A20-Olimex-SOM-EVB"Tom Rini2020-04-242-4/+0
| | | | | | | | | While the change is correct, generally, it was not intended to be pushed just yet. This reverts commit b897306341024695d17296efc1f9d83d06368209. Signed-off-by: Tom Rini <trini@konsulko.com>
* Merge branch '2020-04-24-master-imports'Tom Rini2020-04-2453-499/+916
|\ | | | | | | | | | | | | | | - Assorted minor bugfixes. - Resync fixdep with Linux v5.7-rc1 - Numerous changes to reduce SPL in various cases including when we have read-only env support. - Allow mkimage to align the header on FIT images to a specific size.
| * travis: Correct error checking when building boardsWIP/2020-04-24-master-importsSimon Glass2020-04-241-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | At present if buildman reports an error, the travis build still succeeds. This is because the travis script does not stop when it sees errors; nor does it automatically return the exit code. Also the current error checking never triggers since 'ret' is not set. Fix this by setting 'ret' correctly. Signed-off-by: Simon Glass <sjg@chromium.org> Reported-by: Michal Simek <michal.simek@xilinx.com> Acked-by: Michal Simek <michal.simek@xilinx.com>
| * mkimage: fit: Free buf directly in fit_extract_data()Bin Meng2020-04-241-2/+1
| | | | | | | | | | | | | | If given ptr to free() is NULL, no operation is performed. Hence we can just free buf directly in fit_extract_data(). Signed-off-by: Bin Meng <bin.meng@windriver.com>
| * mkimage: fit: Unmmap the memory before closing fd in fit_import_data()Lihua Zhao2020-04-241-10/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | Without calling munmap(), the follow-up call to open() the same file with a flag O_TRUNC seems not to cause any issue on Linux, but it fails on Windows with error like below: Can't open kernel_fdt.itb.tmp: Permission denied Fix this by unmapping the memory before closing fd in fit_import_data(). Signed-off-by: Lihua Zhao <lihua.zhao@windriver.com> Signed-off-by: Bin Meng <bin.meng@windriver.com>
| * tools: Remove the out-of-date MinGW support codesBin Meng2020-04-245-175/+3
| | | | | | | | | | | | | | MinGW build for U-Boot tools has been broken for years. The official support of Windows build is now MSYS2. Remove the MinGW support codes. Signed-off-by: Bin Meng <bin.meng@windriver.com>
| * doc: invalid doc link in rstFlatTable.pyHeinrich Schuchardt2020-04-241-2/+0
| | | | | | | | | | | | | | Remove an invalid documentation link in rstFlatTable.py. This synchronizes the file with Linux next-20200413. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
| * spl: Kconfig: de-dup SPL_DM_GPIO definitionJoel Johnson2020-04-241-6/+0
| | | | | | | | | | | | | | | | | | Two nearly concurrent commits (d4d65e112 and bcee8d676) added a SPL_DM_GPIO symbol. Resolve the duplication in favor of the version in drivers/gpio/Kconfig. Signed-off-by: Joel Johnson <mrjoel@lixil.net> Reviewed-by: Frieder Schrempf <frieder.schrempf@kontron.de>
| * fixdep: Re-sync with Linux 5.7-rc1Masahiro Yamada2020-04-241-45/+47
| | | | | | | | | | | | | | | | | | | | fixdep is a standalone host program, so we can just re-sync it with the latest Linux in one commit. I kept the U-Boot own code block surrounded by /* hack for U-Boot */ ... /* U-boot hack end */. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
| * fixdep: handle CONFIG_IS_ENABLE() and friends for TPLMasahiro Yamada2020-04-241-5/+7
| | | | | | | | | | | | | | | | | | | | | | | | Since commit f1c6e1922eb5 ("spl: dm: use CONFIG_IS_ENABLED to test for the DM option"), CONFIG_IS_ENABLED() handles CONFIG_TPL_* options, but fixdep still cannot because it hard-codes the "SPL_" prefix as follows: char tmp_buf[256] = "SPL_"; /* hack for U-Boot */ Take care of the "TPL_" prefix too. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
| * .mailmap: map Ruchika Gupta's mail addressHeinrich Schuchardt2020-04-241-0/+1
| | | | | | | | | | | | | | Freescale mail addresses are not valid anymore. Reported-by: Fabio Estevam <festevam@gmail.com> Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
| * dlmalloc: remove unit test support in SPLHeinrich Schuchardt2020-04-241-1/+1
| | | | | | | | | | | | We cannot run unit tests in SPL. So remove the unit test support. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
| * lib: do not provide hexdump in SPLHeinrich Schuchardt2020-04-241-1/+1
| | | | | | | | | | | | | | SPL should not be enlarged by building with CONFIG_HEXDUMP=y. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Reviewed-by: Tom Rini <trini@konsulko.com>
| * common: image_sign_info helper functions in SPLHeinrich Schuchardt2020-04-243-2/+13
| | | | | | | | | | | | | | | | Do not build image_sign_info helper functions in SPL if not needed. Fixes: b983cc2da0ba ("lib: rsa: decouple rsa from FIT image verification") Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Reviewed-by: Tom Rini <trini@konsulko.com>
| * lib: do not build OID registry in SPLHeinrich Schuchardt2020-04-241-2/+1
| | | | | | | | | | | | | | | | | | The OID registry is only used by crypto functions that are not built in SPL. So we should not build it in SPL. Fixes: a9b45e6e8382 ("lib: add oid registry utility") Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Reviewed-by: Tom Rini <trini@konsulko.com>
| * tools: image-host.c: use correct output formatHeinrich Schuchardt2020-04-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When building on a 32bit host the following warning occurs: tools/image-host.c: In function ‘fit_image_read_data’: tools/image-host.c:310:42: warning: format ‘%ld’ expects argument of type ‘long int’, but argument 3 has type ‘ssize_t’ {aka ‘int’} [-Wformat=] printf("Can't read all file %s (read %ld bytes, expexted %ld)\n", ~~^ %d filename, n, sbuf.st_size); ~ n is of type ssize_t so we should use %zd for printing. Fixes: 7298e422504e ("mkimage: fit: add support to encrypt image with aes") Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Reviewed-by: Simon Glass <sjg@chromium.org>
| * Makefile: ARMv7-M has no CPSR registerHeinrich Schuchardt2020-04-241-7/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Compiling on ARMv7-M fails when trying to address the CPSR register which is not available on this architecture. Atomic functions refer to the CPSR register if compiled with arch/arm/include/asm/proc-armv/system.h. On ARMv7-M we should hence use arch/arm/thumb1/include/asm/proc-armv/system.h instead. Cf. https://stackoverflow.com/questions/61097841/error-selected-processor-does-not-support-requested-special-purpose-register Reported-by: Sicris Rey Embay <sicris.embay@gmail.com> Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
| * qemu: don't allow to select 32- and 64-bitHeinrich Schuchardt2020-04-241-5/+9
| | | | | | | | | | | | | | TARGET_QEMU_ARM_64BIT and TARGET_QEMU_ARM_32BIT should be mutually exclusive. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
| * fvp: Add support for loading Android boot images via semihostingPeter Collingbourne2020-04-242-10/+22
| | | | | | | | | | | | | | | | | | FVP now loads an Android boot image named boot.img if available, otherwise it falls back to the existing code path. Signed-off-by: Peter Collingbourne <pcc@google.com> Reviewed-by: Ryan Harkin <ryan.harkin@linaro.org> Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
| * mkimage: fit_image: Add option to make fit header alignKever Yang2020-04-244-15/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The image is usually stored in block device like emmc, SD card, make the offset of image data aligned to block(512 byte) can avoid data copy during boot process. eg. SPL boot from FIT image with external data: - SPL read the first block of FIT image, and then parse the header; - SPL read image data separately; - The first image offset is the base_offset which is the header size; - The second image offset is just after the first image; - If the offset of imge does not aligned, SPL will do memcpy; The header size is a ramdon number, which is very possible not aligned, so add '-B size'to specify the align size in hex for better performance. example usage: ./tools/mkimage -E -f u-boot.its -B 0x200 u-boot.itb Signed-off-by: Kever Yang <kever.yang@rock-chips.com> Reviewed-by: Punit Agrawal <punit1.agrawal@toshiba.co.jp> Reviewed-by: Tom Rini <trini@konsulko.com>
| * libfdt: Make fdtdec_get_child_count() available for HOSTKever Yang2020-04-243-11/+20
| | | | | | | | | | | | | | | | | | The tool need to use fdtdec_get_child_count(), make it available for HOST_CC. Signed-off-by: Kever Yang <kever.yang@rock-chips.com> Reviewed-by: Punit Agrawal <punit1.agrawal@toshiba.co.jp> Reviewed-by: Simon Glass <sjg@chromium.org>
| * tool: use ALIGN() to align the sizeKever Yang2020-04-242-2/+2
| | | | | | | | | | | | | | | | | | Use the ALIGN() for size align so that the code is more readable. Signed-off-by: Kever Yang <kever.yang@rock-chips.com> Reviewed-by: Punit Agrawal <punit1.agrawal@toshiba.co.jp> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
| * tools: imx8mimage: remove redundant codeKever Yang2020-04-241-1/+0
| | | | | | | | | | | | | | | | | | The align for fit_size has been done twice, remove the first one for it does not make any sense. Signed-off-by: Kever Yang <kever.yang@rock-chips.com> Reviewed-by: Punit Agrawal <punit1.agrawal@toshiba.co.jp> Reviewed-by: Tom Rini <trini@konsulko.com>
| * tools: kwbimage: use common ALIGN to do the size alignKever Yang2020-04-242-6/+4
| | | | | | | | | | | | | | | | | | The ALIGN() is now available at imagetool.h, migrate to use it. Signed-off-by: Kever Yang <kever.yang@rock-chips.com> Reviewed-by: Punit Agrawal <punit1.agrawal@toshiba.co.jp> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Stefan Roese <sr@denx.de>
| * tools: mkimage: use common ALIGN to do the size alignKever Yang2020-04-241-2/+3
| | | | | | | | | | | | | | | | The ALIGN() is now available at imagetool.h, migrate to use it. Signed-off-by: Kever Yang <kever.yang@rock-chips.com> Reviewed-by: Punit Agrawal <punit1.agrawal@toshiba.co.jp> Reviewed-by: Tom Rini <trini@konsulko.com>
| * tool: aisimage: use ALIGN instead of self defiend macroKever Yang2020-04-241-4/+4
| | | | | | | | | | | | | | | | The ALIGN() is available at imagetool.h, no need to self define one. Signed-off-by: Kever Yang <kever.yang@rock-chips.com> Reviewed-by: Punit Agrawal <punit1.agrawal@toshiba.co.jp> Reviewed-by: Tom Rini <trini@konsulko.com>
| * tool: Move ALIGN_MASK to header as common MACROKever Yang2020-04-245-9/+5
| | | | | | | | | | | | | | | | | | The ALIGN code is need by many files who need handle structure or image align, so move the macro to imagetool.h file. Signed-off-by: Kever Yang <kever.yang@rock-chips.com> Reviewed-by: Punit Agrawal <punit1.agrawal@toshiba.co.jp> Reviewed-by: Tom Rini <trini@konsulko.com>
| * docs: Fix conf.py for Sphinx 2.0Jonathan Corbet2020-04-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | commit 3bc8088464712fdcb078eefb68837ccfcc413c88 upstream. Our version check in Documentation/conf.py never envisioned a world where Sphinx moved beyond 1.x. Now that the unthinkable has happened, fix our version check to handle higher version numbers correctly. Signed-off-by: Jonathan Corbet <corbet@lwn.net> [rebase for u-boot] Signed-off-by: Sean Anderson <seanga2@gmail.com>
| * env/sf.c: drop private CMD_SAVEENV logicRasmus Villemoes2020-04-241-11/+1
| | | | | | | | | | | | | | | | | | | | | | Deciding whether to compile the env_sf_save() function based solely on CONFIG_SPL_BUILD is wrong: For U-Boot proper, it leads to a build warning in case CONFIG_CMD_SAVEENV=n (because the env_save_ptr() macro causes the function to indeed not be referenced anywhere). And for SPL, when one selects CONFIG_SPL_SAVEENV, one obviously expects to actually be able to save the environment. Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
| * env/ext4.c: remove CONFIG_CMD_SAVEENV ifdefRasmus Villemoes2020-04-241-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Removing this ifdef/endif pair yields a "defined but unused warning" for CONFIG_CMD_SAVEENV=n, but that vanishes if we use the ENV_SAVE_PTR macro instead. This gives slightly better compile testing, and moreover, it's possible to have CONFIG_CMD_SAVEENV=n CONFIG_SPL_SAVEENV=y SPL_ENV_IS_IN_EXT4=y in which case env_ext4_save would erroneously not be compiled in. Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
| * env/fat.c: remove private CMD_SAVEENV logicRasmus Villemoes2020-04-241-8/+1
| | | | | | | | | | | | | | | | Always compile the env_fat_save() function, and let CONFIG_IS_ENABLED(SAVEENV) (via the ENV_SAVE_PTR macro) decide whether it actually ends up being compiled in. Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
| * env_internal.h: add alternative ENV_SAVE_PTR macroRasmus Villemoes2020-04-241-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The current definition of the env_save_ptr does not take SPL_SAVEENV into account. Moreover, the way it is implemented means that drivers need to guard the definitions of their _save methods with ifdefs to avoid "defined but unused" warnings in case CMD_SAVEENV=n. The ifdeffery can be avoided by using a "something ? x : NULL" construction instead and still have the compiler elide the _save method when it is not referenced. Unfortunately we can't just switch the existing env_save_ptr macro, since that would give a lot of build errors unless all the ifdeffery is removed at the same time. Conversely, removing that ifdeffery first would merely lead to the "defined but unused" warnings temporarily, but for some storage drivers it requires a bit more work than just removing their private CMD_SAVEENV logic. So introduce an alternative to env_save_ptr, which for lack of a better name is simply uppercased, allowing one to update storage drivers piecemeal to both reduce their ifdeffery and honour CONFIG_SPL_SAVEENV. Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
| * env: add SAVEENV as an alias of the CMD_SAVEENV symbolRasmus Villemoes2020-04-241-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, testing whether to compile in support for saving the environment is a bit awkward when one needs to take SPL_SAVEENV into account, and quite a few storage drivers currently do not honour SPL_SAVEENV. To make it a bit easier to decide whether environment saving should be enabled, introduce SAVEENV as an alias for the CMD_SAVEENV symbol. Then one can simply use CONFIG_IS_ENABLED(SAVEENV) Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
| * bootcount_ext: Add flag to enable/disable bootcountFrédéric Danis2020-04-242-12/+85
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | After a successful upgrade, multiple problem during boot sequence may trigger the altbootcmd process. This patch adds a version and an upgrade_available entries to the bootcount file to enable/disable the bootcount check. When failing to read the bootcount file it will consider that bootcount is enabled, acting as previously, and update the file accordingly. The bootcount file is only saved when `upgrade_available` is true, this allows to save writes to the filesystem. Signed-off-by: Frédéric Danis <frederic.danis@collabora.com> Reviewed-by: Simon Glass <sjg@chromium.org>
| * make env_entry::callback conditional on !CONFIG_SPL_BUILDRasmus Villemoes2020-04-244-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The callback member of struct env_entry is always NULL for an SPL build. Removing it thus saves a bit of run-time memory in the SPL (when CONFIG_SPL_ENV_SUPPORT=y) since struct env_entry is embedded in struct env_entry_node - i.e. about 2KB for the normal case of 512+change hash table entries. Two small fixups are needed for this, all other references to the callback member are already under !CONFIG_SPL_BUILD: Don't initialize .callback in set_flags() - hsearch_r doesn't use that value anyway. And make env_callback_init() initialize ->callback to NULL for a new entry instead of relying on an unused or deleted entry having NULL in ->callback. Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk> Reviewed-by: Simon Glass <sjg@chromium.org>
| * lib/hashtable.c: don't test ->callback in SPLRasmus Villemoes2020-04-241-0/+2
| | | | | | | | | | | | | | | | | | In SPL, environment callbacks are not supported, so e->callback is always NULL. Removing this makes the SPL a little smaller (about 400 bytes in my ppc build) with no functional change. Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk> Reviewed-by: Simon Glass <sjg@chromium.org>
| * lib/hashtable.c: create helper for calling env_entry::callbackRasmus Villemoes2020-04-241-8/+15
| | | | | | | | | | | | | | | | This is preparation for compiling out the "call the callback" code and associated error handling for SPL, where ->callback is always NULL. Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk> Reviewed-by: Simon Glass <sjg@chromium.org>
| * env: remove callback.o for an SPL buildRasmus Villemoes2020-04-242-1/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | env.h says this about about callback declarations (U_BOOT_ENV_CALLBACK): * For SPL these are silently dropped to reduce code size, since environment * callbacks are not supported with SPL. So env_callback_init() does a lot of work to not find anything in the guaranteed empty env_clbk list. Drop callback.o entirely from the link and stub out the only public function defined in callback.o. This cuts about 600 bytes from the SPL on my ppc build. Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk> Reviewed-by: Simon Glass <sjg@chromium.org>
| * eth: mtk-eth: add mt7531 switch support in mediatek eth driverLanden Chao2020-04-242-127/+577
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | mt7531 is a 7-ports switch with 5 embedded giga phys, and uses the same MAC design of mt7530. The cpu port6 supports SGMII only. The cpu port5 supports RGMII or SGMII in different model. mt7531 is connected to mt7622 via both RGMII and SGMII interfaces. In this patch, mt7531 cpu port5 or port6 is configured to maximum capability to align CPU MAC setting. The dts has been committed in the commit 6efa450565cdc ("arm: dts: mediatek: add ethernet and sgmii dts node for mt7622") Signed-off-by: Landen Chao <landen.chao@mediatek.com> Tested-by: Frank Wunderlich <frank-w@public-files.de>
| * watchdog: mpc8xx_wdt: Allow selection of watchdog mode through environmentCharles Frey2020-04-241-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The mpc8xx watchdog can work either in 'reset mode' or 'NMI mode'. The selection can be done at startup only. It is desirable to select the mode without rebuilding U-boot. It is also desirable to disable the watchdog without rebuilding. At watchdog startup, check environment variable 'watchdog_mode'. If it is 'off', the watchdog is not started. If it is 'nmi', the watchdog is started in NMI mode. Otherwise, it is started in reset mode which is the default mode. Signed-off-by: Charles Frey <charles.frey@c-s.fr> Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
* | sunxi: Fix PHY regression on A20-OLinuXino-Lime2 and A20-Olimex-SOM-EVBTom Rini2020-04-242-0/+4
|/ | | | | | | | | | | | | | | | | When moving the PHYLIB PHY drivers around in Kconfig we did not at the same time perform a careful migration of the related drivers and sub-options. This lead to the case where previously Kconfig-enabled driver choices were now disabled on some platforms. Correct this by enabling both the PHY driver and sub-option on the above referenced platforms. Fixes: af2cbfd6b982 ("drivers: net: Provide Kconfig menu for PHYLIB") Fixes: 8728c97eff5b ("configs: Re-sync") Reported-by: Dario <dario86@tutamail.com> Signed-off-by: Tom Rini <trini@konsulko.com> --- After checking back on the original commit I can see that these are the only two platforms to have been broken in the change.
* dm: pinctrl: Use right device pointer for configuring pinctrlWIP/23Apr2020Lokesh Vutla2020-04-231-2/+2
| | | | | | | | | | | | | commit 719cab6d2e2bf ("dm: pinctrl: convert pinctrl-single to livetree") converted pinctrl driver to livetree. In this conversion, the call to read pinctrl-single,pins/bits property is provided with pinctrl device pointer instead of pinctrl config pointer. Because of this none of the pins gets configured. Fix it by passing the right udevice pointer. Fixes: 719cab6d2e2bf ("dm: pinctrl: convert pinctrl-single to livetree") Reported-by: Tom Rini <trini@konsulko.com> Reviewed-by: Patrick Delaunay <patrick.delaunay@st.com> Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
* Merge https://gitlab.denx.de/u-boot/custodians/u-boot-riscvTom Rini2020-04-2317-86/+211
|\ | | | | | | | | | | | | | | | | - Adds few DT related fixes required for Linux EFI stub to work on RISC-V. - Makes SBI v0.2 the default SBI version to work with OpenSBI v0.7. - Revert "riscv: qemu: clear kernel-start/-end in device tree as workaround for BBL" - Remove unnecessary CONFIG_IS_ENABLED().
| * riscv: Move all fdt fixups togetherAtish Patra2020-04-232-33/+33
| | | | | | | | | | | | | | Keep all the fdt fixups together for better code management. Signed-off-by: Atish Patra <atish.patra@wdc.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
| * riscv: Copy the reserved-memory nodes to final DTAtish Patra2020-04-231-1/+7
| | | | | | | | | | | | | | | | | | | | | | The DT used by U-Boot may be different from the DT being passed to the OS if the DT is loaded from external media such as network or mmc. In that case, the reserved-memory node needs to be copied to the DT passed to the OS. Signed-off-by: Atish Patra <atish.patra@wdc.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Tested-by: Bin Meng <bmeng.cn@gmail.com>
| * riscv: Setup reserved-memory node for FU540Atish Patra2020-04-232-0/+16
| | | | | | | | | | | | | | | | | | | | FU540 uses OF_SEPARATE instead of OF_PRIOR_STAGE. Enable OF_BOARD_FIXUP to update the DT with reserved-memory node. Signed-off-by: Atish Patra <atish.patra@wdc.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Tested-by: Bin Meng <bmeng.cn@gmail.com>
| * riscv: Provide a mechanism to fix DT for reserved memoryAtish Patra2020-04-236-0/+108
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In RISC-V, M-mode software can reserve physical memory regions by setting appropriate physical memory protection (PMP) csr. As the PMP csr are accessible only in M-mode, S-mode U-Boot can not read this configuration directly. However, M-mode software can pass this information via reserved-memory node in device tree so that S-mode software can access this information. This patch provides a framework to copy to the reserved-memory node from one DT to another. This will be used to update the DT used by U-Boot and the DT passed to the next stage OS. Signed-off-by: Atish Patra <atish.patra@wdc.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Tested-by: Bin Meng <bmeng.cn@gmail.com>