Re: [PATCH v2 2/2] power: pmic: fix regulators behaviour

2023-07-15 Thread Svyatoslav Ryhel
16 липня 2023 р. 02:40:37 GMT+03:00, Simon Glass написав(-ла): >Hi Svyatoslav, > >On Sat, 15 Jul 2023 at 12:34, Svyatoslav Ryhel wrote: >> >> Currently device tree entries of regulators are completely >> ignored and regulators are probed only if they are called >> by the device which uses it.

Re: [PATCH v2 0/2] power: pmic: add TPS65913 support

2023-07-15 Thread Svyatoslav Ryhel
16 липня 2023 р. 02:37:39 GMT+03:00, Jonas Karlman написав(-ла): >On 2023-07-15 20:34, Svyatoslav Ryhel wrote: >> Existing PALMAS PMIC driver is fully compatible with TI TPS65913 >> PMIC found in many Tegra 4 devices, like Tegra Note 7 and ASUS >> TF701T. Add TPS65913 dts compatible with TPS65

[PATCH v5 45/46] x86: video: Add a driver for QEMU bochs emulation

2023-07-15 Thread Simon Glass
Bochs is convenient with QEMU on x86 since it does not require a video BIOS. Add a driver for it. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v2) Changes in v2: - Bring in to qemu series - Rebase to -next - Drop unused of_match - Fix Boschs typo - Rename bochs_init_l

[PATCH v5 46/46] x86: Switch QEMU over to use the bochs driver

2023-07-15 Thread Simon Glass
This is more convenient since it does not require a video BIOS. Enable it for QEMU. Also drop use of video in SPL for the 64-bit QEMU, since it not needed now. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- Changes in v5: - Use QEMU instead of qemu - Drop patch 'Show the number of physic

[PATCH v5 44/46] efi: Use the installed ACPI tables

2023-07-15 Thread Simon Glass
U-Boot sets up the ACPI tables during startup. Rather than creating a new set, install the existing ones. Create a memory-map record to cover the tables. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v4) Changes in v4: - Drop patch "video: Allow building video drivers

[PATCH v5 43/46] sandbox: Install ACPI tables on startup

2023-07-15 Thread Simon Glass
With x86 we set up the ACPI tables on startup so they can be examined. Do the same with sandbox, so it is consistent. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) board/sandbox/sandbox.c | 16 1 file changed, 16 insertions(+) diff --git a/board/

[PATCH v5 42/46] sandbox: Correct header order in board file

2023-07-15 Thread Simon Glass
Fix the header order in this file. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) board/sandbox/sandbox.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/board/sandbox/sandbox.c b/board/sandbox/sandbox.c index c7b6cb78fff5..54c119daeeeb 10

[PATCH v5 41/46] log: Support outputing function names in SPL

2023-07-15 Thread Simon Glass
The output is garbled when tiny printf() is used. Correct this by adding a special case. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v2) Changes in v2: - Add new patch to support outputing function names in SPL common/log_console.c | 10 -- 1 file changed,

[PATCH v5 40/46] x86: Make sure that the LPC is active before SDRAM init

2023-07-15 Thread Simon Glass
Some boards need to access GPIOs to determine which SDRAM is fitted to the board, for example chromebook_link. Probe this device (if it exists) to make sure that this works as expected. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v2) Changes in v2: - Add new patch to

[PATCH v5 38/46] x86: Convert some debug statements to use logging

2023-07-15 Thread Simon Glass
Move from using debug() to log_debug() so that we don't have to use the __func__ parameter and can access other logging features. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- Changes in v5: - Use "gpio" for log return Changes in v2: - Add new patch to convert some debug statements to u

[PATCH v5 39/46] x86: link: Support Micron memory

2023-07-15 Thread Simon Glass
Add the required tag so that micron memory can be set up correctly. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v2) Changes in v2: - Add new patch to support Micron memory arch/x86/dts/chromebook_link.dts | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/x86

[PATCH v5 37/46] x86: Record the start and end of the tables

2023-07-15 Thread Simon Glass
The ACPI tables are special in that they are passed to EFI as a separate piece, independent of other tables. Also they can be spread over two areas of memory, e.g. with QEMU we end up with tables kept in high memory as well. Add new global_data fields to hold this information and update the bdinf

