summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2024-09-19imx9: clock: Update clock init function and sequenceYe Li
Since we use SPEED GRADE fuse to set A55 frequency, remove the set_arm_core_low_drive_clk function which has hard coded frequency. And adjust clock_init called sequence and split it to early and late functions. Set the authen register in early function, because CCF driver checks NS bit. Set bus and core clock in late function, because the fuse read and SoC type/rev depend on ELE. Reviewed-by: Peng Fan <peng.fan@nxp.com> Signed-off-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com>
2024-09-19imx9: soc: Add function to get target voltage modeYe Li
Replace the static CONFIG_IMX9_LOW_DRIVE_MODE with runtime target voltage mode by checking the part's SPEED GRADE fuse. SPL will configure to highest A55 speed which is indicated by the SPEED fuse and select corresponding voltage mode. Reviewed-by: Peng Fan <peng.fan@nxp.com> Signed-off-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com>
2024-09-19imx9: soc: Print ELE informationPeng Fan
The boot image includes Edgelock Enclave(ELE) Firmware. Print the information out to let user know which version firmware is being used. Signed-off-by: Peng Fan <peng.fan@nxp.com>
2024-09-19imx9: soc: Change second Ethernet MAC fuse layoutYe Li
The second Ethernet MAC (eQOS) fuse layout is changed since i.MX93 A1 following other i.MX platforms, for example i.MX8MP. Order for A0: MAC1_ADDR[15:0] MAC1_ADDR[31:16] MAC1_ADDR[47:32] MAC2_ADDR[47:32] MAC2_ADDR[15:0] MAC2_ADDR[31:16] Order since A1: MAC1_ADDR[15:0] MAC1_ADDR[31:16] MAC1_ADDR[47:32] MAC2_ADDR[15:0] MAC2_ADDR[31:16] MAC2_ADDR[47:32] Signed-off-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com>
2024-09-19imx9: soc: Change FSB directly access to fuse APIPeng Fan
To support OSCCA enabled part which has disabled FSB access from SOC, change directly read from FSB to use fuse_read API. Signed-off-by: Peng Fan <peng.fan@nxp.com>
2024-09-19imx9: soc: Print UID in big endian format for EL2GOYe Li
Print UID in big endian format and as one buffer of bytes, so customer can directly use it for EdgeLock 2GO. Before: UID: 0xf6c8ae93 0x0f46b326 0x10d61eb3 0x0583c2d2 Become: UID: 93aec8f626b3460fb31ed610d2c28305 Signed-off-by: Ye Li <ye.li@nxp.com> Reviewed-by: Peng Fan <peng.fan@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com>
2024-09-19imx9: soc: imx9: soc: Align UID endianness with ROMFrank Li
ROM use UID[0] and UID[1] as serial number with big endian when usb serial download. After update this, uuu(>1.6) can use below command to filter out devices when multi boards connected. uuu -ms <serial#> ... [sudo] uuu -lsusb can list known devices with serial# informaiton. Signed-off-by: Frank Li <Frank.Li@nxp.com> Reviewed-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com>
2024-09-19imx9: soc: Configure TRDC for M33 TCM accessYe Li
On OSCCA part, M33 TCM is used for ROM PATCH and protected by ELE ROM. So after release TRDC, we need to configure TRDC for M33 TCM, otherwise A55 can't access the TCM. Reviewed-by: Peng Fan <peng.fan@nxp.com> Signed-off-by: Ye Li <ye.li@nxp.com>
2024-09-19imx9: soc: wait ssar when power on power domainPeng Fan
SSAR handshake done means power on finished, not ISO done. so correct the waiting mask. Fixes: 0256577a83b ("imx: imx9: Add MIX power init") Signed-off-by: Peng Fan <peng.fan@nxp.com>
2024-09-18Merge patch series "Fix various bugs"Tom Rini
Simon Glass <sjg@chromium.org> says: This series includes the patches needed to make make the EFI 'boot' test work. That test has now been split off into a separate series along with the EFI patches. This series fixes these problems: - sandbox memory-mapping conflict with PCI - the fix for that causes the mbr test to crash as it sets up pointers instead of addresses for its 'mmc' commands - the mmc and read commands which cast addresses to pointers - a tricky bug to do with USB keyboard and stdio - a few other minor things
2024-09-18test: mbr: Drop a duplicate testSimon Glass
The test currently runs twice as it is declared twice. Unwind this. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18test: mbr: Use RAM for the buffersSimon Glass
The normal approach with sandbox is to use a fixed memory address in the RAM, to avoid needing to create a map for transient local variables. Update this test to use this approach. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18test: mbr: Use a constant for the block sizeSimon Glass
It isn't that important to factor out constants in tests, but in this case we have 0x200 and 512 used. The commands don't use the constant as they use a block count ('1'). It doesn't create more code to use a constant, so create one. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18test: mbr: Unmap the buffers after useSimon Glass
This tests maps some local variables into sandbox's address space. Make sure to unmap them afterwards. Note that the normal approach with sandbox is to use a fixed memory address in the RAM, to avoid needing to create a map for transient local variables. Signed-off-by: Simon Glass <sjg@chromium.org> Fixes: 04291ee0aba ("cmd: mbr: Allow 4 MBR partitions without need...")
2024-09-18cmd: Fix memory-mapping in cmp commandSimon Glass
This unmaps a different address from what was mapped. Fix it. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18read: Tidy up use of map_sysmem() in the read commandSimon Glass
Rename the variable to 'ptr' since it is a pointer, not an address. Make sure to unmap the pointer. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18mmc: Use map_sysmem() with buffers in the mmc commandSimon Glass
The current implementation casts an address to a pointer. Make it more sandbox-friendly by using map_sysmem(). Rename the variable to 'ptr' since it is a pointer, not an address. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18sandbox: Implement reference counting for address mappingSimon Glass
An address may be mapped twice and unmapped twice. Delete the mapping only when the last user unmaps it. Fix a missing comment while here. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18sandbox: Add some debugging to pci_ioSimon Glass
Add a little debugging to this driver. Convert the existing debugging to use logging. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18sandbox: Unmap old tagsSimon Glass
So far unmapping has not been implemented. This means that if one test maps a pointer to an address with map_sysmem(), then a second test can use that same pointer, by mapping the address back to a pointer with map_to_sysmem(). This is not really desirable, even if it doesn't cause any problems at the moment. Implement unmapping, to clean this up. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18sandbox: Update cpu to use loggingSimon Glass
Use log_debug() instead of including the function name in the string. Add one more debug for PCI. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18sandbox: Change the range used for memory-mapping tagsSimon Glass
Sandbox keeps a table of addresses which map to pointers which are outside its emulated DRAM. The current range from 10000000 conflicts with the PCI range, meaning that if PCI mapping is on, that particular address can be decoded by PCI instead of the table. Fix this by moving the range up to the top of memory. Update the docs while we are here. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18test: mbr: Adjust test to drop 0xSimon Glass
U-Boot commands typically don't need 0x to specify hex, since they use hex by default. Adding 0x in this test is confusing since it suggests that it is necessary. Drop it from the file. Also use the %#x construct to get the 0x when needed. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18test: mbr: Adjust test to use lower-case hexSimon Glass
Switch to lower-case hex which is more commonly used in U-Boot. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18dm: usb: Deal with USB keyboard persisting across testsSimon Glass
Clear any USB-keyboard devices before running a unit test, to avoid using a stale udevice pointer in stdio. Add a long comment to explain this situation and why this solution seems best, at least for now. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18usb: Add DEV_FLAGS_DM to stdio for USB keyboardSimon Glass
This device contains a pointer to struct udevice so set the flag indicating that, just to be tidy. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18log: Add a new log category for the consoleSimon Glass
Add a new category which covers the console, including the stdio drivers. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18usb: Drop old non-DM codeSimon Glass
The driver model deadline for USB was in 2019, so drop the old USB keyboard code, to avoid needing to deal with the extra code path. Drop the unnecessary #ifdef around USB_KBD_BOOT_REPORT_SIZE while we are here. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18bootstd: Create a function to reset USBSimon Glass
Set up a function for this, since it needs to be used from multiple test files. This test file is only used on sandbox, where USB is enabled, so drop the local declaration of usb_started Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18scripts: Update pylint.baseSimon Glass
There have been quite a few changes in the Python scripts, so update the pylint baseline. This was created using: make pylint cp pylint.cur scripts/pylint.base Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18test/py: Fix some pylint warnings in test_ut.pySimon Glass
Tidy up most of these warnings. Remaining are four of these: R0914: Too many local variables which can only by fixed by splitting things into functions, so that is left for another time. Part of this change was done by the flynt tool. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18nvmxip: Avoid probing on bootSimon Glass
Devices should be probed when they are used, not before. Drop this boot-time probing. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-18nvmxip: Drop the message on probeSimon Glass
We should not need to announce this device. Drop the message. Signed-off-by: Simon Glass <sjg@chromium.org>
2024-09-16cmd: osd: Depend on OSDMarek Vasut
The OSD command calls functions from video_osd-uclass.o , which is built only when CONFIG_OSD is enabled. Add the missing dependency into Kconfig. Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2024-09-16cmd: mmc: Allow using partition name in mmc erase commandTomas Paukrt
The mmc erase command currently requires blk# and cnt parameters which can be obtained using the part start and part size commands if the entire partition needs to be erased. Simplify the use of the mmc erase command by allowing the partition name to be specified directly. Signed-off-by: Tomas Paukrt <tomaspaukrt@email.cz> Reviewed-by: Quentin Schulz <quentin.schulz@cherry.de>
2024-09-16mmc: Hide mmc speed command under mmc commandMarek Vasut
The mmc speed command configuration option keeps showing up in Kconfig directly in 'Command line interface'. Move MMC_SPEED_MODE_SET under CMD_MMC to make it show up alongside the MMC command. Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org> Reviewed-by: Quentin Schulz <quentin.schulz@cherry.de> Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
2024-09-16Merge patch series "Arm: npcm: modify npcm8xx boot setting"Tom Rini
Jim Liu <jim.t90615@gmail.com> says: Modify npcm8xx new boot design. Correct memory setting and set gpio default value.
2024-09-16pinctrl: npcm8xx: clear all gpio eventsStanley Chu
Clear all gpio events to avoid unexpected interrupts during kernel booting. Signed-off-by: Stanley Chu <yschu@nuvoton.com>
2024-09-16configs: arbel_evb: change env offset and boot addressJim Liu
Change env offset and boot address for new design. Signed-off-by: Jim Liu <JJLIU0@nuvoton.com>
2024-09-16board: arbel: correct the dram bank sizeJim Liu
If CONFIG_SYS_MEM_TOP_HIDE is defined, gd->ram_size is reduced by CONFIG_SYS_MEM_TOP_HIDE. Need to correct the actual ram size in dram_init_banksize. Signed-off-by: Jim Liu <JJLIU0@nuvoton.com>
2024-09-16drivers/crypto: aspeed: Add Caliptra SHA ACC supportChia-Wei Wang
Aspeed AST27xx SoCs integrate the CPTRA 1.0 secure IP, which export a SHA accelerator interface for SoC to use. Note that CPTRA 1.0 supports only SHA384 and SHA512 and this patch is verified by the 'hash test sha384/sha512' commands. Signed-off-by: Chia-Wei Wang <chiawei_wang@aspeedtech.com>
2024-09-16Merge tag 'v2024.10-rc5' into nextTom Rini
Prepare v2024.10-rc5
2024-09-16Prepare v2024.10-rc5v2024.10-rc5Tom Rini
Signed-off-by: Tom Rini <trini@konsulko.com>
2024-09-16doc/develop/sending_patches.rst: Reword where our git tree is slightlyTom Rini
We shouldn't have had the link to our git tree be contained within "``" as that meant that it did not work as a link, so remove those. And rather than make this a link plus text, keep this as a link within the text for overall clarity. Suggested-by: Quentin Schulz <quentin.schulz@cherry.de> Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org> Reviewed-by: Quentin Schulz <quentin.schulz@cherry.de> Signed-off-by: Tom Rini <trini@konsulko.com>
2024-09-13Merge patch series "Bump new hush commits and fix old hush test behavior"Tom Rini
Francis Laniel <francis.laniel@amarulasolutions.com> says: Hi! With this series, I bumped the new hush to get the latest commits from upstream. Also, I added back a reverted commit which goal was to fix a bad behavior in old hush test. I had to tweak a bit this commit, but everything worked both locally and in the CI.
2024-09-13cli: modern_hush: Add upstream commits up to 13 July 2024Francis Laniel
This commit adds the following hush busybox upstream commits: 23da5c4b716b ("hush: do not exit interactive shell on some redirection errors") 14e28c18ca1a ("hush: fix "exec 3>FILE" aborting if 3 is exactly the next free fd") 6c38d0e9da2d ("hush: avoid duplicate fcntl(F_SETFD, FD_CLOEXEC) during init") 758b21402abc ("hush: detect when terminating "done"/"fi" is missing") 2639f3bc72ac ("hush: set G.ifs sooner (prevents segfault)") Adding specific ifdef and endif guard was needed for 2639f3bc72ac. Signed-off-by: Francis Laniel <francis.laniel@amarulasolutions.com>
2024-09-13test: hush: dollar: fix bugous behaviorIon Agorria
The dollar test was merged with bugous console behavior, and instead of fixing it, this behavior was just workarounded. This was done to keep compatibility with the existing behavior. It seems like without the fix the ut_assert_skipline(); didn't clear console and running ut_assert_skipline(); many times would give always OK. With e58bafc35fe3 ("lib: membuff: fix readline not returning line in case of overflow") the line is cleared correctly and next assert fails because now there is nothing to clean which is correct if we look the this a bit above the failing assert: if (gd->flags & GD_FLG_HUSH_MODERN_PARSER) { /* * For some strange reasons, the console is not empty after * running above command. * So, we reset it to not have side effects for other tests. */ console_record_reset_enable(); } else if (gd->flags & GD_FLG_HUSH_OLD_PARSER) { ut_assert_console_end(); } Which further confirms that tests workaround the old problem and now that problem is fixed we can remove the whole if blocks and simply place ut_assert_console_end() right after ut_assert_skipline() without any conditional and will pass green. So this part of code goes from: ut_assert_skipline(); ut_assert_skipline(); if (gd->flags & GD_FLG_HUSH_MODERN_PARSER) { /* See above comments. */ console_record_reset_enable(); } else if (gd->flags & GD_FLG_HUSH_OLD_PARSER) { ut_assert_console_end(); } to become: ut_assert_skipline(); if (gd->flags & GD_FLG_HUSH_OLD_PARSER) { ut_assert_skipline(); } ut_assert_console_end(); The if block mentioned above that calls console_record_reset_enable() is completely removed as fixed by e58bafc35fe3. [flaniel: adapt second if] Signed-off-by: Ion Agorria <ion@agorria.com> Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com> Tested-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Link: https://lore.kernel.org/r/20240105072212.6615-8-clamor95@gmail.com [mkorpershoek: reworded commit title] Signed-off-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> [flaniel: remove console_record_reset_enable() if] Signed-off-by: Francis Laniel <francis.laniel@amarulasolutions.com>
2024-09-13Merge tag 'efi-next-20241024' of ↵Tom Rini
https://source.denx.de/u-boot/custodians/u-boot-efi into next Pull request efi-next-20241024 UEFI: * Use generated UUIDs in UEFI capsules: - efi: define struct efi_guid - lib: uuid: add UUID v5 support - efi: add a helper to generate dynamic UUIDs - doc: uefi: document dynamic UUID generation - sandbox: switch to dynamic UUIDs - lib: uuid: supporting building as part of host tools - include: export uuid.h - tools: mkeficapsule: use u-boot UUID library - tools: mkeficapsule: support generating dynamic GUIDs - test: lib/uuid: add unit tests for dynamic UUIDs - test: lib/uuid: add tests for UUID version/variant bits * Minor code clean-up - shorten efi_bootmgr_release_uridp_resource() - rename efi_bootmgr_image_return_notify - return the correct error in efi_bootmgr_release_uridp() - Kconfig: clean up the efi configuration status - Use puts() in cout so that console recording works - Put back copyright message in helloworld.c
2024-09-13Merge tag 'doc-2024-10-rc4' of ↵Tom Rini
https://source.denx.de/u-boot/custodians/u-boot-efi Pull request doc-2024-10-rc4 * doc/develop/sending_patches.rst: Clarify when to use which branch * doc/arch/m68k.rst: Update toolchain comment * doc/arch/mips.rst: Update toolchain list * doc: Update rST to not reference the old wiki * doc/mkeficapsule.1: Update homepage link * bootcount: Update to point to current documentation * binman: Update links for sending patches
2024-09-12binman: Update links for sending patchesTom Rini
When linking to our documentation for submitting patches, we shouldn't point at the old wiki but instead our current documentation. Signed-off-by: Tom Rini <trini@konsulko.com>