summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-01-20Merge https://source.denx.de/u-boot/custodians/u-boot-marvellTom Rini
- fdt_support: Add fdt_for_each_node_by_compatible() helper macro (Marek) - turris_omnia: Fixup SATA or PCIe nodes at runtime in DT blob (Pali) - pci_mvebu: Add support for Kirkwood PCIe controllers (Pali) - SPL: More verifications for kwbimage in SPL (Pali) - mvebu: Remove comphy_update_map() (Pali) - Minor misc stuff
2022-01-20Merge tag 'u-boot-amlogic-20220120' of ↵Tom Rini
https://source.denx.de/u-boot/custodians/u-boot-amlogic - Disable CONFIG_NET_RANDOM_ETHADDR for android configs - meson64_android: define raw parts for bootloader to permit flashing with fastboot - vim3: configure serial# from ethaddr to permit using fastboot like sei510/610
2022-01-20Merge tag 'doc-2022-04-rc1' of ↵Tom Rini
https://source.denx.de/u-boot/custodians/u-boot-efi Pull request doc-2022-04-rc1 Replace @return by Return: in code comments.
2022-01-20arm: a37xx: Disable CONFIG_DEBUG_UART_ANNOUNCEPali Rohár
After next branch was merged to v2022.01 release, U-Boot on A3720 started printing "<debug_uart>" line on UART during booting. There is no need to print this debug line by default, so disable it via config option CONFIG_DEBUG_UART_ANNOUNCE in all config files for Armada 3720 boards. Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20phy: marvell: Remove unused function comphy_update_map()Pali Rohár
This weak function is not used anymore, so completely remove it. Private struct comphy_map is not used by any board code anymore, so move it into private driver header file comphy_core.h. Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20arm: mvebu: turris_mox: Convert comphy_update_map() to board_fix_fdt()Pali Rohár
Code in board_fix_fdt() already detects connected MOX modules so there is no need to have custom comphy_update_map() function for setting serdes speeds. This change sets phy-mode for MOX SFP module (when present) to sgmii. Comphy driver then sets sgmii serdes speed for this module to 1.25G. Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20drivers: octeon: get rid of Unicode in codeHeinrich Schuchardt
Placing Unicode control codes <U+0080><U+0093> in the middle of a comment does not make much sense. Let's get rid of all Unicode in drivers/ram/octeon/octeon3_lmc.c. Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20arm: mvebu: spl: Fix 100 column exceedsMarek Behún
Fix 100 column exceeds in arch/arm/mach-mvebu/spl.c. Signed-off-by: Marek Behún <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20arm: mvebu: spl: Use IS_ENABLED() instead of #ifdef where possibleMarek Behún
Use the preferred if (IS_ENABLED(X)) instead of #ifdef X where possible. There are still places where this is not possible or is more complicated to convert in this file. Leave those be for now. Signed-off-by: Marek Behún <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20arm: mvebu: spl: Use preferred types u8/u16/u32 instead of uintN_tMarek Behún
Checkpatch warns about using uint32/16/8_t instead of u32/16/8. Use the preferred types. Signed-off-by: Marek Behún <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20arm: mvebu: spl: Print srcaddr in error messageMarek Behún
Print the wrong srcaddr (spl_image->offset) in error message also for SATA case. Signed-off-by: Marek Behún <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20arm: mvebu: Check for kwbimage data checksumPali Rohár
Last 4 bytes of kwbimage boot image is checksum. Verify it via the new spl_check_board_image() function which is called by U-Boot SPL after loading kwbimage. Signed-off-by: Pali Rohár <pali@kernel.org> Signed-off-by: Marek Behún <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20SPL: Add support for checking board / BootROM specific image typesPali Rohár
Commit 9baab60b8054 ("SPL: Add support for parsing board / BootROM specific image types") added support for loading board specific image types. This commit adds support for a new weak function spl_parse_board_header() which is called after loading boot image. Board may implement this function for checking if loaded board specific image is valid. Signed-off-by: Pali Rohár <pali@kernel.org> Signed-off-by: Marek Behún <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20arm: mvebu: Check that kwbimage blockid matches boot modePali Rohár
Each boot mode has its own kwbimage specified by blockid. So check that kwbimage is valid by blockid. Signed-off-by: Pali Rohár <pali@kernel.org> Signed-off-by: Marek Behún <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20SPL: Add struct spl_boot_device parameter into spl_parse_board_header()Pali Rohár
Add parameter spl_boot_device to spl_parse_board_header(), which allows the implementations to see from which device we are booting and do boot-device-specific checks of the image header. Signed-off-by: Pali Rohár <pali@kernel.org> Signed-off-by: Marek Behún <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20arm: mvebu: Check that kwbimage offset and blocksize are validPali Rohár
There are certain restrictions for kwbimage offset and blocksize. Validate them. Signed-off-by: Pali Rohár <pali@kernel.org> Signed-off-by: Marek Behún <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20pci: pci_mvebu: Add support for Kirkwood PCIe controllersPali Rohár
Kirkwood uses macros KW_DEFADR_PCI_MEM and KW_DEFADR_PCI_IO for base address of PCIe mappings. Size of PCIe windows is not defined in any macro yet, so export them in new KW_DEFADR_PCI_MEM_SIZE and KW_DEFADR_PCI_IO_SIZE macros. Kirkwood arch code already maps mbus windows for io and mem, so avoid calling mvebu_mbus_add_window_by_id() function which would try to do duplicate window mapping. Kirkwood PCIe controllers already use "marvell,kirkwood-pcie" DT compatible string, so mark pci_mvebu.c driver as compatible for it. Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20arm: mvebu: turris_omnia: Fixup SATA or PCIe nodes at runtime in DT blobPali Rohár
On of the MiniPCIe ports on Turris Omnia is also a mSATA port. Whether it works in SATA or PCIe mode is determined by a strapping pin, which value is read from the MCU. We already determine which type of card is connected when configuring SerDeses. But until now we left both SATA and PCIe port 0 nodes in device tree enabled, and so the SATA driver is probed in U-Boot / Linux even if we know there is no mSATA card, and similarly PCIe driver tries to link on port 0 even if we know there is mSATA card, not a PCIe card. Fixup device tree blob to disable SATA node if mSATA card is not present, and to disable PCIe port 0 node if mSATA card is present. Do this for U-Boot's DT blob before relocation and also for kernel DT blob before booting. This ensures that software does not try to use SATA or PCIe HW when corresponding PHY is not configured. Signed-off-by: Pali Rohár <pali@kernel.org> [ refactored and fixed some issues ] Signed-off-by: Marek Behún <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de>
2022-01-20fdt_support: Add fdt_for_each_node_by_compatible() helper macroMarek Behún
Add macro fdt_for_each_node_by_compatible() to allow iterating over fdt nodes by compatible string. Convert various usages of off = fdt_node_offset_by_compatible(fdt, start, compat); while (off > 0) { code(); off = fdt_node_offset_by_compatible(fdt, off, compat); } and similar, to fdt_for_each_node_by_compatible(off, fdt, start, compat) code(); Signed-off-by: Marek Behún <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de> Reviewed-by: Simon Glass <sjg@chromium.org>
2022-01-20board: amlogic: vim3: configure serial# from ethaddrMattijs Korpershoek
The Khadas VIM3 and VIM3L boards, which are supported in Android via Yukawa [1] need a serial number for usb/fastboot enumeration. Whenever the environment does not provide a serial#, use the eth mac address as serial#. [1] https://source.android.com/setup/build/devices#vim3_and_vim3l_boards Signed-off-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Reviewed-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Link: https://lore.kernel.org/r/20220119142400.127342-1-mkorpershoek@baylibre.com
2022-01-20configs: meson64_android: define raw parts for bootloaderMattijs Korpershoek
Per the android documentation[1]: - the mmc2boot0 partition should be labeled "bootloader". - the mmc2boot1 partition should be labeled "bootenv". Also the u-boot documentation[2] refers to a BOOT1_OFFSET of 1 block. Define 2 raw partitions to store the bootloaders and the bootenv. [1] https://source.android.com/setup/build/devices#vim3-fastboot [2] https://u-boot.readthedocs.io/en/latest/board/amlogic/khadas-vim3l.html Suggested-by: Gary Bisson <gary.bisson@boundarydevices.com> Signed-off-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Link: https://lore.kernel.org/r/20220107163913.3393563-1-mkorpershoek@baylibre.com Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
2022-01-20configs: amlogic: Disable CONFIG_NET_RANDOM_ETHADDR for androidMattijs Korpershoek
The Khadas vim3 and vim3l defconfigs introduced with: * f89b90d2d9 ("configs: add khadas-vim3{l}_android for AOSP support") * 425f06f86e ("configs: prepare khadas-vim3{l}_ab_android for AOSP support") were based on an outdated defconfig prior to the ede1f4f297 ("configs: amlogic: Disable CONFIG_NET_RANDOM_ETHADDR when unnecessary") cleanup. Disable CONFIG_NET_RANDOM_ETHADDR for the android configs as well to stay consistent. Signed-off-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Link: https://lore.kernel.org/r/20220112084023.2858375-1-mkorpershoek@baylibre.com Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
2022-01-19doc: replace @return by Return:Heinrich Schuchardt
Sphinx expects Return: and not @return to indicate a return value. find . -name '*.c' -exec \ sed -i 's/^\(\s\)\*\(\s*\)@return\(\s\)/\1*\2Return:\3/' {} \; find . -name '*.h' -exec \ sed -i 's/^\(\s\)\*\(\s*\)@return\(\s\)/\1*\2Return:\3/' {} \; Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2022-01-19Merge tag 'xilinx-for-v2022.04-rc1' of ↵Tom Rini
https://source.denx.de/u-boot/custodians/u-boot-microblaze Xilinx changes for v2022.04-rc1 gpio: - Add modepin driver net: - Save random mac addresses to eth variable zynqmp gem: - Add support for mdio bus DT description - Add support for reset and SGMII phy configuration - Reduce timeout for MDIO accesses zynqmp clk: - Fix clock handling for gem and usb phy: - Add zynqmp phy/serdes driver serial: - Add one missing compatible string microblaze: - Symbol alignement - SPL fixups - Code cleanups zynqmp: - Various dt changes, DP pre-reloc, gem resets, gem clocks - Switch SOM to shared psu configuration - Move dcache handling to firmware driver - Workaround gmii2rgmii DT description issue - Enable broadcasts again - Change firmware enablement logic - Small adjustement in firmware driver versal: - Support new mmc@ DT nodes - Fix run time variable handling - Add missing I2C_PMC ID for power domain
2022-01-19doc: samsung: axy17lte: Fix underlinesTom Rini
A few sections had underlines that were too short, correct. Signed-off-by: Tom Rini <trini@konsulko.com>
2022-01-19firmware: zynqmp: Do not report error if node is already configuredMichal Simek
Power domain driver sends PM fragment to PMUFW. It is sent for every node which is listed in DT. But some nodes could be already enabled but driver is not capable to find it out. That's why it blinly sents request for every listed IP. When PMUFW response by XST_PM_ALREADY_CONFIGURED error code there is no need to show any error message because node is already enabled. That's why cover this case with message when DEBUG is enabled. Signed-off-by: Michal Simek <michal.simek@xilinx.com> Link: https://lore.kernel.org/r/8c15ef0b68cf191f693d3d010f70ac24cfd8171f.1642163135.git.michal.simek@xilinx.com
2022-01-19firmware: zynqmp: Move loading message to debugMichal Simek
Power domain driver is using this function for every IP which is PD listed. This can end up with a lot of messages which end up in boot log. That's why show it only in EL3 as was used in past. Signed-off-by: Michal Simek <michal.simek@xilinx.com> Link: https://lore.kernel.org/r/d73fc8bc663110b6e8d5e70fdb6435d1199e9db8.1642163135.git.michal.simek@xilinx.com
2022-01-19Merge https://source.denx.de/u-boot/custodians/u-boot-samsungTom Rini
- Updates for a{3,7}y17lte platforms
2022-01-19arm64: zynqmp: Change firmware dependencyMichal Simek
In case of mini U-Boot configurations there is no need to enable firmware driver which just consume space for nothing. That's why add an option to disable it. Signed-off-by: Michal Simek <michal.simek@xilinx.com> Link: https://lore.kernel.org/r/d439399160ff3374f2b39f54f7dd70fa8c8bfea0.1642162121.git.michal.simek@xilinx.com
2022-01-19arm64: xilinx: dts: Add dma properties to fix dtbs_check warningsShravya Kumbham
Update dma name and add #dma-cells properties to fix dtbs_check warnings. Signed-off-by: Shravya Kumbham <shravya.kumbham@xilinx.com> Signed-off-by: Michal Simek <michal.simek@xilinx.com> Link: https://lore.kernel.org/r/fedbf83fd5c682b4d61905d2cb790d33c2f079d6.1642160644.git.michal.simek@xilinx.com
2022-01-19arm64: zynqmp: Update USB node handle from dwc3 to usbManish Narani
The DWC3 bindings require all USB node handles to be '^usb@[0-9a-f]+$'. Update the same in ZynqMP device tree. Signed-off-by: Manish Narani <manish.narani@xilinx.com> Signed-off-by: Michal Simek <michal.simek@xilinx.com> Link: https://lore.kernel.org/r/26fc2777eeb92cb5cb1d558d7c19cfb54ac42d0c.1642160613.git.michal.simek@xilinx.com
2022-01-19arm64: zynqmp: Change compatible strings for cadence uartMichal Simek
Based on Linux kernel DT binding there should be different compatible strings used that's why align zynqmp.dtsi with it. Signed-off-by: Michal Simek <michal.simek@xilinx.com> Link: https://lore.kernel.org/r/e2404ccd22fd97fe6020be0b3b6eb3c8677f55b0.1642160583.git.michal.simek@xilinx.com
2022-01-18Merge branch '2022-01-18-platform-updates'Tom Rini
- cubieboard7 MMC support, AST2600 MAC support
2022-01-18miiphy.h: Remove CONFIG_DM_xxx guardsTom Rini
Function prototypes must not be guarded with ifdef tests. Doing so prevents us from doing: if (CONFIG_IS_ENABLED(FOO)) func(); as that results in a warning when CONFIG_FOO is not enabled. Signed-off-by: Tom Rini <trini@konsulko.com>
2022-01-18clk: ast2600: Revise MII interface delayDylan Hung
The clock delay of the RMII/RGMII interface is controlled by SCU340~35C. These values are obtained by measurement and experiments so we simply use macro to define them. Signed-off-by: Dylan Hung <dylan_hung@aspeedtech.com> Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
2022-01-18configs: ast2600: enable DM_MDIO and MDIO driverDylan Hung
Enable DM_MDIO and Aspeed MDIO driver for AST2600 EVB. Signed-off-by: Dylan Hung <dylan_hung@aspeedtech.com> Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
2022-01-18ARM: dts: ast2600: Add MDIO devicesDylan Hung
There are 4 MDIO bus controllers in AST2600 SOC. Each of them can connect to one or more PHY chips and is flexible to work with the 4 MAC devices in AST2600. On AST2600 EVB, MDIO 0,1,2,3 connect to the PHY chips used by MAC 0,1,2,3 respectively. Signed-off-by: Dylan Hung <dylan_hung@aspeedtech.com> Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
2022-01-18net: ftgmac100: Add Aspeed AST2600 supportDylan Hung
Add support of the MAC controller of Aspeed AST2600 SOC. The MAC controller is the same with AST2500, except it has stand-alone MDIO hardware block. Signed-off-by: Dylan Hung <dylan_hung@aspeedtech.com> Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
2022-01-18net: ftgmac100: Add DM_MDIO supportDylan Hung
Add support for DM_MDIO to connect to PHY. For the systems that have a stand-alone MDIO hardware block, enable CONFIG_DM_MDIO to use driver model for MDIO devices. Signed-off-by: Dylan Hung <dylan_hung@aspeedtech.com> Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
2022-01-18configs: Enable mmc supportAmit Singh Tomar
This commits enables mmc on the Actions Cubieboard7 board. Signed-off-by: Amit Singh Tomar <amittomer25@gmail.com>
2022-01-18mmc: actions: add MMC driver for Actions OWL S700/S900Amit Singh Tomar
This commit adds support for MMC controllers found on Actions OWL SoC platform(S700/S900). Signed-off-by: Amit Singh Tomar <amittomer25@gmail.com>
2022-01-18ARM: dts: s700: add MMC/SD controller nodeAmit Singh Tomar
This patch adds node for mmc/sd controller found on Action Semi OWL S700 SoC. Since, upstream Linux binding has not been merged for S700 MMC/SD controller, Changes are put in u-boot specific dtsi file. Signed-off-by: Amit Singh Tomar <amittomer25@gmail.com>
2022-01-18ARM: dts: sync Actions Semi S700 DT from Linux v5.16-rc3Amit Singh Tomar
This Synchronizes the Actions Semi S700 SoC DT changes from commit "g58e1100fdc59" ("Linux v5.16-rc3"). Signed-off-by: Amit Singh Tomar <amittomer25@gmail.com>
2022-01-18clk: actions: Add SD/MMC clocksAmit Singh Tomar
This commit adds SD/MMC clocks, and provides .set/get_rate callbacks for SD/MMC device present on Actions OWL S700 SoCs. Signed-off-by: Amit Singh Tomar <amittomer25@gmail.com>
2022-01-18clk: actions: Introduce dummy get/set_rate callbacksAmit Singh Tomar
This commit introduces get/set_rate callbacks, these are dummy at the moment, and can be used to get/set clock for various devices based on the clk id. Signed-off-by: Amit Singh Tomar <amittomer25@gmail.com> Reviewed-by: Sean Anderson <seanga2@gmail.com>
2022-01-18Merge branch '2022-01-17-assorted-updates'Tom Rini
- musb gadget pinctrl-single, pxa3xx nand bugfixes - btrfs BLAKE2 hash support and another btrfs fix - board_r cleanups
2022-01-18pinctrl: single: add support for pinctrl-single, pins when #pinctrl-cells = 2AJ Bagwell
Changes to the am33xx device (33e9021a) trees have been merged in from the upstream linux kernel which now means the device tree uses the new pins format (as of 5.10) where the confinguration can be stores as a separate configuration value and pin mux mode which are then OR'd together. This patch adds support for the new format to u-boot so that pinctrl-cells is now respected when reading in pinctrl-single,pins Signed-off-by: Anthony Bagwell <anthony.bagwell@hivehome.com>
2022-01-18fs/btrfs: fix a bug that U-boot fs btrfs implementation doesn't handle ↵Qu Wenruo
NO_HOLE feature correctly [BUG] When passing a btrfs with NO_HOLE feature to U-boot, and if one file contains holes, then the hash of the file is not correct in U-boot: # mkfs.btrfs -f test.img # Since v5.15, mkfs defaults to NO_HOLES # mount test.img /mnt/btrfs # xfs_io -f -c "pwrite 0 4k" -c "pwrite 8k 4k" /mnt/btrfs/file # md5sum /mnt/btrfs/file 277f3840b275c74d01e979ea9d75ac19 /mnt/btrfs/file # umount /mnt/btrfs # ./u-boot => host bind 0 /home/adam/test.img => ls host 0 < > 12288 Mon Dec 27 05:35:23 2021 file => load host 0 0x1000000 file 12288 bytes read in 0 ms => md5sum 0x1000000 0x3000 md5 for 01000000 ... 01002fff ==> 855ffdbe4d0ccc5acab92e1b5330e4c1 The md5sum doesn't match at all. [CAUSE] In U-boot btrfs implementation, the function btrfs_read_file() has the following iteration for file extent iteration: /* Read the aligned part */ while (cur < aligned_end) { ret = lookup_data_extent(root, &path, ino, cur, &next_offset); if (ret < 0) goto out; if (ret > 0) { /* No next, direct exit */ if (!next_offset) { ret = 0; goto out; } } /* Read file extent */ But for NO_HOLES features, hole extents will not have any extent item for it. Thus if @cur is at a hole, lookup_data_extent() will just return >0, and update @next_offset. But we still believe there is some data to read for @cur for ret > 0 case, causing we read extent data from the next file extent. This means, what we do for above NO_HOLES btrfs is: - Read 4K data from disk to file offset [0, 4K) So far the data is still correct - Read 4K data from disk to file offset [4K, 8K) We didn't skip the 4K hole, but read the data at file offset [8K, 12K) into file offset [4K, 8K). This causes the checksum mismatch. [FIX] Add extra check to skip to the next non-hole range after lookup_data_extent(). Signed-off-by: Qu Wenruo <wqu@suse.com>
2022-01-18fs/btrfs: add dependency on BLAKE2 hashQu Wenruo
Now btrfs can utilize the newly intorudced BLAKE2 hash. Signed-off-by: Qu Wenruo <wqu@suse.com>
2022-01-18lib: add BLAKE2 hash supportQu Wenruo
The code is cross-ported from BLAKE2 reference implementation (https://github.com/BLAKE2/BLAKE2). With minimal change to remove unused macros/features. Currently there is only one user inside U-boot (btrfs), and since it only utilize BLAKE2B, all other favors are all removed. Signed-off-by: Qu Wenruo <wqu@suse.com> [trini: Rename ROUND to R to avoid clash with <linux/bitops.h> Signed-off-by: Tom Rini <trini@konsulko.com>