[PATCH v5 36/46] x86: Refactor table-writing code a little

2023-07-15 Thread Simon Glass
The implementation of write_tables() is confusing because it uses the rom_table_start variable as the address pointer as it progresses. Rename it to rom_addr to make the code clearer. Move the rom_table_end variable into the block where it is used. Also update logging to use the ACPI category, no

[PATCH v5 34/46] fs: fat: Support reading from a larger block size

2023-07-15 Thread Simon Glass
At present it is not possible to read from some CDROM drives since the FAT sector size does not match the media's block size. Add a conversion option for this, so that reading is possible. This does increase SPL size for read-only FAT support by 25 bytes but all but 6 are covered by the previous p

[PATCH v5 35/46] x86: Enable useful options for qemu-86_64

2023-07-15 Thread Simon Glass
This build can be used to boot standard distro builds, since these are mostly 64-bit these days. Enable some more options, so that all possible EFI UUIDs are decoded, we get a proper printf() in SPL, can search memory for tables, support the full set of standard-boot features, have full logging and

[PATCH v5 33/46] fs: fat: Shrink the size of a few strings

2023-07-15 Thread Simon Glass
To save a few bytes, replace Error with ** and try to use the same string for multiple messages where possible. Reviewed-by: Bin Meng Signed-off-by: Simon Glass --- (no changes since v2) Changes in v2: - Drop ** in strings and use log_err() for messages fs/fat/fat.c | 20 +++---

[PATCH v5 32/46] x86: Allow logging to be used in SPL reliably

2023-07-15 Thread Simon Glass
When global_data is relocated, log_head moves in memory, meaning that the items in that list point to the wrong place. Disable logging when making the change, then reenable it afterwards, so that logging works normally. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1)

[PATCH v5 31/46] x86: Enable display for QEMU 64-bit

2023-07-15 Thread Simon Glass
Enable the various options needed for display to work on the qemu-x86_64 board. This includes expanding the available malloc() memory in SPL, since the PCI bus must be enumerated in order to find the video device. It also includes enabling a bloblist, so that the video parameters can be passed. Th

[PATCH v5 30/46] pci: Mask the ROM address in case it is already enabled

2023-07-15 Thread Simon Glass
In some cases the video ROM may have been enabled previously, such as by a previous firmware stage. Use the correct address in that case. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) drivers/pci/pci_rom.c | 1 + 1 file changed, 1 insertion(+) diff --git a/driver

[PATCH v5 29/46] pci: Adjust video BIOS debugging to be SPL-friendly

2023-07-15 Thread Simon Glass
A hex value is expected for the VGA mode. Add a 0x prefix, since the # construct is not supported in SPL. We don't want to add it, due to code-size constraints. Signed-off-by: Simon Glass --- (no changes since v1) drivers/pci/pci_rom.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)

[PATCH v5 28/46] x86: Init video in SPL if enabled

2023-07-15 Thread Simon Glass
When video is required in SPL, set this up ready for use. Ignore any problems since it may be that video is not actually available and we still want to continue on to U-Boot proper in that case. Signed-off-by: Simon Glass --- Changes in v5: - Drop code to ensure the SPL banner is only shown once

[PATCH v5 27/46] x86: Ensure SPL banner is only shown once

2023-07-15 Thread Simon Glass
Print the banner in SPL init only if the spl_board_init() function isn't enabled. The spl_board_init() function is in the same file, but is called later, by board_init_r(). This avoids printing two banners, which causes tests to fail. Signed-off-by: Simon Glass --- Changes in v5: - Split out ba

[PATCH v5 26/46] x86: Pass video settings from SPL to U-Boot proper

2023-07-15 Thread Simon Glass
When video is set up in SPL, U-Boot proper needs to use the correct parameters so it can write to the display. Put these in a bloblist so they are available to U-Boot proper. Signed-off-by: Simon Glass Reviewed-by: Nikhil M Jain Reviewed-by: Bin Meng --- Changes in v5: - Use u16 instead of us

[PATCH v5 24/46] pci: Tidy up logging and reporting for video BIOS

2023-07-15 Thread Simon Glass
When running the ROM the code is not very helpful when something goes wrong. Add a little more debugging and some logging of return values to improve this. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) drivers/pci/pci_rom.c | 12 +--- 1 file changed, 9 ins

