summaryrefslogtreecommitdiff
path: root/board/starfive/visionfive2/starfive_visionfive2.c
AgeCommit message (Collapse)Author
2025-04-27board: starfive: visionfive2: Order board detection logic to match configE Shattow
Fixup previous merge resolution of this series. Intent is to ease code readability and logic to match ordering in CONFIG_OF_LIST - Remove "starfive/" string math - Remove redundant local cache of calls to get_*_from_eeprom() - Match name before EEPROM product_id in board_fit_config_name_match() - Remove single-consumer FDTFILE_* defines - Do not set fdtfile for visionfive-2-* when unknown model revision Fixes: 5a0a93a76848 ("Merge branch 'master' of https://source.denx.de/u-boot/custodians/u-boot-riscv") Signed-off-by: E Shattow <e@freeshell.de>
2025-04-25board: starfive: DeepComputing FML13V01 fdt selectionHeinrich Schuchardt
We support all JH7110 boards with starfive_visionfive2_defconfig. The relevant device-tree is selected at runtime based on EEPROM data. Support setting $fdtfile to the file name of the DeepComputing Framework motherboard (FML13V01) device-tree. Reviewed-by: Hal Feng <hal.feng@starfivetech.com> Reviewed-by: Matthias Brugger <mbrugger@suse.com> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Reviewed-by: E Shattow <e@freeshell.de>
2025-04-25board: starfive: Remove duplicated board_fdt_blob_setupYao Zi
The default version should work for Starfive VisionFive 2. Signed-off-by: Yao Zi <ziyao@disroot.org> Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com>
2025-03-28board: starfive: Remove compatible boards Milk-V Mars CM and Mars CM LiteE Shattow
Remove leftover code from Milk-V Mars CM and Mars CM Lite boards that do not exist in upstream Linux Kernel devicetree-rebasing. These will be re- introduced when submitted upstream for a future U-Boot release. Users of these boards should use the previous stable release of U-Boot until then. Signed-off-by: E Shattow <e@freeshell.de>
2024-12-18fdt: Swap the signature for board_fdt_blob_setup()Simon Glass
This returns a devicetree and updates a parameter with an error code. Swap it, since this fits better with the way U-Boot normally works. It also (more easily) allows leaving the existing pointer unchanged. No yaks were harmed in this change, but there is a very small code-size reduction. For sifive, the OF_BOARD option must be set for the function to be called, so there is no point in checking it again. Also OF_SEPARATE is defined always. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Matthias Brugger <mbrugger@suse.com> Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com> [trini: Update total_compute] Signed-off-by: Tom Rini <trini@konsulko.com>
2024-05-30board: starfive: support Pine64 Star64 boardH Bell
Similar to the Milk-V Mars, The Star64 board contains few differences to the VisionFive 2 boards, so can be part of the same U-boot build. Signed-off-by: Henry Bell <dmoo_dv@protonmail.com> Cc: ycliang@andestech.com Cc: heinrich.schuchardt@canonical.com Reviewed-by: E Shattow <lucent@gmail.com>
2024-05-14board: add support for Milk-V Mars CMHeinrich Schuchardt
We already support the VisionFive 2 and the Milk-V Mars board by patching the VisionFive 2 device tree. With this patch the same is done for the Milk-V Mars CM. Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Tested-by: E. Shattow <lucent@gmail.com> Reviewed-by: E. Shattow <lucent@gmail.com>
2024-04-09riscv: starfive: avoid including common.hHeinrich Schuchardt
The usage of common.h is deprecated. Remove it from board files. Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com>
2024-04-09riscv: set fdtfile on Milk-V MarsHeinrich Schuchardt
Set environment variable fdtfile to the correct value for the Milk-V Mars board. Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com>
2024-04-09riscv: do not set default fdt for VisionFive 2Heinrich Schuchardt
Currently in set_fdtfile() we set the value of environment variable fdtfile unconditionally. The implies that a value in the environment will be ignored. With the patch environment variable fdtfile will only be set if it does not yet exist. This requires that CONFIG_DEFAULT_FDT_FILE is not set. Now the user can either set and save fdtfile interactively or in the U-Boot configuration to overrule the device-tree name chosen based on the hardware in set_fdtfile(). Reported-by: E Shattow <lucent@gmail.com> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com>
2023-10-02Merge branch 'next'Tom Rini
Signed-off-by: Tom Rini <trini@konsulko.com>
2023-09-26riscv: set fdtfile on VisionFive 2Heinrich Schuchardt
Multiple revisions of the StarFive VisionFive 2 board exist. They can be identified by reading their EEPROM. Linux uses two differently named device-tree files. To load the correct device-tree we need to set $fdtfile to the device-tree file name that matches the board revision. Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com> Tested-by: Milan P. Stanić <mps@arvanta.net>
2023-09-20riscv: set fdtfile on VisionFive 2Heinrich Schuchardt
Multiple revisions of the StarFive VisionFive 2 board exist. They can be identified by reading their EEPROM. Linux uses two differently named device-tree files. To load the correct device-tree we need to set $fdtfile to the device-tree file name that matches the board revision. Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com>
2023-09-20board: visionfive2: Fixup memory size passed to kernelShengyu Qu
Use fdt_fixup_memory to make the memory size data from dtb match the actual size. Signed-off-by: Shengyu Qu <wiagn233@outlook.com> Tested-by: Milan P. Stanić <mps@arvanta.net>
2023-08-09treewide: unify the linker symbol reference formatShiji Yang
Now all linker symbols are declared as type char[]. Though we can reference the address via both the array name 'var' and its address '&var'. It's better to unify them to avoid confusing developers. This patch converts all '&var' linker symbol refrences to the most commonly used format 'var'. Signed-off-by: Shiji Yang <yangshiji66@outlook.com> Reviewed-by: Tom Rini <trini@konsulko.com>
2023-07-12configs: starfive: Enable ID EEPROM configurationYanhong Wang
Enabled ID_EEPROM and I2C configuration for StarFive VisionFive2 board. Signed-off-by: Yanhong Wang <yanhong.wang@starfivetech.com> Reviewed-By: Leo Yu-Chi Linag <ycliang@andestech.com>
2023-04-20board: starfive: add StarFive VisionFive v2 board supportYanhong Wang
Add board support for StarFive VisionFive v2. Signed-off-by: Yanhong Wang <yanhong.wang@starfivetech.com> Tested-by: Conor Dooley <conor.dooley@microchip.com>