summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2024-01-07smbios: Require the caller to align the SMBIOS tableSimon Glass
All callers handle this alignment, so drop the unnecessary code. This simplifies things a little. Signed-off-by: Simon Glass <[email protected]> Reviewed-by: Heinrich Schuchardt <[email protected]> Reviewed-by: Ilias Apalodimas <[email protected]>
2024-01-07efi: Use the correct GUID for the SMBIOS tableSimon Glass
EFI does not use the 'anchor string' to determine the SMBIOS table version, instead preferring to have two separate GUIDs. Use the correct one, depending on the table version. Call unmap_system() to balance to the use of map_sysmem() Signed-off-by: Simon Glass <[email protected]> Reviewed-by: Heinrich Schuchardt <[email protected]> Reviewed-by: Ilias Apalodimas <[email protected]>
2024-01-07smbios: Correct gd_smbios_start()Simon Glass
This should access arch-specific properties. Fix it and update the existing usage. Signed-off-by: Simon Glass <[email protected]> Reviewed-by: Heinrich Schuchardt <[email protected]> Reviewed-by: Ilias Apalodimas <[email protected]>
2024-01-07smbios: Use SMBIOS 3.0 to support an address above 4GBSimon Glass
When the SMBIOS table is written to an address above 4GB a 32-bit table address is not large enough. Use an SMBIOS3 table in that case. Note that we cannot use efi_allocate_pages() since this function has nothing to do with EFI. There is no equivalent function to allocate memory below 4GB in U-Boot. One solution would be to create a separate malloc() pool, or just always put the malloc() pool below 4GB. - Use log_debug() for warning - Rebase on Heinrich's smbios.h patch - Set the checksum for SMBIOS3 Signed-off-by: Simon Glass <[email protected]> Reviewed-by: Heinrich Schuchardt <[email protected]>
2024-01-07smbios: SMBIOS 3.0 (64-bit) Entry Point structureHeinrich Schuchardt
Add definition of the SMBIOS 3.0 (64-bit) Entry Point structure. Signed-off-by: Heinrich Schuchardt <[email protected]> Reviewed-by: Simon Glass <[email protected]> Reviewed-by: Ilias Apalodimas <[email protected]> Signed-off-by: Simon Glass <[email protected]>
2024-01-07smbios: Move the rest of the SMBIOS2 codeSimon Glass
Move all of this logic into the else clause, since it will not be used for SMBIOS3 Signed-off-by: Simon Glass <[email protected]> Reviewed-by: Heinrich Schuchardt <[email protected]> Reviewed-by: Ilias Apalodimas <[email protected]>
2024-01-07smbios: Refactor 32-bit code into an else statementSimon Glass
In preparation for adding support for SMBIOS3 move this code into an else statement. There is no functional change. Signed-off-by: Simon Glass <[email protected]> Reviewed-by: Heinrich Schuchardt <[email protected]> Reviewed-by: Ilias Apalodimas <[email protected]>
2024-01-06Merge branch 'staging' of ↵Tom Rini
https://source.denx.de/u-boot/custodians/u-boot-tegra into next Documentation updates for endeavoru, lg_x3, grouper and transformers, addition of MIPI calibration clock name for T114 (inline with T124+), conversion of TEGRA_SUPPORT_NON_SECURE into Kconfig and endeavoru stability improvements.
2024-01-06Merge branch '2024-01-05-fw_env-fixes' into nextTom Rini
- A few fw_env fixes
2024-01-06arm: dts: iot2050: Fix by syncing from LinuxJan Kiszka
This restores support for IOT2050 by widely synchronizing its DT files with the Linux kernel. We additionally need to add the alias restoration that is still waiting for its upstream merge and the not-yet-upstreamed bits needed for watchdog reboot detection. Fixes: 4dbdc84754ea ("arm: dts: k3-am654: pull in dtb update from Linux") Signed-off-by: Jan Kiszka <[email protected]>
2024-01-05fw_env: autodetect NAND erase size and env sectorsAnthony Loiseau
As already done for NOR chips, if device ESIZE and ENVSECTORS static configurations are both zero, then autodetect them at runtime. Cc: Joe Hershberger <[email protected]> cc: Stefan Agner <[email protected]> cc: Rasmus Villemoes <[email protected]> Signed-off-by: Anthony Loiseau <[email protected]>
2024-01-05fw_env: keep calling read() until whole flash block is readRafał Miłecki
It's totally valid for read() to provide less bytes than requested maximum. It may happen if there is no more data available yet or source pushes data in small chunks. This actually happens when trying to read env data from NVMEM device. Kernel may provide NVMEM content in page size parts (like 4096 B). This fixes warnings like: Warning on /sys/bus/nvmem/devices/u-boot-env0/nvmem: Attempted to read 16384 bytes but got 4096 Warning on /sys/bus/nvmem/devices/u-boot-env0/nvmem: Attempted to read 12288 bytes but got 4096 Warning on /sys/bus/nvmem/devices/u-boot-env0/nvmem: Attempted to read 8192 bytes but got 4096 Since the main loop in flash_read_buf() is used to read blocks this patch adds a new nested one. Signed-off-by: Rafał Miłecki <[email protected]>
2024-01-05fw_env: rename variables holding env data contentRafał Miłecki
Rename "addr0" and "addr1" to "buf0" and "buf1" accordingly. Name "addr" suggests that variable contains a numeric value being some kind of address. Name "buf" is de facto a standard name for pointer to allocated memory for reading data to. While at it drop redundant checks for NULL before calling free(). Signed-off-by: Rafał Miłecki <[email protected]>
2024-01-05fw_env: fix reading NVMEM device's "compatible" valueRafał Miłecki
Call to fread() was changed to check for return value. The problem is it can't be checked for returning 1 (as it is) to determine success. We call fread() with buffer size as "size" argument. Reading any "compatible" value shorter than buffer size will result in returning 0 even on success. Modify code to use fstat() to determine expected read length. This fixes regression that broke using fw_env with NVMEM devices. Fixes: c059a22b7776 ("tools: env: fw_env: Fix unused-result warning") Cc: Jaehoon Chung <[email protected]> Signed-off-by: Rafał Miłecki <[email protected]>
2024-01-05board: htc: endeavoru: add an early SPL RCM hookSvyatoslav Ryhel
Unlike all other supported Tegra devices and most known Tegra devices, the HTC One X has no hardware way to enter APX/RCM mode, which may lead to a dangerous situation when, if BCT is set correctly and the bootloader is faulty, the device will hang in a permanent brick state. Exiting from this state can be done only by disassembling the device and shortening the testpad to the ground. To prevent this or to minimize the probability of such an accident, it was proposed to add the RCM rebooting hook as early into SPL as possible since SPL is much more robust and has minimal changes that can break bootflow. gpio_early_init_uart() function was chosen as it is the earliest function exposed for setup by the device. Hook performs a check for volume up button state and triggers RCM if it is pressed. Signed-off-by: Svyatoslav Ryhel <[email protected]>
2024-01-04Merge patch series "ATF and OP-TEE Firewalling for K3 devices."Tom Rini
Manorit Chawdhry <[email protected]> says: K3 devices have firewalls that are used to prevent illegal accesses to memory regions that are deemed secure. The series prevents the illegal accesses to ATF and OP-TEE regions that are present in different K3 devices. AM62X, AM62AX and AM64X are currently in hold due to some firewall configurations that our System Controller (TIFS) needs to handle. The devices that are not configured with the firewalling nodes will not be affected and can continue to work fine until the firewall nodes are added so will be a non-blocking merge. Test Logs: https://gist.github.com/manorit2001/4cead2fb3a19eb5d19005b3f54682627 CICD Run: https://github.com/u-boot/u-boot/pull/442
2024-01-04docs: board: ti: k3: Add secure booting documentationManorit Chawdhry
This commit adds a general flow to explain the usage of firewalls and the chain of trust in K3 devices. Signed-off-by: Manorit Chawdhry <[email protected]>
2024-01-04docs: board: ti: k3: Cleanup FIT signature documentationManorit Chawdhry
The previous documentation had been very crude so refactor it to make it cleaner and concise. Signed-off-by: Manorit Chawdhry <[email protected]>
2024-01-04arm: dts: k3-j7200-binman: Add firewall configurationsManorit Chawdhry
The following commits adds the configuration of firewalls required to protect ATF and OP-TEE memory region from non-secure reads and writes using master and slave firewalls present in our K3 SOCs. Signed-off-by: Manorit Chawdhry <[email protected]> Tested-by: Thomas Richard <[email protected]>
2024-01-04arm: dts: k3-j721s2-binman: Add firewall configurationsManorit Chawdhry
The following commits adds the configuration of firewalls required to protect ATF and OP-TEE memory region from non-secure reads and writes using master and slave firewalls present in our K3 SOCs. Signed-off-by: Manorit Chawdhry <[email protected]>
2024-01-04arm: dts: k3-j721e-binman: Add firewall configurationsManorit Chawdhry
The following commits adds the configuration of firewalls required to protect ATF and OP-TEE memory region from non-secure reads and writes using master and slave firewalls present in our K3 SOCs. Signed-off-by: Manorit Chawdhry <[email protected]>
2024-01-04arm: dts: k3-binman: Add k3-security.h and include it in k3-binman.dtsiManorit Chawdhry
For readability during configuring firewalls, adding k3-security.h file and including it in k3-binman.dtsi to be accessible across K3 SoCs Reviewed-by: Simon Glass <[email protected]> Signed-off-by: Manorit Chawdhry <[email protected]> Reviewed-by: Andrew Davis <[email protected]>
2024-01-04binman: ftest: Add test for ti-secure firewall nodeManorit Chawdhry
Add test for TI firewalling node in ti-secure. Reviewed-by: Simon Glass <[email protected]> Signed-off-by: Manorit Chawdhry <[email protected]>
2024-01-04binman: ti-secure: Add support for firewalling entitiesManorit Chawdhry
We can now firewall entities while loading them through our secure entity TIFS, the required information should be present in the certificate that is being parsed by TIFS. The following commit adds the support to enable the certificates to be generated if the firewall configurations are present in the binman dtsi nodes. Reviewed-by: Simon Glass <[email protected]> Signed-off-by: Manorit Chawdhry <[email protected]>
2024-01-04dtoc: Change dst to self in debug messageManorit Chawdhry
Fix the error message to not use dst and use self as it is copying the properties to self. While using templating if there are no subnodes defined, we end up in this situation where "dst" isn't defined and it tries to print the error message and fails. 'UnboundLocalError: local variable 'dst' referenced before assignment' Fixes: 55e1278d5eca ("dtoc: Allow inserting a list of nodes into another") Signed-off-by: Manorit Chawdhry <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-01-04configs: j7200: Remove HBMC_AM654 configNishanth Menon
Kernel commit 1b77265626a4 ("arm64: dts: ti: k3-j7200-mcu-wakeup: Add HyperBus node") was merged to kernel without its dependent patch [1]. Similar fix is needed in U-Boot, and hbmc currently breaks boot. Till this gets fixed in U-Boot, disable the config by default so that the hbmc probe that happens in board/ti/j721e/evm.c will not take place and lead to boot failure. This is similar to the approach in commit 5b2671594b80 ("configs: j721e: Remove HBMC_AM654 config"), introduced to j7200 evm platform. [1] https://lore.kernel.org/all/[email protected]/ Signed-off-by: Nishanth Menon <[email protected]> Reviewed-by: Neha Malcom Francis <[email protected]>
2024-01-03ARM: tegra114: support nonsecure state detectionSvyatoslav Ryhel
Principle is exactly the same as on T124, testing of register which behaves differently in secure and non-secure states. Signed-off-by: Svyatoslav Ryhel <[email protected]>
2024-01-03ARM: tegra114: expand MC register mapSvyatoslav Ryhel
This expansion is required for nonsecure detection to work correctly. Signed-off-by: Svyatoslav Ryhel <[email protected]>
2024-01-03ARM: tegra124: convert TEGRA_SUPPORT_NON_SECURE into KconfigSvyatoslav Ryhel
Signed-off-by: Svyatoslav Ryhel <[email protected]>
2024-01-03MAINTAINERS: fix folders within glob patternAnthony Loiseau
A "F: foo*" entry does not match any foo*/ folder nor its subtree, another "F: foo*/" entry is needed for that. Add missing foo*/ entries where an existing folder was ignored, so this folder and its subtree is properly covered. Arm tegra, Arm TI and Environment sections are affected. Cc: Tom Rini <[email protected]> Cc: Thierry Reding <[email protected]> Cc: Svyatoslav Ryhel <[email protected]> Cc: Tom Rini <[email protected]> Cc: Joe Hershberger <[email protected]> Signed-off-by: Anthony Loiseau <[email protected]>
2024-01-03MAINTAINERS: Fix ANDROID AB unknown file entryMattijs Korpershoek
Commit 19a91f2464a8 ("Create a new boot/ directory") moved the android_ab.c code under boot/android_ab but did not update the MAINTAINERS entry. Update it so that the maintainer will get cc'ed again. Fixes: 19a91f2464a8 ("Create a new boot/ directory") Signed-off-by: Mattijs Korpershoek <[email protected]> Reviewed-by: Sam Protsenko <[email protected]>
2024-01-03configs: Resync with savedefconfigTom Rini
Rsync all defconfig files using moveconfig.py Signed-off-by: Tom Rini <[email protected]>
2024-01-03Merge tag 'v2024.01-rc6' into nextTom Rini
Prepare v2024.01-rc6
2024-01-03Prepare v2024.01-rc6v2024.01-rc6Tom Rini
Signed-off-by: Tom Rini <[email protected]>
2024-01-03configs: Resync with savedefconfigTom Rini
Rsync all defconfig files using moveconfig.py Signed-off-by: Tom Rini <[email protected]>
2024-01-03arm: dts: k3-am62a*: Sync with kernel v6.7-rc1Nishanth Menon
Sync with kernel v6.7-rc1 and sync up the u-boot dts files accordingly. Signed-off-by: Nishanth Menon <[email protected]>
2024-01-03arm: mach-k3: am62a: Add main_timer0 id to the dev listNishanth Menon
main_timer0 is used by u-boot as the tick-timer. Add it to the soc devices list so it an be enabled via the k3 power controller. Signed-off-by: Nishanth Menon <[email protected]> Reviewed-by: Neha Malcom Francis <[email protected]>
2024-01-03Merge patch series "sync am65x device tree with Linux v6.7-rc1"Tom Rini
Bryan Brattlof <[email protected]> says: Hello Again Everyone! This series gets the am65x booting again along with syncing the device tree files with v6.7-rc1 Linux. The bulk of these patches unify the WKUP SPL board file with the arm64 files to make future syncs from Linux much easier. In the end the DTBs should look a lot like what the DTBs look like for the am64x which is fairly similar to the am65x. For those interested in what UART boot looks like: https://paste.sr.ht/~bryanb/7df8a645dc548912cd806abd5ecab967ef3287bc
2024-01-03arm: dts: k3-am654: convert bootph-pre-ram to bootph-allBryan Brattlof
Many nodes are reused between WKUP SPL, MAIN SPL, and U-Boot. Using bootph-pre-ram is causing these nodes to be present in SPL builds but pruned away during the U-Boot build. Convert these nodes to bootph-all so they will remain no matter which dtb build is happening. Tested-by: Tom Rini <[email protected]> Signed-off-by: Bryan Brattlof <[email protected]> Reviewed-by: Nishanth Menon <[email protected]>
2024-01-03arm: dts: k3-am654: remove duplicate mcu secure proxy nodeBryan Brattlof
With the Linux and U-Boot board dtb files unified, we now have a duplicate mcu secure proxy node. Remove it Tested-by: Tom Rini <[email protected]> Signed-off-by: Bryan Brattlof <[email protected]> Reviewed-by: Nishanth Menon <[email protected]>
2024-01-03arm: dts: k3-am654: move dummy_clock to root nodeBryan Brattlof
The dummy_clock node is used to help the drivers probe the IO needed to setup consoles and boot media to load firmware into the SoC. This dummy_clock isn't a device that exists nor does it exist in the mcu domain. So move it from cbass_mcu to the root node to avoid any confusion. Tested-by: Tom Rini <[email protected]> Signed-off-by: Bryan Brattlof <[email protected]> Reviewed-by: Nishanth Menon <[email protected]>
2024-01-03arm: dts: k3-am654: remove un-needed aliasesBryan Brattlof
These aliases are not needed in U-Boot. Remove them Tested-by: Tom Rini <[email protected]> Signed-off-by: Bryan Brattlof <[email protected]> Reviewed-by: Nishanth Menon <[email protected]>
2024-01-03arm: dts: k3-am654: remove duplicate root propertiesBryan Brattlof
With the Linux and U-Boot board dtb files unified, we have duplicate properties in the root node. Remove them Tested-by: Tom Rini <[email protected]> Signed-off-by: Bryan Brattlof <[email protected]> Reviewed-by: Nishanth Menon <[email protected]>
2024-01-03arm: dts: k3-am654: remove duplicate vtt pinmuxBryan Brattlof
With the Linux and U-Boot board dtb files unified, we now have a duplicate vtt_pinmux node. Remove it Tested-by: Tom Rini <[email protected]> Signed-off-by: Bryan Brattlof <[email protected]> Reviewed-by: Nishanth Menon <[email protected]>
2024-01-03arm: dts: k3-am654: remove duplicate mdioBryan Brattlof
With the Linux and U-Boot board dtb files unified, we now have a duplicate mdio node. Remove it Tested-by: Tom Rini <[email protected]> Signed-off-by: Bryan Brattlof <[email protected]> Reviewed-by: Nishanth Menon <[email protected]>
2024-01-03arm: dts: k3-am654: remove usb0Bryan Brattlof
The pinmux for usb0 is missing from the Linux board dtb file. Remove it until we can introduce it in Linux Tested-by: Tom Rini <[email protected]> Signed-off-by: Bryan Brattlof <[email protected]> Reviewed-by: Nishanth Menon <[email protected]>
2024-01-03arm: dts: k3-am654: remove duplicate ospi0 nodeBryan Brattlof
With the Linux and U-Boot board dtb files unified, we now have a duplicate ospi0 node. Remove it Tested-by: Tom Rini <[email protected]> Signed-off-by: Bryan Brattlof <[email protected]> Reviewed-by: Nishanth Menon <[email protected]>
2024-01-03arm: dts: k3-am654: remove duplicate wkup_i2c0Bryan Brattlof
With the Linux and U-Boot board dtb files unified, we now have a duplicate wkup_i2c0 node. Remove it Tested-by: Tom Rini <[email protected]> Signed-off-by: Bryan Brattlof <[email protected]> Reviewed-by: Nishanth Menon <[email protected]>
2024-01-03arm: dts: k3-am654: remove duplicate sdhci1 pinmux nodeBryan Brattlof
With the Linux and U-Boot board dtb files unified, we now have a duplicate sdhci1 pinmux node. Remove it Tested-by: Tom Rini <[email protected]> Signed-off-by: Bryan Brattlof <[email protected]> Reviewed-by: Nishanth Menon <[email protected]>
2024-01-03arm: dts: k3-am654: remove duplicate sdhci0 pinmux nodeBryan Brattlof
With the Linux and U-Boot board dtb files unified, we now have a duplicate sdhci0 pinmux node. Remove it Tested-by: Tom Rini <[email protected]> Signed-off-by: Bryan Brattlof <[email protected]> Reviewed-by: Nishanth Menon <[email protected]>