[PATCH v5 25/46] x86: Allow video-BIOS code to be built for SPL

2023-07-15 Thread Simon Glass
With qemu-x86_64 we need to run the video BIOS while in 32-bit mode, i.e. SPL. Add a Kconfig option for this, adjust the Makefile rules and use CONFIG_IS_ENABLED() where needed. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) arch/x86/lib/Makefile | 7 --- arch

[PATCH v5 11/46] x86: Show an error when a BIOS exception occurs

2023-07-15 Thread Simon Glass
Rather than silently hanging, show an error first. This can happen when there is something wrong with the video BIOS. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v2) Changes in v2: - Fix BINS typo - Drop the Ooops string arch/x86/lib/bios.c | 2 +- 1 file changed,

[PATCH v5 23/46] pci: Allow the video BIOS to work in SPL with QEMU

2023-07-15 Thread Simon Glass
QEMU emulates two common machines (Q35 and i440fx) which use mapping to determine whether RAM is present below 1MB. In order to copy the video BIOS to c we need to flip this mapping over to RAM. This does not happen automatically until SPL has finished running. Switch in RAM at these address s

[PATCH v5 22/46] pci: Support autoconfig in SPL

2023-07-15 Thread Simon Glass
Allow PCI autoconfig to be handled in SPL, so that we can set it up correctly for boards which need to do this before U-Boot proper. This includes qemu-x64_64 which needs to set up the video device while in 32-bit mode. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1)

[PATCH v5 21/46] nvme: Provide more useful debugging messages

2023-07-15 Thread Simon Glass
When scanning fails it is useful to be able to decode what went wrong. Add some debugging for this. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) drivers/nvme/nvme.c | 36 ++-- 1 file changed, 26 insertions(+), 10 deletions(-) diff

[PATCH v5 20/46] bdinfo: Show the malloc base with the bdinfo command

2023-07-15 Thread Simon Glass
It is useful to see the base of the malloc region. This is visible when debugging but not in normal usage. Add it to the global data so that it can be shown. Signed-off-by: Simon Glass Reviewed-by: Nikhil M Jain Tested-by: Nikhil M Jain Reviewed-by: Bin Meng --- Changes in v5: - Add 'bdinfo'

[PATCH v5 12/46] acpi: Add a comment to set the acpi tables

2023-07-15 Thread Simon Glass
Sometimes a previous bootloader has written ACPI tables. It is useful to be able to find and list these. Add an 'acpi set' command to set the address for these tables. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- Changes in v5: - Drop unnecessary 'allow' word cmd/acpi.c |

[PATCH v5 19/46] x86: Improve the trampoline in 64-bit mode

2023-07-15 Thread Simon Glass
At present this leaves the stack at the pre-relocation value. This is not ideal since we want to have U-Boot running entirely from the top of memory. In addition, the new global_data pointer is not actually used, since the global_data pointer itself is relocated, then the pre-relocation value is c

[PATCH v5 18/46] efi: Show all known UUIDs with CONFIG_CMD_EFIDEBUG

2023-07-15 Thread Simon Glass
The CMD_EFIDEBUG option enables debugging so it is reasonable to assume that all effects should be made to decode the dreaded UUIDs favoured by UEFI. Update the table to show them all when CONFIG_CMD_EFIDEBUG is enabled. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1

[PATCH v5 17/46] qfw: Set the address of the ACPI tables

2023-07-15 Thread Simon Glass
Once the ACPI tables have been set up, record their address so that it is possible to list them with 'acpi list'. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) drivers/misc/qfw.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/misc/qfw.c b/drivers/

[PATCH v5 16/46] log: Tidy up an ambiguous comment

2023-07-15 Thread Simon Glass
Add a bit more detail so it is clear that multiple devices are supported, but only one per driver. Signed-off-by: Simon Glass --- Changes in v5: - Drop period at end of commit subject - Drop extra 'a' in commit message common/log.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --

[PATCH v5 15/46] qfw: Show the file address if available

2023-07-15 Thread Simon Glass
Some files have an associated address. Show this with the 'qfw list' command so that it is possible to dump the data. Note that the reference to 'md' is for the md.rst file, not a markdown file. Signed-off-by: Simon Glass --- Changes in v5: - Drop extra 'qfw list' line - Update commit message t

