summaryrefslogtreecommitdiff
path: root/drivers
AgeCommit message (Collapse)Author
2024-01-09fastboot: add oem console command supportIon Agorria
"oem console" serves to read console record buffer. Signed-off-by: Ion Agorria <[email protected]> Signed-off-by: Svyatoslav Ryhel <[email protected]> Reviewed-by: Mattijs Korpershoek <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mattijs Korpershoek <[email protected]>
2024-01-09fastboot: implement "getvar all"Ion Agorria
This commit implements "fastboot getvar all" listing by iterating the existing dispatchers that don't require parameters (as we pass NULL), uses fastboot multiresponse. Signed-off-by: Ion Agorria <[email protected]> Signed-off-by: Svyatoslav Ryhel <[email protected]> Reviewed-by: Mattijs Korpershoek <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mattijs Korpershoek <[email protected]>
2024-01-09fastboot: multiresponse supportIon Agorria
Currently u-boot fastboot can only send one message back to host, so if there is a need to print more than one line messages must be kept sending until all the required data is obtained. This behavior can be adjusted using multiresponce ability (getting multiple lines of response) proposed in this patch. Signed-off-by: Ion Agorria <[email protected]> Signed-off-by: Svyatoslav Ryhel <[email protected]> Reviewed-by: Mattijs Korpershoek <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mattijs Korpershoek <[email protected]>
2024-01-09cpu: riscv: set correct SMBIOS processor family valueHeinrich Schuchardt
The SMBIOS specification requires to set the processor family in the type 4 (Processor Information) table to specific values depending only on the bitness of the system (0x200 for RV32 and 0x201 for RV64). With this patch dmidecode shows Handle 0x0004, DMI type 4, 48 bytes Processor Information Socket Designation: Not Specified Type: Central Processor Family: RV64 for qemu-riscv64_smode_defconfig. Signed-off-by: Heinrich Schuchardt <[email protected]>
2024-01-09rng: detect RISC-V Zkr RNG device in bind methodHeinrich Schuchardt
The existence of devices should be checked in the bind method and not in the probe method. Adjust the RISC-V Zkr RNG driver accordingly. Use ENOENT (and not ENODEV) to signal that the device is not available. Fixes: ceec977ba1a9 ("rng: Provide a RNG based on the RISC-V Zkr ISA extension") Reported-by: Andre Przywara <[email protected]> Signed-off-by: Heinrich Schuchardt <[email protected]>
2024-01-09rng: fix ARMv8.5 RNDR driverHeinrich Schuchardt
In different parts of our code we assume that the first RNG device is the one to be used. Therefore it is preferable to detect the availability of the RNDR register already in the bind method. For signaling the non-existence of a device the driver model requires using ENOENT (and not ENODEV). Fixes: 31565bb0aa2d ("driver: rng: Add DM_RNG interface for ARMv8.5 RNDR registers") Signed-off-by: Heinrich Schuchardt <[email protected]> Reviewed-by: Andre Przywara <[email protected]> Tested-by: Andre Przywara <[email protected]>
2024-01-07acpi: enable writing ACPI tables on QEMUHeinrich Schuchardt
Invoke write_acpi_tables() via EVT_LAST_STAGE_INIT on QEMU except on X86. X86 calls write_acpi_tables() in write_tables(). Signed-off-by: Heinrich Schuchardt <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-01-07acpi: carve out qfw_acpi.cHeinrich Schuchardt
Move the code related to copying tables from QEMU to a separate code module. Signed-off-by: Heinrich Schuchardt <[email protected]> Reviewed-by: Tom Rini <[email protected]> Reviewed-by: Simon Glass <[email protected]> Reviewed-by: Ilias Apalodimas <[email protected]>
2024-01-07acpi: Kconfig symbol CONFIG_QFW_ACPIHeinrich Schuchardt
We have two implementations of write_acpi_tables(). One for writing ACPI tables based on ACPI_WRITER() entries another based on copying tables from QEMU. Create a symbol CONFIG_QFW_ACPI that signifies copying ACPI tables from QEMU and use it consistently. Signed-off-by: Heinrich Schuchardt <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-01-03Merge tag 'v2024.01-rc6' into nextTom Rini
Prepare v2024.01-rc6
2023-12-27cache: add sifive private L2 cache driverZong Li
This driver is currently responsible for enabling the clock gating feature of SiFive pre core's private L2 cache. Signed-off-by: Zong Li <[email protected]> Reviewed-by: Leo Yu-Chi Liang <[email protected]>
2023-12-26spi: npcm_pspi: Fix the wrong clock divider calculationJim Liu
Fix the wrong clock divider calculation. Signed-off-by: Jim Liu <[email protected]>
2023-12-21iommu: add qcom-hyp-smmuCaleb Connolly
Add a basic implementation of the ARM SMMU. This driver is intended for use on Qualcomm platforms where the SMMU has been configured by a previous bootloader, cannot be turned off, and doesn't support BYPASS streams. It keeps all existing stream mappings and only creates new ones for stream ids that aren't already configured. This driver is necessary to support peripherals that perform DMA which weren't configured by the previous stage bootloader (for example USB). It works by allocating a context bank using identity mapping (as U-Boot doesn't use virtual addresses). Signed-off-by: Caleb Connolly <[email protected]>
2023-12-21iommu: add a connect opCaleb Connolly
Add an optional iommu callback to be invoked before a device probes. This can be used to configure the IOMMU in preparation for the device (e.g. by allocating a context bank) Signed-off-by: Caleb Connolly <[email protected]>
2023-12-21iommu: fix compilation when CONFIG_PCI disabledCaleb Connolly
The dev_pci_iommu_enable() function is only available when CONFIG_PCI is enabled, replace the runtime check with a preprocessor one to fix compilation with pci disabled. Signed-off-by: Caleb Connolly <[email protected]>
2023-12-21global: Remove duplicate common.h inclusionsTom Rini
These files include <common.h> twice. Start by removing the second inclusion of the file. Reviewed-by: Simon Glass <[email protected]> Signed-off-by: Tom Rini <[email protected]>
2023-12-21global: Drop common.h inclusionTom Rini
In order to make it easier to move on to dropping common.h from code directly, remove common.h inclusion from the rest of the header file which had been including it. Reviewed-by: Simon Glass <[email protected]> Signed-off-by: Tom Rini <[email protected]>
2023-12-21arm: Partial cleanup and audit usage of <config.h>Tom Rini
We need to include <config.h> directly when a file needs to have something such as CFG_SYS_SDRAM_SIZE referenced as this file is not automatically globally included and is most commonly indirectly included via common.h. Remove most cases of arm including config.h directly, but add it where needed. This includes a few board-specific fixes. Reviewed-by: Simon Glass <[email protected]> Signed-off-by: Tom Rini <[email protected]>
2023-12-21global: Restrict use of '#include <linux/kconfig.h>'Tom Rini
In general terms, we -include include/linux/kconfig.h and so normal U-Boot code does not need to also #include it. However, for code which is shared with userspace we may need to add it so that either our full config is available or so that macros such as CONFIG_IS_ENABLED() can be evaluated. In this case make sure that we guard these includes with a test for USE_HOSTCC so that it clear as to why we're doing this. Reviewed-by: Simon Glass <[email protected]> Signed-off-by: Tom Rini <[email protected]>
2023-12-20Merge tag 'u-boot-amlogic-next-20231220' of ↵Tom Rini
https://source.denx.de/u-boot/custodians/u-boot-amlogic into next - Add support for new GXL MDIO mux, with driver and Linux DT sync from v6.4
2023-12-19drivers: pinctrl: tegra: incorporate existing codeSvyatoslav Ryhel
Move all existing pinmux and funcmux code into a dedicated folder in pinctrl to simplify further maintenance. Signed-off-by: Svyatoslav Ryhel <[email protected]>
2023-12-19drivers: pinctrl: create Tegra DM pinctrl driverSvyatoslav Ryhel
The existing pinctrl driver available for Tegra SOC is well designed, but it lacks DM support. Let's add a DM compatible overlay, which allows use of the device tree, along with preserving backward compatibility with all existing setups and the ability to use it in SPL board configuration stage. Signed-off-by: Svyatoslav Ryhel <[email protected]>
2023-12-19mmc: tegra: use max-frequency from device tree if providedPeter Geis
The driver currently hard-codes the max freqency for the sdhci controllers. If the controller is unable to operate at the max frequency, the mmc card will not be available on the first scan. Subsequent scans will eventually find a working combination. Fix this by allowing the driver to check for the max-frequency property and default to the original value if it doesn't exist. Signed-off-by: Peter Geis <[email protected]> Signed-off-by: Svyatoslav Ryhel <[email protected]>
2023-12-19drivers: gpio-uclass: support PMIC GPIO childrenSvyatoslav Ryhel
UCLASS_PMIC may have GPIO children without exposed fdt node, in this case if requesting fails, check if uclass is PMIC. Restrict build for supported devices only to save those precious bytes on devices with no spare memory. Signed-off-by: Svyatoslav Ryhel <[email protected]>
2023-12-19drivers: gpio: implement PALMAS GPIO cellSvyatoslav Ryhel
Add gpio driver for TI Palmas series PMIC. This has 8 gpio which can work as input/output. Signed-off-by: Svyatoslav Ryhel <[email protected]>
2023-12-19drivers: gpio: implement MAX77663 GPIO cellSvyatoslav Ryhel
MAXIM Semiconductor's PMIC, MAX77663 has 8 GPIO pins and 3 GPIO-like pins. It also supports interrupts from these pins. Add GPIO driver for these pins to control via GPIO APIs. Signed-off-by: Svyatoslav Ryhel <[email protected]>
2023-12-19Merge patch series "Add support for MediaTek MT8365 EVK Board"Tom Rini
Julien Masson <[email protected]> says: This patch series add the support for the MediaTek MT8365 EVK Board [1]. Most of the code have been copied/adapted from Linux tag v6.7-rc2. For now we only enable/test these features: Boot, UART, Watchdog and MMC. [trini: This includes two clocks not listed in the Linux binding, which needs resyncing later]
2023-12-19clk: mediatek: add clock driver support for MediaTek MT8365 SoCJulien Masson
This patch adds clock driver support for MediaTek MT8365 SoC. The changes are based on the Linux source code tag v6.7-rc2. clk-mt8365.c has been written based on these kernel files: - clk-mt8365.c (a96cbb146a9736f501fe66ebda6a9018735e5e8a) - clk-mt8365-apmixedsys.c (65c9ad77cbc0eed78db94d80041aba675cfbdfa9) And adapted following the clk attributes supported by U-Boot. Signed-off-by: Julien Masson <[email protected]> Reviewed-by: Mattijs Korpershoek <[email protected]>
2023-12-19mmc: mediatek: set b_max according CONFIG_SYS_MMC_MAX_BLK_COUNTJulien Masson
The block count limit on MMC based devices should be set according to CONFIG_SYS_MMC_MAX_BLK_COUNT instead of hardcoding value. Signed-off-by: Julien Masson <[email protected]>
2023-12-19gpio: dw: Drop unused headersMaksim Kiselev
Drop headers which are not used or needed in this file. Signed-off-by: Maksim Kiselev <[email protected]>
2023-12-19tee: optee: don't enumerate services if there ain't anyEtienne Carriere
Change optee driver service enumeration to not enumerate (and allocate a zero sized shared memory buffer) when OP-TEE reports that there is no service to enumerate. This change fixes an existing issue that occurs when the such zero sized shared memory buffer allocated from malloc() has a physical address of offset 0 of a physical 4kB page. In such case, OP-TEE secure world refuses to register the zero-sized shared memory area and makes U-Boot optee service enumeration to fail. Fixes: 94ccfb78a4d6 ("drivers: tee: optee: discover OP-TEE services") Signed-off-by: Etienne Carriere <[email protected]> Reviewed-by: Patrice Chotard <[email protected]> Reviewed-by: Jens Wiklander <[email protected]>
2023-12-19tee: optee: don't fail on services enumeration failureEtienne Carriere
Change optee probe function to only warn when service enumeration sequence fails instead of reporting an optee driver probe failure. Indeed U-Boot can still use OP-TEE even if some OP-TEE services are not discovered. Fixes: 94ccfb78a4d6 ("drivers: tee: optee: discover OP-TEE services") Signed-off-by: Etienne Carriere <[email protected]> Reviewed-by: Patrice Chotard <[email protected]> Reviewed-by: Jens Wiklander <[email protected]>
2023-12-19remoteproc: k3-dsp: Avoid reloading of firmwareUdit Kumar
DSP core is going into abnormal state when load callback is called after starting of DSP core. Reload of firmware needs core to be stopped first, followed by load. So avoid loading of firmware, when core is started. Signed-off-by: Udit Kumar <[email protected]>
2023-12-19net: Add Amlogic GXL MDIO Mux driverNeil Armstrong
Port the mdio-mux-meson-gxl.c Linux driver introduced in [1], and adapt it to U-Boot. This driver is needed to boot U-Boot with Linux DT since v6.4, since it switched the MDIO mux from the mmio to a proper GXL driver. [1] 9a24e1ff4326 ("net: mdio: add amlogic gxl mdio mux support") Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Neil Armstrong <[email protected]>
2023-12-18Merge branch 'next' of https://source.denx.de/u-boot/custodians/u-boot-riscv ↵Tom Rini
into next - VisionFive2: Enable CONFIG_SYSRESET - StarFive: Modify starfive timer driver - AMD/Xilinx: Add MicroBlaze V support - Unmatched: Migrate to text environment
2023-12-18Merge branch 'master' of https://source.denx.de/u-boot/custodians/u-boot-spi ↵Tom Rini
into next - spi_nor_read_sfdp_dma_unsafe (Vaishnav) - w25q01/02 (Jim)
2023-12-18Merge tag 'v2024.01-rc5' into nextTom Rini
Prepare v2024.01-rc5
2023-12-18timer: starfive: Add Starfive timer supportKuan Lim Lee
Add timer driver in Starfive SoC. It is an timer that outside of CPU core and inside Starfive SoC. Signed-off-by: Kuan Lim Lee <[email protected]> Signed-off-by: Wei Liang Lim <[email protected]> Changes for v2: - correct driver name, comment, variable Reviewed-by: Leo Yu-Chi Liang <[email protected]>
2023-12-15Merge tag 'clk-2024.01-next' of ↵Tom Rini
https://source.denx.de/u-boot/custodians/u-boot-clk into next clock patches for u-boot/next The main thing in here is Igor's conversion of soc_clk_dump to a clk_ops member. There's also a write-protect feature for nuvoton clocks. Signed-off-by: Sean Anderson <[email protected]>
2023-12-15test: dm: clk_ccf: test ccf_clk_opsYang Xiwen
Assign ccf_clk_ops to .ops of clk_ccf driver so that it can act as an clk provider. Also add "#clock-cells=<1>" to its device tree node. Add "i2c_root" to clk_test in the device tree and driver for testing. Get "i2c_root" clock in CCF unit tests and add tests for it. Signed-off-by: Yang Xiwen <[email protected]> Reviewed-by: Sean Anderson <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2023-12-15clk: nuvoton: add read only feature for clk driverJim Liu
Add a flag to set ahb/apb/fiu/spi clock divider as read-only The spi clock setting is related to booting flash, it is setup by early bootloader. It just protects the clock source and can't modify it in uboot. Signed-off-by: Jim Liu <[email protected]> Reviewed-by: Sean Anderson <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2023-12-15clk: treewide: switch to clock dump from clk_opsIgor Prusov
Switch to using new dump operation in clock provider drivers instead of overriding soc_clk_dump. Tested-by: Patrice Chotard <[email protected]> Reviewed-by: Sean Anderson <[email protected]> Signed-off-by: Igor Prusov <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2023-12-15clk: amlogic: Move driver and ops structsIgor Prusov
Move driver and ops structs to avoid forward declaration after switching to dump in clk_ops. Reviewed-by: Neil Armstrong <[email protected]> Signed-off-by: Igor Prusov <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2023-12-15clk: k210: Move soc_clk_dump functionIgor Prusov
Move clock dump function to avoid forward declaration after switching to dump in clk_ops. Reviewed-by: Sean Anderson <[email protected]> Signed-off-by: Igor Prusov <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2023-12-15clk: ast2600: Move soc_clk_dump functionIgor Prusov
Move clock dump function to avoid forward declaration after switching to dump in clk_ops. Signed-off-by: Igor Prusov <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2023-12-15clk: zynq: Move soc_clk_dump to Zynq clock driverIgor Prusov
Move clock dump function in preparation for switching to dump function in clk_ops. Acked-by: Michal Simek <[email protected]> Signed-off-by: Igor Prusov <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2023-12-15clk: Check that composite clock's div has set_rate()Igor Prusov
It's possible for composite clocks to have a divider that does not implement set_rate() operation. For example, sandbox_clk_composite() registers composite clock with a divider that only has get_rate(). Currently clk_composite_set_rate() only checks thate rate_ops are present, so for sandbox it will cause NULL dereference during clk_set_rate(). This patch adds rate_ops->set_rate check tp clk_composite_set_rate(). Signed-off-by: Igor Prusov <[email protected]> Reviewed-by: Sean Anderson <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2023-12-15clk: get correct ops for clk_enable() and clk_disable()Yang Xiwen
assign clk_dev_ops(clkp->dev) to ops to ensure correct clk operations are called on clocks. This fixes the incorrect enable_count issue as described in [1]. [1]: https://lore.kernel.org/all/SEZPR06MB695927A6DEEEF8489A06897396A7A@SEZPR06MB6959.apcprd06.prod.outlook.com/ Signed-off-by: Yang Xiwen <[email protected]> Reviewed-by: Sean Anderson <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2023-12-15clk: check parent_name in clk_register to avoid confusing log_error() outputYang Xiwen
For some gate clocks and fixed clocks without a parent, calling clk_register will print an useless error message indicating that parent is missing. Fix that by gaurding log_xxx() with an if-statement. Signed-off-by: Yang Xiwen <[email protected]> Suggested-by: Sean Anderson <[email protected]> Reviewed-by: Sean Anderson <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2023-12-15board: stm32f469-disco: add support to displayDario Binacchi
Add support to Orise Tech OTM8009A display on stm32f469-disco board. It was necessary to retrieve the framebuffer address from the device tree because the address returned by the video-uclass driver pointed to a memory area that was not usable. Signed-off-by: Dario Binacchi <[email protected]> Reviewed-by: Patrice Chotard <[email protected]>