pinctrl: Remove DM_FLAG_PRE_RELOC flag in various driversWhen a driver declares DM_FLAG_PRE_RELOC flag, it wishes to bebound before relocation. However due to a bug in the DM core,the flag only t
pinctrl: Remove DM_FLAG_PRE_RELOC flag in various driversWhen a driver declares DM_FLAG_PRE_RELOC flag, it wishes to bebound before relocation. However due to a bug in the DM core,the flag only takes effect when devices are statically declaredvia U_BOOT_DEVICE(). This bug has been fixed recently by commit"dm: core: Respect drivers with the DM_FLAG_PRE_RELOC flag inlists_bind_fdt()", but with the fix, it has a side effect thatall existing drivers that declared DM_FLAG_PRE_RELOC flag willbe bound before relocation now. This may expose potential bootfailure on some boards due to insufficient memory during thepre-relocation stage.To mitigate this potential impact, the following changes areimplemented:- Remove DM_FLAG_PRE_RELOC flag in the driver, if the driver only supports configuration from device tree (OF_CONTROL)- Keep DM_FLAG_PRE_RELOC flag in the driver only if the device is statically declared via U_BOOT_DEVICE()- Surround DM_FLAG_PRE_RELOC flag with OF_CONTROL check, for drivers that support both statically declared devices and configuration from device treeSigned-off-by: Bin Meng <bmeng.cn@gmail.com>Reviewed-by: Simon Glass <sjg@chromium.org>
show more ...
SPDX: Convert all of our single license tags to Linux Kernel styleWhen U-Boot started using SPDX tags we were among the early adopters andthere weren't a lot of other examples to borrow from. So
SPDX: Convert all of our single license tags to Linux Kernel styleWhen U-Boot started using SPDX tags we were among the early adopters andthere weren't a lot of other examples to borrow from. So we picked thearea of the file that usually had a full license text and replaced itwith an appropriate SPDX-License-Identifier: entry. Since then, theLinux Kernel has adopted SPDX tags and they place it as the very firstline in a file (except where shebangs are used, then it's second line)and with slightly different comment styles than us.In part due to community overlap, in part due to better tag visibilityand in part for other minor reasons, switch over to that style.This commit changes all instances where we have a single declaredlicense in the tag as both the before and after are identical in tagcontents. There's also a few places where I found we did not have a tagand have introduced one.Signed-off-by: Tom Rini <trini@konsulko.com>
Remove unnecessary instances of DECLARE_GLOBAL_DATA_PTRWe have a large number of places where while we historically referencedgd in the code we no longer do, as well as cases where the code added
Remove unnecessary instances of DECLARE_GLOBAL_DATA_PTRWe have a large number of places where while we historically referencedgd in the code we no longer do, as well as cases where the code addedthat line "just in case" during development and never dropped it.Signed-off-by: Tom Rini <trini@konsulko.com>
dm: Rename dev_addr..() functionsThese support the flat device tree. We want to use the dev_read_..()prefix for functions that support both flat tree and live tree. So renamethe existing function
dm: Rename dev_addr..() functionsThese support the flat device tree. We want to use the dev_read_..()prefix for functions that support both flat tree and live tree. So renamethe existing functions to avoid confusion.In the end we will have: 1. dev_read_addr...() - works on devices, supports flat/live tree 2. devfdt_get_addr...() - current functions, flat tree only 3. of_get_address() etc. - new functions, live tree onlyAll drivers will be written to use 1. That function will in turn calleither 2 or 3 depending on whether the flat or live tree is in use.Note this involves changing some dead code - the imx_lpi2c.c file.Signed-off-by: Simon Glass <sjg@chromium.org>
dm: core: Replace of_offset with accessorAt present devices use a simple integer offset to record the device treenode associated with the device. In preparation for supporting a livedevice tree,
dm: core: Replace of_offset with accessorAt present devices use a simple integer offset to record the device treenode associated with the device. In preparation for supporting a livedevice tree, which uses a node pointer instead, refactor existing code toaccess this field through an inline function.Signed-off-by: Simon Glass <sjg@chromium.org>
Fix codying style broken by recent libfdt syncCommit b02e4044ff8e ("libfdt: Bring in upstream stringlistfunctions") broke codying style in some places especiallyby inserting an extra whitespace b
Fix codying style broken by recent libfdt syncCommit b02e4044ff8e ("libfdt: Bring in upstream stringlistfunctions") broke codying style in some places especiallyby inserting an extra whitespace before fdt_stringlist_count().Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>Acked-by: Simon Glass <sjg@chromium.org>
libfdt: Bring in upstream stringlist functionsThese have now landed upstream. The naming is different and in one case thefunction signature has changed. Update the code to match.This applies the
libfdt: Bring in upstream stringlist functionsThese have now landed upstream. The naming is different and in one case thefunction signature has changed. Update the code to match.This applies the following upstream commits byThierry Reding <treding@nvidia.com> : 604e61e fdt: Add functions to retrieve strings 8702bd1 fdt: Add a function to get the index of a string 2218387 fdt: Add a function to count stringsSigned-off-by: Simon Glass <sjg@chromium.org>
pinctrl: Add pinctrl driver support for Exynos7420 SoCAdd pinctrl driver support for Samsung's Exynos7420 SoC. The changeshave been split into Exynos7420 specific and common Exynos specificportio
pinctrl: Add pinctrl driver support for Exynos7420 SoCAdd pinctrl driver support for Samsung's Exynos7420 SoC. The changeshave been split into Exynos7420 specific and common Exynos specificportions so that this implementation is reusable on other ExynosSoCs as well.The Exynos pinctrl driver supports only device tree based pinconfiguration. The bindings used are similar to the ones used in thelinux kernel.Cc: Masahiro Yamada <yamada.masahiro@socionext.com>Cc: Simon Glass <sjg@chromium.org>Cc: Minkyu Kang <mk7.kang@samsung.com>Signed-off-by: Thomas Abraham <thomas.ab@samsung.com>Reviewed-by: Simon Glass <sjg@chromium.org>Acked-by: Minkyu Kang <mk7.kang@samsung.com>Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>