[PATCH v5 09/46] x86: Show the CPU physical address size with bdinfo

2023-07-15 Thread Simon Glass
This is useful information so show it with the bdinfo command. Signed-off-by: Simon Glass --- Changes in v5: - Adjust the prompt for clarity (although it is now >12 chars) arch/x86/lib/bdinfo.c | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/x86/lib/bdinfo.c b/arch/x86/lib/bdinfo.c in

[PATCH v5 14/46] part: Allow setting the partition-table type

2023-07-15 Thread Simon Glass
Some devices have multiple partition types available on the same media. It is sometimes useful to see these to check that everything is working correctly. Provide a way to manually set the partition-table type, avoiding the auto-detection process. Signed-off-by: Simon Glass Reviewed-by: Bin Meng

[PATCH v5 10/46] x86: Correct get_sp() implementation for 64-bit

2023-07-15 Thread Simon Glass
Use an assembler implementation as is done for i386, so that the results are equivalent for i386 and x86_64. Signed-off-by: Simon Glass --- Changes in v5: - Reword commit message arch/x86/lib/bootm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/lib/bootm.c b/arc

[PATCH v5 13/46] bdinfo: Show the RAM top and approximate stack pointer

2023-07-15 Thread Simon Glass
These are useful pieces of information when debugging. The RAM top shows where U-Boot started allocating memory from, before it relocated. The stack pointer can be checked to ensure it is in the correct region. Signed-off-by: Simon Glass Reviewed-by: Nikhil M Jain Tested-by: Nikhil M Jain Revie

[PATCH v5 06/46] bios_emulator: Drop VIDEO_IO_OFFSET

2023-07-15 Thread Simon Glass
This is always zero in the source tree, so drop it. While we are here, add a comment to _X86EMU_env since the symbol is actually defined twice, which can cause confusion when building. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- Changes in v5: - Drop unnecessary 'it' in commit message

[PATCH v5 08/46] x86: Add a comment for board_init_f_r_trampoline()

2023-07-15 Thread Simon Glass
Add a comment for this function in the header. Change the function (and the one after) to use __noreturn to keep checkpatch happy. Add docs to board_init_f_r() while we are here. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v2) Changes in v2: - Add docs to board_ini

[PATCH v5 07/46] x86: Tidy up EFI code in interrupt_init()

2023-07-15 Thread Simon Glass
The ll_boot_init() check handles the EFI case so we don't need the rest of the code. Drop it. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) arch/x86/cpu/i386/interrupt.c | 17 + 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/arch/x8

[PATCH v5 05/46] bios_emulator: Add Kconfig and adjust Makefile for SPL

2023-07-15 Thread Simon Glass
The Kconfig for this is currently inside a particular board. Move it into the correct place and allow use in SPL, so that video can be used there if needed. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) board/google/Kconfig | 7 --- drivers/Kconfig

[PATCH v5 04/46] x86: mtrr: Add documentation

2023-07-15 Thread Simon Glass
Add documention for the x86 'mtrr' command. Signed-off-by: Simon Glass Reviewed-by: Bin Meng Suggested-by: Heinrich Schuchardt --- Changes in v5: - Fix 'abrievated' typo - Drop extra space in penultimate example Changes in v2: - Add new patch with docs for mtrr command doc/usage/cmd/mtrr.rs

[PATCH v5 03/46] x86: Allow listing MTRRs in SPL

2023-07-15 Thread Simon Glass
Move MTRR-listing code into a common file so it can be used from SPL. Update the 'mtrr' command to call it. Use this in SPL just before adjusting the MTRRs, so we can see the state set up by the board. Only show it when debug is enabled. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- Cha

[PATCH v5 02/46] x86: Return mtrr_add_request() to its old purpose

