Javier Tia [Sun, 10 Nov 2024 08:28:39 +0000 (10:28 +0200)]
net: lwip: Add Support Server Name Indication support
SNI, or Server Name Indication, is an addition to the TLS encryption
protocol that enables a client device to specify the domain name it is
trying to reach in the first step of the TLS handshake, preventing
common name mismatch errors and not reaching to HTTPS server that
enforce this condition. Since most of the websites require it nowadays
add support for it.
It's worth noting that this is already sent to lwIP [0]
[0] https://github.com/lwip-tcpip/lwip/pull/47
Signed-off-by: Javier Tia <javier.tia@linaro.org> Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Javier Tia [Sun, 10 Nov 2024 08:28:38 +0000 (10:28 +0200)]
net: lwip: Update lwIP for mbedTLS > 3.0 support and enable https
The current code support mbedTLS 2.28. Since we are using a newer
version in U-Boot, update the necessary accessors and the lwIP codebase
to work with mbedTLS 3.6.0. It's worth noting that the patches are
already sent to lwIP [0]
While at it enable LWIP_ALTCP_TLS and enable TLS support in lwIP
[0] https://github.com/lwip-tcpip/lwip/pull/47
Signed-off-by: Javier Tia <javier.tia@linaro.org> Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Ilias Apalodimas [Sun, 10 Nov 2024 08:28:37 +0000 (10:28 +0200)]
mbedtls: Enable TLS 1.2 support
Since lwIP and mbedTLS have been merged we can tweak the config options
and enable TLS1.2 support. Add RSA and ECDSA by default and enable
enough block cipher modes of operation to be comatible with modern
TLS requirements and webservers
Reviewed-by: Raymond Mao <raymond.mao@linaro.org> Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Lad Prabhakar [Mon, 4 Nov 2024 13:50:12 +0000 (13:50 +0000)]
board: hoperun: Switch to use complete DTS files from upstream DTS
For upstream Linux kernel we use below DTBs for HiHope boards:
- r8a774a1-hihope-rzg2m-ex.dtb
- r8a774e1-hihope-rzg2h-ex.dtb
- r8a774b1-hihope-rzg2n-ex.dtb
Update the CONFIG_OF_LIST to match the above. Now that we have switched
upstream DTS, drop deleting the nodes and also rename the
r8a774*-u-boot.dtsi files to r8a774*-ex-u-boot.dtsi to match the OF_LIST
files so that the `bootph-all` property gets applied to required nodes
in upstream DTS.
Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com> Signed-off-by: Chris Paterson <chris.paterson2@renesas.com>
Chris Paterson [Mon, 4 Nov 2024 13:50:11 +0000 (13:50 +0000)]
configs: hihope_rzg2: Set correct MMC device for U-Boot env
Currently we set CONFIG_SYS_MMC_ENV_DEV=1 which is wrong:
Loading Environment from MMC... MMC: no card present
*** Warning - No block device, using default environment
This issue was introduced when we switched to using upstream Linux device
trees for the hihope boards which named the MMC devices differently.
Correct to dev 0 so that the U-Boot environment can be loaded from the
correct storage device.
Fixes: 18fb23b13158 ("ARM: dts: renesas: Switch to using upstream DT on 64bit Renesas SoCs") Signed-off-by: Chris Paterson <chris.paterson2@renesas.com> Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Paul Barker [Fri, 1 Nov 2024 14:20:16 +0000 (14:20 +0000)]
arm: renesas: Fix RZ/G2L GICR base address
When support for the Renesas RZ/G2L SoC was added, the GICR base address
for CPU1 was accidentally used. We should instead supply the GICR base
address for CPU0 so that interrupts are correctly configured for the
CPU core that U-Boot is actually using.
Fixes: 387d4275ab0e ("arm: rmobile: Add basic RZ/G2L family support") Signed-off-by: Paul Barker <paul.barker.ct@bp.renesas.com>
Paul Barker [Wed, 30 Oct 2024 10:35:43 +0000 (10:35 +0000)]
board: rzg2l: Update MAINTAINERS file to match dts/upstream paths
We are now using the dts/upstream subtree for the RZ/G2L SoC family, so
update the board MAINTAINERS file to match rz-smarc dtsi files in this
subtree.
Signed-off-by: Paul Barker <paul.barker.ct@bp.renesas.com> Reviewed-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
- Improve imx9 boot medium autodection.
- Add possibility to skip DCD on i.MX8.
- Switch to using upstream DT on DH i.MX6 DHCOM.
- Add support for i.MX6DL DHCOM SoM on PDK2 carrier board.
- Handle FIELD_RETURN on i.MX HAB.
Tom Rini [Sat, 9 Nov 2024 14:05:41 +0000 (08:05 -0600)]
Merge tag 'efi-2025-01-rc2-2' of https://source.denx.de/u-boot/custodians/u-boot-efi
Pull request efi-2025-01-rc2-2
Documentation:
* correct title and author of rst2pdf generated pdf
* describe CONFIG_DEBUG_SBI_CONSOLE
* remove vile language
UEFI
* correct printf codes in mkeficapsule
* add an EFI test app
* move default filename to a function
* move get_efi_pxe_arch() to efi_helper
* allow reporting the host defaults in efidebug
* drop sandbox PXE architecture
Other:
* do not reserve extra 16 KiB of stack in lmb
* disable the sandbox virtio blk device
* provide -N command line flag to control EFI default boot file name
on the sandbox
* provide a unit test for the efi bootmeth
Ian Ray [Fri, 8 Nov 2024 14:03:55 +0000 (16:03 +0200)]
arm: mach-imx: imx8m: re-use SNVS init routine
Working with HAB on the i.MX8MP we've encountered a case where a board
that successfully authenticates u-boot when booting Linux subsequently
fails to properly bring up the RTC.
The RTC registers live in the low-power block of the Secure Non-Volatile
Storage (SNVS) block.
The root cause of the error has been traced to the HAB handing off the
SNVS-RTC in a state where HPCOMR::NPSWA_EN = 0 in other words where the
Non-Privileged Software Access Enable bit is zero.
Configure SNVS to allow unpriv access to SNVS LP for imx8m and imx8mp.
This commit generalizes 723f8359c1 ("imx: mx7: snvs: Add an SNVS init
routine") to also be used on i.MX8M SoCs, and was testeed on i.MX8MP.
Ian Ray [Fri, 8 Nov 2024 14:03:54 +0000 (16:03 +0200)]
arm: mach-imx: move snvs module
Commit 723f8359c1 ("imx: mx7: snvs: Add an SNVS init routine") noted
that the init_snvs() call likely applies to other i.MX processors, and
this has been found to be true for i.MX8MP.
Marek Vasut [Tue, 5 Nov 2024 23:06:53 +0000 (00:06 +0100)]
ARM: dts: imx: Switch to using upstream DT on DH i.MX6 DHCOM
Enable OF_UPSTREAM to use upstream DT and add nxp/imx/ prefix to the
DEFAULT_DEVICE_TREE. And thereby directly build DTB from dts/upstream/src/
including *-u-boot.dtsi files from arch/$(ARCH)/dts/ directory.
Marek Vasut [Tue, 5 Nov 2024 23:06:52 +0000 (00:06 +0100)]
ARM: dts: imx6dl: Add support for i.MX6DL DHCOM SoM on PDK2 carrier board
Add support for the DH electronics i.MX6DL DHCOM SoM and a PDK2 evaluation
board. The evaluation board features three serial ports, USB OTG, USB host
with an USB hub, Fast or Gigabit ethernet, eMMC, uSD, SD, analog audio,
PCIe and HDMI video output.
All of the aforementioned features except for mSATA are supported, mSATA
is not available on i.MX6DL and is only available on DHCOM populated with
i.MX6Q SoC which is already supported upstream.
Backport from linux-next commit c3f5d76a6e03 ("ARM: dts: imx6dl: Add support for i.MX6DL DHCOM SoM on PDK2 carrier board")
Signed-off-by: Marek Vasut <marex@denx.de> Reviewed-by: Christoph Niedermaier <cniedermaier@dh-electronics.com> Signed-off-by: Shawn Guo <shawnguo@kernel.org>
Heiko Schocher [Mon, 4 Nov 2024 18:02:03 +0000 (19:02 +0100)]
tools: imx8image: add possibility to skip dcd
Currently U-Boot always adds DCD Image to boot container.
On imx8qxp SoC it is possible to init RAM from within SCFW,
and adding a DCD image type to the boot container in this case
breaks booting (No debug output anymore from SCFW! Nor any
output from SPL), so we need to configure a dcd skip somehow.
This patch adds a new imx8image_cmd entry CMD_DCD_SKIP and a
new entry in imximage.cfg "DCD_SKIP". If set to "true"
no DCD image type will be added to the container.
Signed-off-by: Heiko Schocher <hs@denx.de> Reviewed-by: Peng Fan <peng.fan@nxp.com>
Benjamin Szőke [Fri, 1 Nov 2024 15:26:18 +0000 (16:26 +0100)]
imx9: Improve boot mode autodetection
Improve "mmcautodetect=yes" boot mode autodetection to able to use it
if CONFIG_ENV_IS_NOWHERE=y is used for i.MX9 SoCs and i.MX93 EVK board.
If both CONFIG_ENV_IS_IN_MMC=y and CONFIG_ENV_IS_NOWHERE=y are in the
defconfig, CONFIG_ENV_IS_IN_MMC=y will be overiden default
CONFIG_ENV_IS_NOWHERE settings.
Goal is in this patch to able to use the boot mode autodetection
if defconfig use only CONFIG_ENV_IS_NOWHERE=y option
(without CONFIG_ENV_IS_IN_MMC) for any i.MX9 SoC.
Signed-off-by: Benjamin Szőke <egyszeregy@freemail.hu>
Paul Geurts [Fri, 1 Nov 2024 08:49:21 +0000 (09:49 +0100)]
imx: hab: Make imx_hab_is_enabled dependent on FIELD_RETURN
The decision on whether HAB is enabled is solely based on the SEC_CONFIG
fuse. The HAB FIELD_RETURN feature is able to permanently disable HAB on
a CPU, after which it is able to boot unsigned firmware. U-Boot however
does not take into account the FIELD_RETURN mode, and refuses to boot
unsigned software when the feature is enabled.
Also take the FIELD_RETURN fuse into account when deciding whether HAB
is enabled. When The FIELD_RETURN fuse is blown, HAB is not enabled.
Tested on i.MX8M Mini, i.MX8M Plus, i.MX8M Nano and i.MX6ULL
Signed-off-by: Paul Geurts <paul.geurts@prodrive-technologies.com>
Simon Glass [Thu, 7 Nov 2024 21:31:50 +0000 (14:31 -0700)]
test: efi: boot: Add a test for the efi bootmeth
Add a simple test of booting with the EFI bootmeth, which runs the app
and checks that it can call 'exit boot-services' (to check that all the
device-removal code doesn't break anything) and then exit back to
U-Boot.
This uses a disk image containing the testapp, ready for execution by
sandbox when needed.
Simon Glass [Thu, 7 Nov 2024 21:31:49 +0000 (14:31 -0700)]
test: efi: boot: Set up an image suitable for EFI testing
Create a new disk for use with tests, which contains the new 'testapp'
EFI app specifically intended for testing the EFI loader.
Attach it to the USB device, since most testing is currently done with
mmc.
Initially this image will be used to test the EFI bootmeth.
Fix a stale comment in prep_mmc_bootdev() while we are here.
For now this uses sudo and a compressed fallback file, like all the
other bootstd tests. Once this series is in, the patch which moves
this to use user-space tools will be cleaned up and re-submitted.
Simon Glass [Thu, 7 Nov 2024 21:31:48 +0000 (14:31 -0700)]
sandbox: virtio: Disable the sandbox virtio blk device
This is not implemented so cannot actually be used to read blocks.
Disable it until it is implemented, to avoid causing a hang with EFI,
which probes every available BLK device.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
Issue: https://source.denx.de/u-boot/u-boot/-/issues/37
Simon Glass [Thu, 7 Nov 2024 21:31:41 +0000 (14:31 -0700)]
efi_loader: Add a test app
Add a simple app to use for testing. This is intended to do whatever it
needs to for testing purposes. For now it just prints a message and
exits boot services.
There was a considerable amount of discussion about whether it is OK to
call exit-boot-services and then return to U-Boot. This is not normally
done in a real application, since exit-boot-services is used to
completely disconnect from U-Boot. For now, this part is skipped.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Moritz Fischer [Mon, 4 Nov 2024 01:49:34 +0000 (01:49 +0000)]
efi_loader: Change efi_dp_from_mem() to use size
All call sites are using size rather than end addresses,
so instead - as previously done - calculating an end address
everywhere, just modify the function to use size and internally
calculate the end address
Cc: Heinrich Schuchardt <xypron.glpk@gmx.de> Cc: Ilias Apalodimas <ilias.apalodimas@linaro.org> Cc: Patrick Wildt <pwildt@google.com> Signed-off-by: Moritz Fischer <moritzf@google.com> Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Simon Glass [Mon, 28 Oct 2024 12:47:59 +0000 (13:47 +0100)]
lmb: Drop extra 16KB of stack space
There is already a defined stack-size which is used to reserve space for
the stack. It is confusing to add more in the lmb module, since then the
memory map (with meminfo command) seems to have a hole in it.
Michal Simek [Fri, 1 Nov 2024 09:50:45 +0000 (10:50 +0100)]
riscv: Introduce configuration for 64bit version Microblaze V
The commit 7576ab2facae ("riscv: Add support for AMD/Xilinx MicroBlaze V")
added support for 32bit version. 64bit version is also available that's why
wire it up too.
DT is providing description for generic QEMU target.
Signed-off-by: Michal Simek <michal.simek@amd.com> Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com>
Yuri Zaporozhets [Wed, 30 Oct 2024 19:38:20 +0000 (20:38 +0100)]
bios_emulator: fix first argument of pci_{read,write}_config_* function calls
When compiling for riscv64, a bunch of warning is produced for the file
drivers/bios_emulator/besys.c. This patch fixes a portion of those warnings,
caused by incorrect first argument to pci_{read,write}_config_* functions.
Yuri Zaporozhets [Wed, 30 Oct 2024 13:00:51 +0000 (14:00 +0100)]
bios_emulator: define the comment symbol for RISC-V assembler too
The bios_emulator driver cannot be compiled for RISC-V because the x86emu.h
header file doesn't define the comment symbol ("#") for the assembler.
With this patch, use the same symbol as for e.g. x86.
Weijie Gao [Tue, 29 Oct 2024 09:47:16 +0000 (17:47 +0800)]
menu: add support to check if menu needs to be reprinted
This patch adds a new callback named need_reprint for menu.
The need_reprint will be called before printing the menu. If the
callback exists and returns FALSE, menu printing will be canceled.
This is very useful if the menu was not changed. It can save time
for serial-based menu to handle more input data.
Signed-off-by: Weijie Gao <weijie.gao@mediatek.com> Reviewed-by: Daniel Golle <daniel@makrotopia.org> Tested-by: Daniel Golle <daniel@makrotopia.org>
Weijie Gao [Tue, 29 Oct 2024 09:47:10 +0000 (17:47 +0800)]
menu: fix the logic checking whether ESC key is pressed
It's observed that the bootmenu on a serial console sometimes
incorrectly quitted with superfluous characters filled to command
line input:
> *** U-Boot Boot Menu ***
>
> 1. Startup system (Default)
> 2. Upgrade firmware
> 3. Upgrade ATF BL2
> 4. Upgrade ATF FIP
> 5. Load image
> 0. U-Boot console
>
>
> Press UP/DOWN to move, ENTER to select, ESC to quit
>MT7988> [B
Analysis shows it was caused by the wrong logic of bootmenu_loop:
At first the bootmenu_loop received the first ESC char correctly.
However, during the second call to bootmenu_loop, there's no data
in the UART Rx FIFO. Due to the low baudrate, the second char of
the down array key sequence hasn't be fully received.
But bootmenu_loop just did a mdelay(10), and then treated it as a
single ESC key press event. It didn't even try tstc() again after
the 10ms timeout.
This patch fixes this issue by letting bootmenu_loop check tstc()
twice.
Tested-By: E Shattow <lucent@gmail.com> Signed-off-by: Weijie Gao <weijie.gao@mediatek.com> Reviewed-by: Daniel Golle <daniel@makrotopia.org> Tested-by: Daniel Golle <daniel@makrotopia.org> Reviewed-by: Simon Glass <sjg@chromium.org>
Tom Rini [Mon, 4 Nov 2024 21:40:54 +0000 (15:40 -0600)]
Merge patch series "U-boot: arm: Refine the booting on Total Compute"
Leo Yan <leo.yan@arm.com> says:
This patch series is to refine the booting on Arm Total Compuate
platform.
It changes to use the info passed in DTB for initialization DRAM info,
and dynamically initializes the booting envoironment variables.
Another big change is to use an envoironment file for boot commands,
based on it, the series extends to support multiple block devices
(MMC and virtio). And the env file is extended for booting Debian.
The last commit is to update memory mapping info based on the DRAM info
passed via DT binding.
Leo Yan [Fri, 25 Oct 2024 17:18:21 +0000 (18:18 +0100)]
arm: total_compute: Update memory mapping info
This commit introduces build_mem_map() function for updating the mem_map
structure with copying info from gd->bd->bi_dram, so that it can keep
the consistence for DRAM info passed via DT.
The page table size is calculated prior to mem_map is ready, introduce
the get_page_table_size() function for a predefined table size.
Initialize the environment variables 'fdt_addr_r' and 'kernel_addr_r'
during the misc init phase. The static configurations are not needed,
remove them.
Signed-off-by: Boyan Karatotev <boyan.karatotev@arm.com> Signed-off-by: Leo Yan <leo.yan@arm.com>
Boyan Karatotev [Fri, 25 Oct 2024 17:18:14 +0000 (18:18 +0100)]
arm: total_compute: depend on TF-A for hardware description
On Total Compute, TF-A passes the info via DT binding for the hardware
description - includes the serial, memory, and arm_ffa nodes.
This commit initializes the fdt base address based on the passed the
register x1.
The similar implementation has already been done for the raspberry pi,
so borrow a lot of it.
Co-developed-by: Jackson Cooper-Driver <jackson.cooper-driver@arm.com> Signed-off-by: Jackson Cooper-Driver <jackson.cooper-driver@arm.com> Signed-off-by: Boyan Karatotev <boyan.karatotev@arm.com> Signed-off-by: Leo Yan <leo.yan@arm.com>
Tom Rini [Mon, 4 Nov 2024 20:49:10 +0000 (14:49 -0600)]
Merge patch series "Fixes to allow 'ut bootm' to pass when run interactively"
Andrew Goodbody <andrew.goodbody@linaro.org> says:
Starting a sandbox session and running 'ut bootm' on the command
line instead of using pytest with --verbose will result in some
test failures. This series makes the tests more deterministic so
that they will better control their environment and hence will
work as expected whether or not they are invoked with '--verbose'.
The series starts with a small fix to the parameters of
bootm_process_cmdline that one commit incorrectly added using a bool
when it had been updated to take flags by the preceeding commit.
Andrew Goodbody [Fri, 1 Nov 2024 13:02:54 +0000 (13:02 +0000)]
test: bootm: Ensure GD_FLG_SILENT is reset
Some bootm tests expect that GD_FLG_SILENT is reset in order
to work as expected. This is the state if the test is run with
'pytest --verbose' but not if run from, say, the sandbox command
line.
So reset the flag for those tests that rely on it being reset. This
has to be done in each test as the test infrastructure will set it
again before every test when not invoked with 'pytest --verbose'.
Signed-off-by: Andrew Goodbody <andrew.goodbody@linaro.org>
The function bootm_process_cmdline_env takes flags as its third
parameter, not a bool. Correct the usage by replacing 'true'
with BOOTM_CL_ALL so that the intent is clear.
A similar change was made throughtout this file in the previous
commit to the one mentioned below as being fixed.
Fixes: 4448fe8e4e7c ("bootm: Allow updating the bootargs in a buffer") Signed-off-by: Andrew Goodbody <andrew.goodbody@linaro.org>
Andrew Goodbody [Tue, 15 Oct 2024 14:17:37 +0000 (15:17 +0100)]
usb: Fix test dependency on ext4write command
The tests test_usb_ext4load_ext4write, test_usb_ext2load and
test_usb_load depend on the command ext4write being present not just
the feature of being able to write to an ext4 file system. So update
their dependencies to include the ext4write command itself. This will
prevent spurious test failures when running the USB tests against USB
storage with an ext2/ext4 partition but no ext4write command available.
Fixes: 1c5b6edad381 ("test/py: usb: Add tests for USB device") Signed-off-by: Andrew Goodbody <andrew.goodbody@linaro.org> Reviewed-by: Love Kumar <love.kumar@amd.com>
Andrew Goodbody [Tue, 15 Oct 2024 12:19:16 +0000 (13:19 +0100)]
usb: Fix test failure with multiple partitions
When test_usb_load finds multiple partitions of the same type then
it will cause a test failure. The call to write the test file will
write a different test file to each partition but only return the
name and size of the last one written. So the test then fails to
load the test file from the first partition as it uses the name of
a file on a different partition.
Refactor the code so that only one test file is written at a time
and is written to only the partition being tested at that time. This
allows the correct file name to always be available to the code that
runs the load command. This reduces the number of files written and
also the number of calls to crc32 needed.
Fixes: 1c5b6edad381 ("test/py: usb: Add tests for USB device") Signed-off-by: Andrew Goodbody <andrew.goodbody@linaro.org> Reviewed-by: Love Kumar <love.kumar@amd.com>
Simon Glass [Mon, 28 Oct 2024 12:47:53 +0000 (13:47 +0100)]
test: Allow saving and restoring the bloblist
Tests which create a new bloblist overwrite the existing one in sandbox.
Provide a flag for tests to declare this behaviour. Save and restore the
bloblist pointer so that other tests remain unaffected.
Note that when sandbox is running normally, the bloblist has been
relocated to high in memory. The existing bloblist tests create a new
bloblist low in memory, so they do not conflict.
Correct a build error on coreboot by using accessors for gd->bloblist: Signed-off-by: Simon Glass <sjg@chromium.org>
Jonas Karlman [Sat, 3 Aug 2024 12:41:45 +0000 (12:41 +0000)]
bootstage: Do not sort records
The timer counter on Rockchip SoCs may be reset in TF-A, this may cause
the bootstage records to be printed out of order and with an incorrect
elapsed time.
For the tested board external TPL and BROM take ~164 ms to initialize
DRAM and load SPL, SPL take ~210ms to load images from FIT and U-Boot
proper take ~477ms to reach cli prompt.
Simon Glass [Sat, 19 Oct 2024 15:21:56 +0000 (09:21 -0600)]
test: Expand implementation of ut_list_has_dm_tests()
This function assumes that all tests in a suite are being run. This
means that it can sometimes call dm_test_restore() when it should not.
The impact of this is that it is not possible, for example, to run
'ut bootstd bootflow_cros' and then check the state of bootstd
afterwards, since all devices are removed and recreated.
Update the function to take account of any selected test, to avoid this
problem.
Simon Glass [Sat, 19 Oct 2024 15:21:50 +0000 (09:21 -0600)]
test: boot: Use a consistent name for the script bootmeth
In the bootflow tests the script bootmeth is bound with the name
bootmeth_script whereas the others have a name without the bootmeth_
prefix. Adjust it to be the same.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
Simon Glass [Sat, 19 Oct 2024 15:21:47 +0000 (09:21 -0600)]
alist: Add a way to efficiently filter an alist
Unlike linked lists, it is inefficient to remove items from an alist,
particularly if it is large. If most items need to be removed, then the
time-complexity approaches O(n2).
Provide a way to do this efficiently, by working through the alist once
and copying elements down.
Marek Vasut [Sun, 27 Oct 2024 02:20:07 +0000 (03:20 +0100)]
ARM: renesas: Deduplicate common Renesas defconfig
Deduplicate common Renesas defconfig by factoring out the common
parts into generic renesas_rcar_defconfig and including those using
the #include <configs/...> preprocessor macro in the current set of
board specific defconfigs. The preprocessor macro is applicable
to defconfigs as well.
This introduces no functional change, the resulting .config are
identical for all Renesas systems.
Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Deduplicate defconfigs for all Renesas R-Car 64bit systems by factoring
out the common parts into generic renesas_rcar64.config and including
those using the #include <configs/...> preprocessor macro in the current
set of board specific defconfigs. The preprocessor macro is applicable
to defconfigs as well.
This introduces no functional change, the resulting .config is identical
for all Renesas R-Car 64bit systems.
Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Deduplicate defconfigs for all Renesas R-Car Gen4 systems by factoring
out the common parts into generic renesas_rcar4.config and including
those using the #include <configs/...> preprocessor macro in the current
set of board specific defconfigs. The preprocessor macro is applicable
to defconfigs as well.
This introduces no functional change, the resulting .config is identical
for all Renesas R-Car Gen4 systems.
Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Deduplicate defconfigs for all Renesas R-Car Gen3 systems by factoring
out the common parts into generic renesas_rcar3.config and including
those using the #include <configs/...> preprocessor macro in the current
set of board specific defconfigs. The preprocessor macro is applicable
to defconfigs as well.
This introduces no functional change, the resulting .config is identical
for all Renesas R-Car Gen3 systems.
Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Deduplicate defconfigs for all Renesas R-Car Gen2 systems by factoring
out the common parts into generic renesas_rcar2.config and including
those using the #include <configs/...> preprocessor macro in the current
set of board specific defconfigs. The preprocessor macro is applicable
to defconfigs as well.
This introduces no functional change, the resulting .config is identical
for all Renesas R-Car Gen2 systems.
Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Marek Vasut [Wed, 4 Sep 2024 22:34:20 +0000 (00:34 +0200)]
clk: renesas: Fix missing unbind on driver look up failure
In case lists_driver_lookup_name("rst_gen3") fails, the clk_gen3 driver
has to be unbound before erroring out. Reorder the function such that
both clk_gen3 and rst_gen3 drivers are looked up first, if either look
up fails then the function errors out right away. Second, the clk_gen3
is bound, if binding fails, the function still errors out right away
because there is nothing to undo after either lists_driver_lookup_name()
call. Finally, rst_gen3 is bound and if this binding fails, then that
is the only place where clk_gen3 has to be unbound before erroring out.
Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Tom Rini [Fri, 1 Nov 2024 19:38:05 +0000 (13:38 -0600)]
Merge patch series "fs: ext4: implement opendir, readdir, closedir"
Heinrich Schuchardt <heinrich.schuchardt@canonical.com> says:
With this series opendir, readdir, closedir are implemented for ext4.
These functions are needed for the UEFI sub-system to interact with
the ext4 file system.
To reduce code growth the functions are reused to implement the ls
command for ext4.
A memory leak in ext4fs_exists is resolved.
ext4fs_iterate_dir is simplified by removing a redundant pointer copy.
Now that opendir, readir, closedir are implemented for ext4 we can use
fs_ls_generic() for implementing the ls command.
Adjust the unit tests:
* fs_ls_generic() produces more spaces between file size and name.
* The ext4 specific message "** Can not find directory. **\n" is not
written anymore.
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Reviewed-by: Simon Glass <sjg@chromium.org>