aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2020-10-29dm: Avoid using #ifdef for CONFIG_OF_LIVESimon Glass
At present this option results in a number of #ifdefs due to the presence or absence of the global_data of_root member. Add a few macros to global_data.h to work around this. Update the code accordingly. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-10-29dm: core: Avoid void * in the of-platdata structsSimon Glass
These pointers point to drivers. Update the definition to make this clear. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-10-29dm: core: Expand the comment for DM_GET_DEVICE()Simon Glass
The current documentation for this is not particularly enlightening. Add a little more detail. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-10-29dtoc: Use a namedtuple for _linksSimon Glass
The use of strings to access a dict is a bit ugly. Use a namedtuple for this instead. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-10-29dtoc: Extract inner loop from output_node()Simon Glass
This function is very long. Put the inner loop in a separate function to enhance readability. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-10-29binman: Support multiple images in the librarySimon Glass
Add support for multiple images, since these are used on x86 now. Select the first image for now, since that is generally the correct one. At some point we can add a way to determine which image is currently running. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-10-29binman: Add a way to read the ROM offsetSimon Glass
Provide a function to read the ROM offset so that we can store the value in one place and clients don't need to store it themselves after calling binman_set_rom_offset(). Signed-off-by: Simon Glass <sjg@chromium.org>
2020-10-29configs: Resync with savedefconfigTom Rini
Rsync all defconfig files using moveconfig.py Signed-off-by: Tom Rini <trini@konsulko.com>
2020-10-29MAINTAINERS, git-mailrc: Update sunxi maintainersAndre Przywara
Maxime mentioned that he feels not having the time to be an Allwinner maintainer anymore. Take over from him. Maxime, many thanks for your great work in the past! I hope I can still relay the occasional technical question to you in the future. Acked-by: Maxime Ripard <mripard@kernel.org> Signed-off-by: Andre Przywara <andre.przywara@arm.com>
2020-10-29Merge https://gitlab.denx.de/u-boot/custodians/u-boot-fsl-qoriqTom Rini
- Bug fixes and updates on vid, ls1088a lx2160a and other layerscape platforms. - Add optee_rpmb support for LX2 & Kontron sl28 support
2020-10-28Prepare v2021.01-rc1Tom Rini
Signed-off-by: Tom Rini <trini@konsulko.com>
2020-10-28Merge branch '2020-10-28-mux-driver-framework'Tom Rini
- Add a framework for mux drivers
2020-10-28test: mux-cmd: Add tests for the 'mux' commandPratyush Yadav
Tests tests run the three mux subcommands: list, select, and deselect, and verify that the commands do what we expect. Signed-off-by: Pratyush Yadav <p.yadav@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2020-10-28cmd: Add a mux commandPratyush Yadav
This command lets the user list, select, and deselect mux controllers introduced with the mux framework on the fly. It has 3 subcommands: list, select, and deselect. List: Lists all the mux present on the system. The muxes are listed for each chip. The chip is identified by its device name. Each chip can have a number of mux controllers. Each is listed in sequence and is assigned a sequential ID based on its position in the mux chip. It lists details like ID, whether the mux is currently selected or not, the current state, the idle state, and the number of states. A sample output would look something like: => mux list a-mux-controller: ID Selected Current State Idle State Num States 0 no unknown as-is 0x4 1 no 0x2 0x2 0x10 2 no 0x73 0x73 0x100 another-mux-controller: ID Selected Current State Idle State Num States 0 no 0x1 0x1 0x4 1 no 0x2 0x2 0x4 Select: Selects a given mux and puts it in the specified state. This subcommand takes 3 arguments: mux chip, mux ID, state to set the mux in. The arguments mux chip and mux ID are used to identify which mux needs to be selected, and then it is selected to the given state. The mux needs to be deselected before it can be selected again in another state. The state should be a hexadecimal number. For example: => mux list a-mux-controller: ID Selected Current State Idle State Num States 0 no 0x1 0x1 0x4 1 no 0x1 0x1 0x4 => mux select a-mux-controller 0 0x3 => mux list a-mux-controller: ID Selected Current State Idle State Num States 0 yes 0x3 0x1 0x4 1 no 0x1 0x1 0x4 Deselect: Deselects a given mux and puts it in its idle state. This subcommand takes 2 arguments: the mux chip and mux ID to identify which mux needs to be deselected. So in the above example, we can deselect mux 0 using: => mux deselect a-mux-controller 0 => mux list a-mux-controller: ID Selected Current State Idle State Num States 0 no 0x1 0x1 0x4 1 no 0x1 0x1 0x4 Signed-off-by: Pratyush Yadav <p.yadav@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2020-10-28test: Add tests for the multiplexer frameworkJean-Jacques Hiblot
Provide tests to check the behavior of the multiplexer framework. Two sets of tests are added. One is using an emulated multiplexer driver that can be used to test basic functionality like select, deselect, etc. The other is using the mmio mux which adds tests specific to it. Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com> Signed-off-by: Pratyush Yadav <p.yadav@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2020-10-28Kconfig: Increase the pre-relocation memoryPratyush Yadav
The memory is close to full and adding a syscon node in test.dts makes it go over the limit and makes malloc() fail on startup. Signed-off-by: Pratyush Yadav <p.yadav@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2020-10-28drivers: mux: mmio-based syscon mux controllerJean-Jacques Hiblot
This adds a driver for mmio-based syscon multiplexers controlled by bitfields in a syscon register range. This is heavily based on the linux mmio-mux driver. Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Pratyush Yadav <p.yadav@ti.com>
2020-10-28dm: board: complete the initialization of the muxes in initr_dm()Jean-Jacques Hiblot
This will probe the multiplexer devices that have a "u-boot,mux-autoprobe" property. As a consequence they will be put in their idle state. Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Pratyush Yadav <p.yadav@ti.com>
2020-10-28drivers: Add a new framework for multiplexer devicesJean-Jacques Hiblot
Add a new subsystem that handles multiplexer controllers. The API is the same as in Linux. Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Pratyush Yadav <p.yadav@ti.com> [trini: Update some error calls to use different functions or pass correct arguments] Signed-off-by: Tom Rini <trini@konsulko.com>
2020-10-28Merge tag 'efi-2021-01-rc2' of ↵Tom Rini
https://gitlab.denx.de/u-boot/custodians/u-boot-efi Pull request for UEFI sub-system for efi-2021-01-rc2 A software RTC driver is supplied for UEFI SCT testing. The following UEFI related bugs are fixed: * correct handling of daylight saving time in GetTime() and SetTime() * handling of the gd register in function tracing on RISC-V * disable U-Boot devices in ExitBootServices()
2020-10-28Merge branch '2020-10-27-further-log-enhancements'Tom Rini
- Allow for log message continuation. - Test fix, build time error checking for new categories
2020-10-27log: correct and check array size of log categoriesHeinrich Schuchardt
The log command has led to NULL dereferences if an unknown category name name was used due to missing entries in the list of category names. Add compile time checks for the array sizes of log_cat_name and log_lvl_name to avoid future mishaps. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Reviewed-by: Simon Glass <sjg@chromium.org>
2020-10-27efi_loader: daylight saving timeHeinrich Schuchardt
Adjust the SetTime() and GetTime() runtime services to correctly convert the daylight saving time information when communicating with the RTC. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2020-10-27efi_loader: Disable devices before handing over controlIlias Apalodimas
U-Boot Driver Model is supposed to remove devices with either DM_REMOVE_ACTIVE_DMA or DM_REMOVE_OS_PREPARE flags set, before exiting. Our bootm command does that by explicitly calling calling "dm_remove_devices_flags(DM_REMOVE_ACTIVE_ALL);" and we also disable any USB devices. The EFI equivalent is doing none of those at the moment. As a result probing an fTPM driver now renders it unusable in Linux. During our (*probe) callback we open a session with OP-TEE, which is supposed to close with our (*remove) callback. Since the (*remove) is never called, once we boot into Linux and try to probe the device again we are getting a busy error response. Moreover all uclass (*preremove) functions won't run. So let's fix this by mimicking what bootm does and disconnect devices when efi_exit_boot_services() is called. Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org> Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2020-10-27efi_loader: Sort header file orderingIlias Apalodimas
Order header files according to https://www.denx.de/wiki/U-Boot/CodingStyle Suggested-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org> Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2020-10-27trace: conserve gd register on RISC-VHeinrich Schuchardt
An UEFI application may change the value of the register that gd lives in. But some of our functions like get_ticks() access this register. So we have to set the gd register to the U-Boot value when entering a trace point and set it back to the application value when exiting the trace point. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2020-10-27rtc: provide an emulated RTCHeinrich Schuchardt
On a board without hardware clock this software real time clock can be used. The build time is used to initialize the RTC. So you will have to adjust the time either manually using the 'date' command or use the 'sntp' to update the RTC with the time from a network time server. See CONFIG_CMD_SNTP and CONFIG_BOOTP_NTPSERVER. The RTC time is advanced according to CPU ticks. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2020-10-27Makefile: provide constant with seconds since epochHeinrich Schuchardt
Provide a constant U_BOOT_EPOCH with the number of seconds since 1970-01-01. This constant can be used to initialize a software real time clock until it is updated via the 'sntp' command. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2020-10-27test: log: test message continuationHeinrich Schuchardt
Provide a unit test checking that a continuation message will use the same log level and log category as the previous message. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Reviewed-by: Simon Glass <sjg@chromium.org>
2020-10-27log: allow for message continuationHeinrich Schuchardt
Some drivers use macro pr_cont() for continuing a message sent via printk. Hence if we want to convert printk messaging to using the logging system, we must support continuation of log messages too. As pr_cont() does not provide a message level we need a means of remembering the last log level. With the patch a pseudo log level LOGL_CONT as well as a pseudo log category LOGC_CONT are introduced. Using these results in the application of the same log level and category as in the previous log message. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Reviewed-by: Simon Glass <sjg@chromium.org>
2020-10-27log: move processing_msg to global dataHeinrich Schuchardt
Replace the static variable processing_msg by a field in the global data. Make the field bool at it can only be true or false. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Reviewed-by: Simon Glass <sjg@chromium.org>
2020-10-27nokia_rx51: re-enable CONSOLE_MUX and SYS_CONSOLE_IS_IN_ENVAnatolij Gustschin
With disabled legacy VIDEO option CONSOLE_MUX is not auto-selected any more, re-enable it. Fixes: 9dec5a0ea130 ("nokia_rx51: disable obsolete VIDEO config") Signed-off-by: Anatolij Gustschin <agust@denx.de> Reviewed-by: Pali Rohár <pali@kernel.org>
2020-10-26Merge tag 'video-for-2021.01-rc1' of ↵Tom Rini
https://gitlab.denx.de/u-boot/custodians/u-boot-video - disable CONFIG_VIDEO to remove DM conversion warnings for boards: at91sam9, eb_cpu5282, ls1021aqds, ls1021atwr, mx23evk, mx6sxsabresd, mx7dsabresd, nokia_rx51, picosam9g45, sansa_fuze_plus, xfi3
2020-10-26nokia_rx51: disable obsolete VIDEO configAnatolij Gustschin
Disable VIDEO config to fix DM_VIDEO conversion deadline warning. Signed-off-by: Anatolij Gustschin <agust@denx.de>
2020-10-26eb_cpu5282: fix CONFIG_DM_VIDEO build warningsAnatolij Gustschin
Remove CONFIG_VIDEO dependency to fix board removal warnings. Signed-off-by: Anatolij Gustschin <agust@denx.de> Cc: Jens Scharsig <esw@bus-elektronik.de>
2020-10-26sansa_fuze_plus: disable obsolete VIDEO configAnatolij Gustschin
DM_VIDEO conversion deadline has passed, disable VIDEO config. Signed-off-by: Anatolij Gustschin <agust@denx.de> Cc: Marek Vasut <marek.vasut@gmail.com>
2020-10-26xfi3: disable obsolete VIDEO configAnatolij Gustschin
DM_VIDEO conversion deadline has passed, disable VIDEO config. Signed-off-by: Anatolij Gustschin <agust@denx.de> Cc: Marek Vasut <marek.vasut@gmail.com>
2020-10-26mx23evk: disable obsolete VIDEO configAnatolij Gustschin
DM_VIDEO conversion deadline has passed, disable VIDEO config. Signed-off-by: Anatolij Gustschin <agust@denx.de> Cc: Otavio Salvador <otavio@ossystems.com.br>
2020-10-26at91sam9n12ek: disable obsolete VIDEO configAnatolij Gustschin
DM_VIDEO conversion deadline has passed, disable VIDEO config. Boards should convert to DM_VIDEO if they need video console support. Signed-off-by: Anatolij Gustschin <agust@denx.de> Cc: Eugen Hristev <eugen.hristev@microchip.com>
2020-10-26at91sam9: disable obsolete VIDEO configAnatolij Gustschin
DM_VIDEO conversion deadline has passed, disable VIDEO config. Signed-off-by: Anatolij Gustschin <agust@denx.de>
2020-10-26picosam9g45: disable obsolete VIDEO configAnatolij Gustschin
DM_VIDEO conversion deadline has passed, disable VIDEO config. Signed-off-by: Anatolij Gustschin <agust@denx.de> Cc: Erik van Luijk <evanluijk@interact.nl>
2020-10-26ls1021atwr: disable obsolete VIDEO configAnatolij Gustschin
DM_VIDEO conversion deadline has passed, disable VIDEO config. Signed-off-by: Anatolij Gustschin <agust@denx.de>
2020-10-26ls1021aqds: disable obsolete VIDEO configAnatolij Gustschin
DM_VIDEO conversion deadline has passed, disable VIDEO config. Signed-off-by: Anatolij Gustschin <agust@denx.de> Cc: Alison Wang <alison.wang@nxp.com>
2020-10-26imx: mx7dsabresd: disable obsolete VIDEO configAnatolij Gustschin
DM_VIDEO conversion deadline has passed, disable VIDEO config. Signed-off-by: Anatolij Gustschin <agust@denx.de>
2020-10-26imx: mx6sxsabresd: disable obsolete VIDEO configAnatolij Gustschin
DM_VIDEO conversion deadline has passed, disable VIDEO config. Signed-off-by: Anatolij Gustschin <agust@denx.de>
2020-10-26Merge branch 'master' of https://gitlab.denx.de/u-boot/custodians/u-boot-riscvTom Rini
- No need to check before free in kendryte clk. - Only enable OF_BOARD_FIXUP if U-Boot is configured for S-Mode. - Reduce k210 dts DMA block size - Move timers into drivers/timer - Correct fu540 dts reg size of clint node
2020-10-26riscv: fu540: dts: Correct reg size of clint nodePragnesh Patel
Signed-off-by: Pragnesh Patel <pragnesh.patel@sifive.com> Reviewed-by: Bin Meng <bin.meng@windriver.com> Reviewed-by: Rick Chen <rick@andestech.com>
2020-10-26riscv: Move timer portions of SiFive CLINT to drivers/timerSean Anderson
Half of this driver is a DM-based timer driver, and half is RISC-V-specific IPI code. Move the timer portions in with the other timer drivers. The KConfig is not moved, since it also enables IPIs. It could also be split into two configs, but no boards use the timer but not the IPI atm, so I haven't split it. Signed-off-by: Sean Anderson <seanga2@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Rick Chen <rick@andestech.com>
2020-10-26timer: Add _TIMER suffix to Andes PLMT KconfigSean Anderson
This matches the naming scheme of other timer drivers. Signed-off-by: Sean Anderson <seanga2@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Rick Chen <rick@andestech.com>
2020-10-26riscv: Move Andes PLMT driver to drivers/timerSean Anderson
This is a regular timer driver, and should live with the other timer drivers. Signed-off-by: Sean Anderson <seanga2@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Rick Chen <rick@andestech.com>