2023-07-15 Thread Simon Glass
This function used to be for adding a list of requests to be actioned on relocation. Revert it back to this purpose, to avoid problems with boards which need control of their MTRRs (i.e. those which don't use FSP). The mtrr_set_next_var() function is available when the next free variable-MTRR must

[PATCH v5 01/46] bdinfo: Add tests for serial settings

2023-07-15 Thread Simon Glass
Since the original patch was written, tests have been added for the 'bdinfo' command. Add the missing pieces so that the tests pass. Signed-off-by: Simon Glass Fixes: 68130503fbd ("bdinfo: Show information about the serial port") --- (no changes since v1) test/cmd/bdinfo.c | 14 ++

[PATCH v5 00/46] x86: Use qemu-x86_64 to boot EFI installers

2023-07-15 Thread Simon Glass
This series adds various minor features so that qemu-x86_64 can boot the Ubuntu 2022.04 installer using a virtio device: qemu-system-x86_64 -M pc -drive format=raw,file=root.img -bios /tmp/b/qemu-x86_64/u-boot.rom -drive if=virtio,file=ubuntu-22.04.2-desktop-amd64.iso -

Re: [PATCH v4 26/45] x86: Init video in SPL if enabled

2023-07-15 Thread Simon Glass
Hi Bin, On Wed, 12 Jul 2023 at 23:17, Bin Meng wrote: > > Hi Simon, > > On Mon, Jun 19, 2023 at 8:01 PM Simon Glass wrote: > > > > When video is required in SPL, set this up ready for use. Ignore any > > problems since it may be that video is not actually available and we > > still want to conti

Re: [PATCH v2 2/5] usb: dwc3-generic: Return early when there is no child node

2023-07-15 Thread Marek Vasut
On 7/16/23 03:05, Jonas Karlman wrote: On 2023-07-16 02:58, Marek Vasut wrote: On 7/16/23 01:10, Jonas Karlman wrote: The current error check for device_find_first_child is not working as expected, the documentation for device_find_first_child mention: @devp: Returns first child device, or

Re: [PATCH v2 2/5] usb: dwc3-generic: Return early when there is no child node

2023-07-15 Thread Jonas Karlman
On 2023-07-16 02:58, Marek Vasut wrote: > On 7/16/23 01:10, Jonas Karlman wrote: >> The current error check for device_find_first_child is not working as >> expected, the documentation for device_find_first_child mention: >> >>@devp: Returns first child device, or NULL if none >>Return: 0 >

Re: [PATCH v2 3/5] usb: dwc3-generic: Relax unsupported dr_mode check

2023-07-15 Thread Marek Vasut
On 7/16/23 01:10, Jonas Karlman wrote: When dr_mode is peripheral or otg and U-Boot has not been built with DM_USB_GADGET support, booting such device may end up with: dwc3_glue_bind_common: subnode name: usb@fcc0 Error binding driver 'dwc3-generic-wrapper': -6 Some drivers failed t

Re: [PATCH v2 2/5] usb: dwc3-generic: Return early when there is no child node

2023-07-15 Thread Marek Vasut
On 7/16/23 01:10, Jonas Karlman wrote: The current error check for device_find_first_child is not working as expected, the documentation for device_find_first_child mention: @devp: Returns first child device, or NULL if none Return: 0 Change to return early when there is no child node to

[PATCH v3 81/81] buildman: Enable test coverage

2023-07-15 Thread Simon Glass
Enable measuring test coverage for buildman so we can see the gaps. It is currently at 68%. Signed-off-by: Simon Glass --- Changes in v3: - Fix 'bulidman' typo in three patches Changes in v2: - Drop patch to move -A logic up a little (since it breaks it) tools/buildman/cmdline.py | 2 +

[PATCH v3 80/81] buildman: Add an option to check maintainers and targets

2023-07-15 Thread Simon Glass
In poking around it seems that many boards don't define a CONFIG_TARGET Kconfig variable. This is not strictly necessary, but add an option to buildman so these can be viewed. Signed-off-by: Simon Glass --- Changes in v3: - Add new patch with an option to check maintains and targets tools/buil

[PATCH v3 79/81] buildman: Use -D for --debug

2023-07-15 Thread Simon Glass
Change -D to mean --debug for consistency with other tools. This is not a commonly used option, so the impact should be minimal. Signed-off-by: Simon Glass --- Changes in v3: - Add new patch to use -D for --debug tools/buildman/buildman.rst | 6 +++--- tools/buildman/cmdline.py | 8

[PATCH v3 78/81] buildman: Add a way to print the architecture for a board

2023-07-15 Thread Simon Glass
This is useful for some tools and is easily available for buildman. Add a new --print-arch option. Signed-off-by: Simon Glass --- (no changes since v2) Changes in v2: - Add new patch to print the architecture for a board tools/buildman/cmdline.py | 2 ++ tools/buildman/control.py | 24 ++

[PATCH v3 77/81] buildman: Move copy_files() out ot BuilderThread class

2023-07-15 Thread Simon Glass
This does not need to be in the class. Move it out to avoid a pylint warning. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 47 + 1 file changed, 24 insertions(+), 23 deletions(-) diff --git a/tools/buildman/builderthrea

[PATCH v3 74/81] buildman: Avoid passing result into _read_done_file()

2023-07-15 Thread Simon Glass
Move the creating of the result object into the function which sets it up, to simplify the code. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 19 +++ 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/tools/buildman/buildert

[PATCH v3 75/81] buildman: Tidy up reporting of a toolchain error

2023-07-15 Thread Simon Glass
Provide the text of the exception when something goes wrong. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 7 +-- tools/buildman/func_test.py | 6 -- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/tools/buildman/builderthread

[PATCH v3 76/81] buildman: Tidy up some comments in builderthread

2023-07-15 Thread Simon Glass
Make sure all functions have full argument documentation. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 66 ++--- 1 file changed, 36 insertions(+), 30 deletions(-) diff --git a/tools/buildman/builderthread.py b/tools/buildma

[PATCH v3 70/81] buildman: Move code to remove old outputs

2023-07-15 Thread Simon Glass
Put this in its own function to reduce the size of the run_commit() function. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 28 +++- 1 file changed, 19 insertions(+), 9 deletions(-) diff --git a/tools/buildman/builderthread.py b

[PATCH v3 72/81] buildman: Move checkout code to a separate function

2023-07-15 Thread Simon Glass
Put this in its own function to reduce the size of the run_commit() function Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 30 +- 1 file changed, 21 insertions(+), 9 deletions(-) diff --git a/tools/buildman/builderthread.py

[PATCH v3 73/81] buildman: Create a function to handle config and build

2023-07-15 Thread Simon Glass
Move this code into a _config_and_build() function, so reduce the size of run_commit(). Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 97 + 1 file changed, 61 insertions(+), 36 deletions(-) diff --git a/tools/buildman/bu

[PATCH v3 69/81] buildman: Move reading of the done file into a function

2023-07-15 Thread Simon Glass
Move this logic into its own function to reduce the size of the run_commt() function. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 66 + 1 file changed, 42 insertions(+), 24 deletions(-) diff --git a/tools/buildman/buil

[PATCH v3 71/81] buildman: Move code to decide output dirs

2023-07-15 Thread Simon Glass
Put this in its own function to reduce the size of the run_commit() function. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 34 - 1 file changed, 25 insertions(+), 9 deletions(-) diff --git a/tools/buildman/builderthread

[PATCH v3 68/81] buildman: Move bulid code into its own function

2023-07-15 Thread Simon Glass
Split this into its own function so reduce the size of run_commit(). Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 40 - 1 file changed, 30 insertions(+), 10 deletions(-) diff --git a/tools/buildman/builderthread.py b/to

[PATCH v3 67/81] buildman: Move reconfigure code into its own function

2023-07-15 Thread Simon Glass
Split this into its own function so reduce the size of run_commit(). Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 41 - 1 file changed, 30 insertions(+), 11 deletions(-) diff --git a/tools/buildman/builderthread.py b/to

[PATCH v3 66/81] buildman: Convert config_out to string IO

2023-07-15 Thread Simon Glass
This is probably a little more efficient and it allows passing the object to another function to write data. Convert config_out to use a string I/O device. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 9 + 1 file changed, 5 insertions(+), 4 del

[PATCH v3 65/81] buildman: Move more things into _build_args()

2023-07-15 Thread Simon Glass
Move more of the argument-building code into this function. Fix a missing assignment for out_rel_dir too. Rename the function since it now builds all the arguments. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 55 - 1 f

[PATCH v3 64/81] buildman: Move setting of toolchain arguments to _build_args()

2023-07-15 Thread Simon Glass
Move a few more pieces to this new function. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/tools/buildman/builderthread.py b/tools/buildman/builderthread.py index 47ebf4dcdd90..e

[PATCH v3 63/81] buildman: Start a function to set up the make arguments

2023-07-15 Thread Simon Glass
Move some of this code into a new funciion, to help reduce the size of the run_commits() function. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 38 - 1 file changed, 23 insertions(+), 15 deletions(-) diff --git a/tools/

[PATCH v3 56/81] buildman: Convert camel case in builder.py

2023-07-15 Thread Simon Glass
Convert this file to snake case and update all files which use it. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builder.py | 228 tools/buildman/builderthread.py | 26 ++-- tools/buildman/control.py | 13 +- tools/buildman/f

[PATCH v3 62/81] buildman: Drop unnecessary assignment of config_out

2023-07-15 Thread Simon Glass
This is already set up earlier in the function, so drop the extra assignment. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 1 - 1 file changed, 1 deletion(-) diff --git a/tools/buildman/builderthread.py b/tools/buildman/builderthread.py index f110137e

[PATCH v3 61/81] buildman: Correct invalid use of out_dir variable

2023-07-15 Thread Simon Glass
This variable has a different meaning in the outer scope. Use a different name to avoid confusion, or bugs. Signed-off-by: Simon Glass --- Changes in v3: - Fix 'scrop' typo tools/buildman/builderthread.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/buildman/bu

[PATCH v3 59/81] buildman: Correct most pylint warnings in builderthread

2023-07-15 Thread Simon Glass
Fix the easy warnings in this file. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builderthread.py | 95 ++--- 1 file changed, 51 insertions(+), 44 deletions(-) diff --git a/tools/buildman/builderthread.py b/tools/buildman/builderthread.py ind

[PATCH v3 60/81] buildman: Export _get_output_dir() to avoid warnings

2023-07-15 Thread Simon Glass
Make this a public memory since it is used outside the class. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builder.py | 8 tools/buildman/builderthread.py | 2 +- tools/buildman/test.py | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) dif

[PATCH v3 54/81] buildman: Convert to argparse

2023-07-15 Thread Simon Glass
Use argparse to parse the arguments, since OptionParser is deprecated now. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/cmdline.py | 130 + tools/buildman/control.py | 141 ++-- tools/buildman/func_test.

[PATCH v3 58/81] buildman: Convert camel case in builderthread.py

2023-07-15 Thread Simon Glass
Convert this file to snake case and update all files which use it. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builder.py | 8 +++--- tools/buildman/builderthread.py | 50 - 2 files changed, 29 insertions(+), 29 deletions(-) diff

[PATCH v3 57/81] buildman: Split parser creation in two

2023-07-15 Thread Simon Glass
Split this into two functions to avoid a warning about too many statements. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/cmdline.py | 44 +-- 1 file changed, 33 insertions(+), 11 deletions(-) diff --git a/tools/buildman/cmdline.py b/t

[PATCH v3 53/81] buildman: Add a test for --boards

2023-07-15 Thread Simon Glass
Add a simple functional test for the --boards option. Fix the example in the docs while we are here. Also improve the docs for Builder.count so it is clearer what it contains. Signed-off-by: Simon Glass --- (no changes since v2) Changes in v2: - Use snake case for tests tools/buildman/builder

[PATCH v3 55/81] buildman: Convert camel case in bsettings.py

2023-07-15 Thread Simon Glass
Convert this file to snake case and update all files which use it. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/bsettings.py | 14 +++--- tools/buildman/control.py | 2 +- tools/buildman/func_test.py | 12 ++-- tools/buildman/main.py | 2 +- tool

[PATCH v3 52/81] buildman: Correct most pylint warnings in cmdline

2023-07-15 Thread Simon Glass
Tidu up warnings in this file. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/cmdline.py | 15 +++ 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/tools/buildman/cmdline.py b/tools/buildman/cmdline.py index 503c48d769ff..660a83bc3d0f 100644 --- a

[PATCH v3 51/81] buildman: Convert camel case in cmdline.py

2023-07-15 Thread Simon Glass
Convert this file to snake case and update all files which use it. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/cmdline.py | 2 +- tools/buildman/func_test.py | 2 +- tools/buildman/main.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/too

[PATCH v3 49/81] buildman: Use get_alow_missing() directly to avoid var

2023-07-15 Thread Simon Glass
Avoid an unnecessary local variable by moving this code to a function. This fixes the pylint warning about too many local variables. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/tools

[PATCH v3 50/81] buildman: Create a function to get number of built commits

2023-07-15 Thread Simon Glass
Move this code into a function. This removes the last pylint error in the control module. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 34 +- 1 file changed, 25 insertions(+), 9 deletions(-) diff --git a/tools/buildman/contro

[PATCH v3 48/81] buildman: Move getting the adjust_cfg into run_builder()

2023-07-15 Thread Simon Glass
Move this into its own function to reduce the size of do_buildman(). Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 38 +++--- 1 file changed, 27 insertions(+), 11 deletions(-) diff --git a/tools/buildman/control.py b/tools/bui

[PATCH v3 47/81] buildman: Move checking for make into run_builder()

2023-07-15 Thread Simon Glass
This is not needed until the builder is run. Move it there to reduce the size of the do_buildman() function. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 14 -- 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/tools/buildman/control.

[PATCH v3 46/81] buildman: Adjust show_toolchain_prefix() to not return

2023-07-15 Thread Simon Glass
This function does not need to return. Simplify the code by exiting immediately. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/tools/buildman/control.py b/tools/buildman/control.py index

[PATCH v3 21/81] buildman: Fix most pylint warnings in control

2023-07-15 Thread Simon Glass
Tidy up the easier-to-fix pylint warnings in module 'control'. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 119 +--- tools/buildman/func_test.py | 2 +- 2 files changed, 71 insertions(+), 50 deletions(-) diff --git a/too

[PATCH v3 45/81] buildman: Drop some unnecessary variables

2023-07-15 Thread Simon Glass
Drop some variables at the end of the do_bulidman() function. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/tools/buildman/control.py b/tools/buildman/control.py index 9f775cb15df4..f30

[PATCH v3 43/81] buildman: Tweak commits and show_bloat

2023-07-15 Thread Simon Glass
Move setting of show_bloat to adjust_options() and adjust how the commits variable is set. Together these remove the pylint warning about too many statements. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 13 + 1 file changed, 5 insertions(+), 8 d

[PATCH v3 25/81] buildman: Add a test for the -A option

2023-07-15 Thread Simon Glass
This lacks a test at present. Add one. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/func_test.py | 7 +++ 1 file changed, 7 insertions(+) diff --git a/tools/buildman/func_test.py b/tools/buildman/func_test.py index 574161aad876..6753a4098942 100644 --- a/tools/build

[PATCH v3 44/81] buildman: Moving running of the builder into a function

2023-07-15 Thread Simon Glass
Move this code into a new function. This removes the pylint warning about too many branches. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 56 --- 1 file changed, 35 insertions(+), 21 deletions(-) diff --git a/tools/buildm

[PATCH v3 40/81] buildman: Move commit numbering into determine_series()

2023-07-15 Thread Simon Glass
Commits are numbered for use in tests. Do this in determine_series() since it is already dealing with the series. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/tools/buildman/control

[PATCH v3 42/81] buildman: Move remaining builder properties to constructor

2023-07-15 Thread Simon Glass
Do these all in the constructor, so it is consistent. Move the stray builder comment into the correct place. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/builder.py | 25 ++--- tools/buildman/control.py | 18 +++--- 2 files changed, 25 in

[PATCH v3 41/81] buildman: Avoid too many returns in do_buildman()

2023-07-15 Thread Simon Glass
Fix the pylint warning by using a variable instead of lots of 'return' statements. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/tools/buildman/control.py b/tools/buildman/control.py i

[PATCH v3 39/81] buildman: Move setting up the output dir into a function

2023-07-15 Thread Simon Glass
Move this code into a separate function to reduce the size of the main do_buildman() directory. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 45 --- 1 file changed, 33 insertions(+), 12 deletions(-) diff --git a/tools/bui

[PATCH v3 38/81] buildman: Move counting of commits into a function

2023-07-15 Thread Simon Glass
Move this code into a separate function to avoid a pylint warning in determine_series(). Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 63 +-- 1 file changed, 41 insertions(+), 22 deletions(-) diff --git a/tools/buildman/c

  1   2   3   >