On Wed, Feb 05, 2025 at 12:09:02PM +0100, Marek Behún wrote:
> > +#define FLD_GET(r, f) (((r) & (f ## _MASK)) >> (f ## _LSB))
> > +#define FLD_SET(r, f, v) r = (((r) & ~(f ## _MASK)) | ((v) << (f ## _LSB)))
>
> Use FIELD_GET and FIELD_SET.
Sorry, FIELD_GET and FIELD_PREP.
On Wed, Feb 05, 2025 at 10:15:45AM +, Oleksii Moisieiev wrote:
...
> +#define RP1_PAD_DRIVE_LSB4
> +#define RP1_PAD_IN_ENABLE_MASK 0x0040
> +#define RP1_PAD_IN_ENABLE_LSB6
> +#define RP1_PAD_OUT_DISABLE_MASK 0x0080
> +#define RP1_PAD_OUT_D
Acked-by: Marek Behún
On Tue, Nov 26, 2024 at 03:20:26PM +0100, Heinrich Schuchardt wrote:
> The number of bytes may only be specified if a device number id provided.
>
> Correct the formatting.
>
> Signed-off-by: Heinrich Schuchardt
> ---
> cmd/rng.c | 4
Hi all,
I am searching for HW that supports both USB host & USB device/gadget
mode, on the same USB port, capable of switching between these modes
at runtime.
Preferably supported in upstream kernel.
Has anyone done this for example with Raspberry Pi?
Thanks.
Marek
On Tue, Sep 03, 2024 at 08:57:24AM +0200, Stefan Roese wrote:
> On 8/29/24 10:08, Marek Behún wrote:
> > Use the i2c_eeprom miscellaneous driver for reading Turris Omnia EEPROM
> > in U-Boot proper. Keep using dm_i2c_read() in SPL build, since adding
> > the i2c_eepro
mode.
Signed-off-by: Marek Behún
---
board/CZ.NIC/turris_omnia/turris_omnia.c | 90
1 file changed, 77 insertions(+), 13 deletions(-)
diff --git a/board/CZ.NIC/turris_omnia/turris_omnia.c
b/board/CZ.NIC/turris_omnia/turris_omnia.c
index 46f20f05c05..eb88ee7f1ed 100644
--- a/
Use the i2c_eeprom miscellaneous driver for reading Turris Omnia EEPROM
in U-Boot proper. Keep using dm_i2c_read() in SPL build, since adding
the i2c_eeprom driver to SPL build increases the image by 1.5 KiB.
Signed-off-by: Marek Behún
---
arch/arm/mach-mvebu/Kconfig | 1 +
board
Rename the variable holding the EEPROM udevice from `chip` to `eeprom`.
Signed-off-by: Marek Behún
---
board/CZ.NIC/turris_omnia/turris_omnia.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/board/CZ.NIC/turris_omnia/turris_omnia.c
b/board/CZ.NIC/turris_omnia
speed mode, and also write this setting to
EEPROM, so that subsequent boots will also train in 1333H mode.
The user can set back the default mode with the `eeprom` U-Boot command,
or with the `omnia-eeprom` Linux command.
Marek
[1] https://docs.turris.cz/hw/omnia/rescue-modes/
Marek Behún (3
Reviewed-by: Marek Behún
Reviewed-by: Marek Behún
Reviewed-by: Marek Behún
Reviewed-by: Marek Behún
Reviewed-by: Marek Behún
Reviewed-by: Marek Behún
field "Use old DDR training":
eeprom update "Use old DDR training" 1
Signed-off-by: Marek Behún
---
arch/arm/mach-mvebu/Kconfig | 1 +
board/CZ.NIC/turris_omnia/Makefile| 1 +
board/CZ.NIC/turris_omnia/eeprom.c| 37 ++-
board
to support this need to select the
ARMADA_38X_SUPPORT_OLD_DDR3_TRAINING
config option and implement the old version of DDR topology provider,
ddr3_get_topology_map().
Signed-off-by: Marek Behún
---
arch/arm/mach-mvebu/Kconfig | 4 +
arch/arm/mach-mvebu/include/mach/cpu.h
Backport the option to compile with immutable debug settings also to
the old implementation of the DDR3 training code.
The original PR for mv-ddr-marvell can be seen at
https://github.com/MarvellEmbeddedProcessors/mv-ddr-marvell/pull/45/
Signed-off-by: Marek Behún
---
drivers/ddr/marvell
Fix some compilation warning in the old DDR training code.
Signed-off-by: Marek Behún
---
drivers/ddr/marvell/a38x/old/ddr3_a38x.c | 1 +
drivers/ddr/marvell/a38x/old/ddr3_init.h | 2 ++
drivers/ddr/marvell/a38x/old/ddr3_training.c | 1 +
drivers/ddr
Enable the 'eeprom' command with support for EEPROM layout for Turris
Omnia. Enable the i2c-eeprom driver so that the EEPROM is accessed via
driver model.
Signed-off-by: Marek Behún
---
configs/turris_omnia_defconfig | 3 +++
1 file changed, 3 insertions(+)
diff --git
, 1600K) and use it to overwrite the DDR topology parameters
used by the DDR training algorithm.
Signed-off-by: Marek Behún
---
board/CZ.NIC/turris_omnia/eeprom.c | 41 +-
board/CZ.NIC/turris_omnia/turris_omnia.c | 99 +++-
2 files changed, 135 insertions(+), 5
Extend the Omnia EEPROM information structure in preparation for more
variables to be stored there.
Signed-off-by: Marek Behún
---
board/CZ.NIC/turris_omnia/eeprom.c | 11 ++-
board/CZ.NIC/turris_omnia/turris_omnia.c | 42
2 files changed, 46 insertions(+), 7
34a04103
RAM size in GB2
Wi-Fi Region
CRC32 checksum cecbc2a1
Signed-off-by: Marek Behún
---
board/CZ.NIC/turris_omnia/Makefile | 1 +
board/CZ.NIC/turris_omnia/eeprom.c | 109 +
2 files changed, 110 insertions(+)
create mode 1006
use reset-gpios so that we can get
rid of these drivers parsing this property.
Fixes: 1da53ae26afc ("arm: mvebu: turris_omnia: Add support for design with SW
reset signals")
Signed-off-by: Marek Behún
---
board/CZ.NIC/turris_omnia/turris_omnia.c | 44 ++-
Save 10 KiB in Turris Omnia's SPL binary by enabling immutable debug
settings for DDR3 training code.
Signed-off-by: Marek Behún
---
configs/turris_omnia_defconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/configs/turris_omnia_defconfig b/configs/turris_omnia_defconfig
Allow compiling with immutable debug settings:
- DEBUG_LEVEL is always set to DEBUG_LEVEL_ERROR
- register dumps are disabled
This can save around 10 KiB of space in the resulting binary, which is a
lot in U-Boot SPL.
Signed-off-by: Marek Behún
---
arch/arm/mach-mvebu/Kconfig | 10
The variables is_validate_window_per_if, is_validate_window_per_pup,
sweep_cnt and is_run_leveling_sweep_tests are only used if
DDR_VIEWER_TOOL macro is defined, so define them only in that case.
Make them static since they are only used in ddr3_debug.c.
Signed-off-by: Marek Behún
---
drivers
The variables is_default_centralization, is_tune_result and
is_bist_reset_bit are never used.
Signed-off-by: Marek Behún
---
drivers/ddr/marvell/a38x/ddr3_debug.c | 3 ---
drivers/ddr/marvell/a38x/ddr3_init.h | 1 -
2 files changed, 4 deletions(-)
diff --git a/drivers/ddr/marvell/a38x
: Marek Behún
---
configs/turris_omnia_defconfig | 1 -
1 file changed, 1 deletion(-)
diff --git a/configs/turris_omnia_defconfig b/configs/turris_omnia_defconfig
index 225a76f993..d5699782d7 100644
--- a/configs/turris_omnia_defconfig
+++ b/configs/turris_omnia_defconfig
@@ -124,4 +124,3
Return from ddr3_tip_print_log() early if we won't print anything
anyway.
This way the compiler can optimize away the VALIDATE_IF_ACTIVE() calls
in the for-loop, so if the SILENT_LIB macro is defined, no code is
generated for the rest of the function, which saves some space.
Signed-off-by:
Hi Stefan,
this is v2 of the series adds some changes to DDR3 training for Armada
38x and Turris Omnia.
I also put one unrelated patch (Fix ethernet PHY reset gpio FDT fixup)
here.
It depends on stuff in Tom's next branch.
Marek
Marek Behún (16):
arm: mvebu: turris_omnia: Disable ext4
On Mon, 17 Jun 2024 22:49:47 +0300
Alex Shumsky wrote:
> Fix btrfs_read/read_and_truncate_page write out of bounds of destination
> buffer. Old behavior break bootstd malloc'd buffers of exact file size.
> Previously this OOB write have not been noticed because distroboot usually
> read files int
fier for the 'eeprom' command, in
addition to the legacy [[bus] devaddr] specifier.
Moreover if no device specifier is given, then the first
UCLASS_I2C_EEPROM device is used, if found.
Signed-off-by: Marek Behún
---
cmd/eeprom.c | 122 ++-
Don't read/write whole EEPROM if not necessary when printing / updating
EEPROM layout fields. Only read/write layout.data_size bytes.
Signed-off-by: Marek Behún
---
cmd/eeprom.c | 11 ++-
1 file changed, 2 insertions(+), 9 deletions(-)
diff --git a/cmd/eeprom.c b/cmd/eeprom.c
In preparation for allowing to access eeprom by driver-model device
name, refactor the eeprom device specifier parsing. Instead of filling
two parameters (i2c_bus, i2c_addr), the parsing function now fills one
parameter of type struct eeprom_dev_spec.
Signed-off-by: Marek Behún
---
cmd/eeprom.c
Refactor the eeprom_execute_command() function into separate functions
do_eeprom_rw(), do_eeprom_print() and do_eeprom_update().
Signed-off-by: Marek Behún
---
cmd/eeprom.c | 111 ---
1 file changed, 71 insertions(+), 40 deletions(-)
diff --git a
Deduplicate the calls to parse_i2c_bus_addr().
Signed-off-by: Marek Behún
---
cmd/eeprom.c | 36 +---
1 file changed, 17 insertions(+), 19 deletions(-)
diff --git a/cmd/eeprom.c b/cmd/eeprom.c
index d610dc9931..12902e812e 100644
--- a/cmd/eeprom.c
+++ b/cmd
ROM layout versioning.
Signed-off-by: Marek Behún
---
cmd/Kconfig | 9 -
cmd/eeprom.c | 20 +++-
configs/cm_fx6_defconfig | 1 +
configs/cm_t43_defconfig | 1 +
4 files changed, 25 insertions(+), 6 deletions(-)
diff --git a/cmd/Kconfig b/cmd/Kco
The bus and devaddr arguments of the eeprom command are optional, and if
only one is given, it is assumed to be devaddr. Change the usage help
from
to
[[bus] [devaddr]
Signed-off-by: Marek Behún
---
cmd/eeprom.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a
The byte variable is of type unsigned char, it is never less than zero.
The error case is handled by *endptr, so drop the comparison altogether.
Signed-off-by: Marek Behún
---
common/eeprom/eeprom_field.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/common/eeprom
The __eeprom_field_update_bin() function is expected to parse a hex
string into bytes (potentially in reverse order), but the
simple_strtoul() function is given 0 as base. This does not work since
the string does not contain '0x' prefix. Add explicit base 16.
Signed-off-by: M
Split the eeprom layout field finding code from the
eeprom_layout_update_field() function in order to make it usable in
alternative implementations of update method.
Signed-off-by: Marek Behún
---
common/eeprom/eeprom_layout.c | 46 +++
include/eeprom_layout.h
Assign the default eeprom layout parameter .data_size and methods
.print() and .update() before calling eeprom_layout_assign() in
eeprom_layout_setup().
This allows eeprom_layout_assign() to overwrite these if needed.
Signed-off-by: Marek Behún
---
common/eeprom/eeprom_layout.c | 8
1
eries is a dependency for some DDR issue fixes for Turris Omnia.
I will be sending that one separately.
github PR link (with CI):
https://github.com/u-boot/u-boot/pull/540
- there is a failure for
test.py for sandbox sandbox_clang
but it seems unrelated to these changes
Marek Behún (11)
On Wed, 15 May 2024 11:10:09 +0200
Stefan Roese wrote:
> Hi Marek,
>
> On 5/15/24 10:59, Marek Behún wrote:
> > On Mon, 6 May 2024 12:03:55 +0200
> > Stefan Roese wrote:
> >
> >> Hi Marek,
> >>
> >> On 4/15/24 18:30, Marek Behún wrote:
On Mon, 6 May 2024 12:03:55 +0200
Stefan Roese wrote:
> Hi Marek,
>
> On 4/15/24 18:30, Marek Behún wrote:
> > Support old DDR3 training code on Turris Omnia, selectable by U-Boot
> > enviroment variable.
> >
> > Users experiencing DDR3 initialization
On Tue, 14 May 2024 16:04:13 +0200
lukas.funke-...@weidmueller.com wrote:
> From: Lukas Funke
>
>
> This series adds a driver to read and write ZynqMP eFuses [1]. The
> driver can be accessed by the 'efuse_read' and 'efuse_write' subcommands
> of the 'zynqmp' command.
Vendor specific commands
use reset-gpios so that we can get
rid of these drivers parsing this property.
Fixes: 1da53ae26afc ("arm: mvebu: turris_omnia: Add support for design with SW
reset signals")
Signed-off-by: Marek Behún
---
board/CZ.NIC/turris_omnia/turris_omnia.c | 44 ++-
Acked-by: Marek Behún
on such as
> 14.0.1.
>
> All the best,
> Tony
>
> On Mon, Apr 15, 2024 at 9:39 AM Marek Behún wrote:
> >
> > Hi Stefan,
> >
> > this series adds some changes to DDR3 training for Armada 38x and
> > Turris Omnia.
> >
> > - patches 1-4 are
the
environment variable
env set omnia_ddr3_training old
env save
Signed-off-by: Marek Behún
---
arch/arm/mach-mvebu/Kconfig | 1 +
board/CZ.NIC/turris_omnia/Makefile| 1 +
board/CZ.NIC/turris_omnia/old_ddr3_training.c | 79 +++
board/CZ.NIC
to support this need to select the
ARMADA_38X_SUPPORT_OLD_DDR3_TRAINING
config option and implement the old version of DDR topology provider,
ddr3_get_topology_map().
Signed-off-by: Marek Behún
---
arch/arm/mach-mvebu/Kconfig | 4 +
arch/arm/mach-mvebu/include/mach/cpu.h
Backport the option to compile with immutable debug settings also to
the old implementation of the DDR3 training code.
The original PR for mv-ddr-marvell can be seen at
https://github.com/MarvellEmbeddedProcessors/mv-ddr-marvell/pull/45/
Signed-off-by: Marek Behún
---
drivers/ddr/marvell
Fix some compilation warning in the old DDR training code.
Signed-off-by: Marek Behún
---
drivers/ddr/marvell/a38x/old/ddr3_a38x.c | 1 +
drivers/ddr/marvell/a38x/old/ddr3_init.h | 2 ++
drivers/ddr/marvell/a38x/old/ddr3_training.c | 1 +
drivers/ddr
Save 10 KiB in Turris Omnia's SPL binary by enabling immutable debug
settings for DDR3 training code.
Signed-off-by: Marek Behún
---
configs/turris_omnia_defconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/configs/turris_omnia_defconfig b/configs/turris_omnia_defconfig
Allow compiling with immutable debug settings:
- DEBUG_LEVEL is always set to DEBUG_LEVEL_ERROR
- register dumps are disabled
This can save around 10 KiB of space in the resulting binary, which is a
lot in U-Boot SPL.
Signed-off-by: Marek Behún
---
arch/arm/mach-mvebu/Kconfig | 10
The variables is_validate_window_per_if, is_validate_window_per_pup,
sweep_cnt and is_run_leveling_sweep_tests are only used if
DDR_VIEWER_TOOL macro is defined, so define them only in that case.
Make them static since they are only used in ddr3_debug.c.
Signed-off-by: Marek Behún
---
drivers
Return from ddr3_tip_print_log() early if we won't print anything
anyway.
This way the compiler can optimize away the VALIDATE_IF_ACTIVE() calls
in the for-loop, so if the SILENT_LIB macro is defined, no code is
generated for the rest of the function, which saves some space.
Signed-off-by:
The variables is_default_centralization, is_tune_result and
is_bist_reset_bit are never used.
Signed-off-by: Marek Behún
---
drivers/ddr/marvell/a38x/ddr3_debug.c | 3 ---
drivers/ddr/marvell/a38x/ddr3_init.h | 1 -
2 files changed, 4 deletions(-)
diff --git a/drivers/ddr/marvell/a38x
explained in patch 6
- patch 9 glues the old DDR3 training code to current U-Boot
- patch 10 allows for dynamic selection of old DDR3 training code on
Turris Omnia, via an U-Boot environment variable
Marek
Marek Behún (10):
ddr: marvell: a38x: debug: return from ddr3_tip_print_log() early if
we
Now that Turris Omnia has a rng driver provided in the MCU driver,
enable the rng command in defconfig.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
configs/turris_omnia_defconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/configs/turris_omnia_defconfig b/configs
Add support for true random number generator provided by the MCU on
Turris Omnia. The MCU firmware supports TRNG if the FEAT_TRNG bit is set
in features. In that case we bind the rng driver.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
configs/turris_omnia_defconfig | 1
In the rng command, print
Abort
instead of
Reading RNG failed
if the error number is -EINTR, which can happen if the user pressed
CTRL-C.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
cmd/rng.c | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/cmd/rng.c
Enable support for the poweroff command via sysreset for Turris Omnia.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
configs/turris_omnia_defconfig | 2 ++
1 file changed, 2 insertions(+)
diff --git a/configs/turris_omnia_defconfig b/configs/turris_omnia_defconfig
index 9d5171c6a8
device are bound as child devices of the MCU device.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
configs/turris_omnia_defconfig| 1 +
drivers/gpio/Kconfig | 7 -
drivers/gpio/Makefile | 1 -
drivers/misc/Kconfig
Update firmware features reading to try reading 32 bits of features and
fallback to reading 16 bits.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
drivers/gpio/turris_omnia_mcu.c | 32 ++--
1 file changed, 22 insertions(+), 10 deletions(-)
diff --git a
Use byteorder conversion function instead of manually assembling data
from/to MCU.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
drivers/gpio/turris_omnia_mcu.c | 80 +++--
1 file changed, 46 insertions(+), 34 deletions(-)
diff --git a/drivers/gpio
Add driver model support for sysreset via mvebu system controller. This is
currently only available for U-Boot proper.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
arch/arm/mach-mvebu/Kconfig | 18 +-
arch/arm/mach-mvebu/Makefile| 2 +-
arch/arm/mach
The mvebu-reset driver is only needed by the mvebu PCIe driver, but
currently it is automatically selected if DM_RESET is enabled. Add the
condition of PCI_MVEBU also being enabled for mvebu-reset to be
selected.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
arch/arm/mach-mvebu
The system-controller driver for 32-bit Armada is currently registered
as UCLASS_RESET, since it only provides enabling/disabling PCIe ports.
Rework it as UCLASS_SYSCON and bind mvebu-reset as a child device.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
arch/arm/mach-mvebu/Kconfig
uld not be built for SPL. Indeed the PCI_MVEBU driver
is not supported in SPL now, and so the mvebu-reset driver is not needed.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
arch/arm/mach-mvebu/Makefile | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/arch/arm/
If the FEAT_CRYPTO feature bit is present in MCU features, the board
crypto is implemented by MCU and the Atmel SHA chip is not present.
Disable Atmel SHA device-tree node in that case.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
board/CZ.NIC/turris_omnia/turris_omnia.c | 23
If MCU supports the FEAT_CRYPTO feature, read board ECDSA public key
from MCU and print it.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
board/CZ.NIC/turris_omnia/turris_omnia.c | 25 +++-
1 file changed, 24 insertions(+), 1 deletion(-)
diff --git a/board
Implement reading board serial number, first MAC address and board
version from MCU. MCU supports board information if the FEAT_BOARD_INFO
feature bit is set in MCU features.
Prefer getting board information from MCU if supported, fallback to
Atmel SHA chip.
Signed-off-by: Marek Behún
Reviewed
.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
board/CZ.NIC/turris_omnia/turris_omnia.c | 100 +++
1 file changed, 68 insertions(+), 32 deletions(-)
diff --git a/board/CZ.NIC/turris_omnia/turris_omnia.c
b/board/CZ.NIC/turris_omnia/turris_omnia.c
index 87e33d88c4
he second print.
Fixes: 8cd4bf7dc9ba ("turris: Use checkboard() instead of show_board_info()")
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
board/CZ.NIC/turris_mox/turris_mox.c | 5 +
board/CZ.NIC/turris_omnia/turris_omnia.c | 1 -
2 files changed, 1 insertion(+), 5 d
Add header containing all MCU command definitions and use it in board
code and in MCU driver.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
board/CZ.NIC/turris_omnia/turris_omnia.c | 81 +++-
drivers/gpio/turris_omnia_mcu.c | 54 +
include/turris-omnia-mcu
U-Boot builds for Turris Omnia are approaching the limit of 0xf
bytes, which is the size of the U-Boot partition on Omnia.
Enable LTO to get more size optimized binaries.
Signed-off-by: Marek Behún
Reviewed-by: Stefan Roese
---
configs/turris_omnia_defconfig | 1 +
1 file changed, 1
://patchwork.ozlabs.org/project/uboot/cover/20240323180711.5498-1-ka...@kernel.org/
https://patchwork.ozlabs.org/project/uboot/cover/20240327162355.24584-1-ka...@kernel.org/
Marek Behún (18):
arm: mvebu: turris_omnia: Enable LTO by default on Turris Omnia
arm: mvebu: turris_omnia: Add header containing MCU
On Thu, 4 Apr 2024 08:38:02 +0200
Stefan Roese wrote:
> Hi Marek,
>
> On 3/27/24 17:23, Marek Behún wrote:
> > Hi Stefan,
> >
> > this is v3 of series adding support for new board revision of Turris
> > Omnia.
> >
> > Changes since v2:
> &
On Thu, 28 Mar 2024 14:01:22 +0100
Stefan Roese wrote:
> On 3/28/24 12:21, Marek Behún wrote:
> > On Thu, 28 Mar 2024 11:04:45 +0100
> > Stefan Roese wrote:
> >
> >>> +static int mvebu_sysreset_request(struct udevice *dev, enum sysreset_t
> >>>
On Thu, 28 Mar 2024 11:04:45 +0100
Stefan Roese wrote:
> > +static int mvebu_sysreset_request(struct udevice *dev, enum sysreset_t
> > type)
> > +{
> > + struct regmap *regmap = syscon_get_regmap(dev->parent);
> > + uint bit;
> > +
> > + if (type != SYSRESET_COLD)
> > + return -E
On Thu, 28 Mar 2024 10:56:01 +0100
Stefan Roese wrote:
> On 3/27/24 17:23, Marek Behún wrote:
> > Implement reading board serial number, first MAC address and board
> > version from MCU. MCU supports board information if the FEAT_BOARD_INFO
> > feature bit is set in MCU feat
Now that Turris Omnia has a rng driver provided in the MCU driver,
enable the rng command in defconfig.
Signed-off-by: Marek Behún
---
configs/turris_omnia_defconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/configs/turris_omnia_defconfig b/configs/turris_omnia_defconfig
index
Add support for true random number generator provided by the MCU on
Turris Omnia. The MCU firmware supports TRNG if the FEAT_TRNG bit is set
in features. In that case we bind the rng driver.
Signed-off-by: Marek Behún
---
configs/turris_omnia_defconfig | 1 +
drivers/misc/Kconfig
In the rng command, print
Abort
instead of
Reading RNG failed
if the error number is -EINTR, which can happen if the user pressed
CTRL-C.
Signed-off-by: Marek Behún
---
cmd/rng.c | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/cmd/rng.c b/cmd/rng.c
index
Enable support for the poweroff command via sysreset for Turris Omnia.
Signed-off-by: Marek Behún
---
configs/turris_omnia_defconfig | 2 ++
1 file changed, 2 insertions(+)
diff --git a/configs/turris_omnia_defconfig b/configs/turris_omnia_defconfig
index 9d5171c6a8..0df0f3c90b 100644
--- a
device are bound as child devices of the MCU device.
Signed-off-by: Marek Behún
---
configs/turris_omnia_defconfig| 1 +
drivers/gpio/Kconfig | 7 -
drivers/gpio/Makefile | 1 -
drivers/misc/Kconfig | 10 ++
drivers
Update firmware features reading to try reading 32 bits of features and
fallback to reading 16 bits.
Signed-off-by: Marek Behún
---
drivers/gpio/turris_omnia_mcu.c | 32 ++--
1 file changed, 22 insertions(+), 10 deletions(-)
diff --git a/drivers/gpio
Use byteorder conversion function instead of manually assembling data
from/to MCU.
Signed-off-by: Marek Behún
---
drivers/gpio/turris_omnia_mcu.c | 80 +++--
1 file changed, 46 insertions(+), 34 deletions(-)
diff --git a/drivers/gpio/turris_omnia_mcu.c b/drivers
The mvebu-reset driver is only needed by the mvebu PCIe driver, but
currently it is automatically selected if DM_RESET is enabled. Add the
condition of PCI_MVEBU also being enabled for mvebu-reset to be
selected.
Signed-off-by: Marek Behún
---
arch/arm/mach-mvebu/Kconfig | 2 +-
1 file changed
Add driver model support for sysreset via mvebu system controller. This is
currently only available for U-Boot proper.
Signed-off-by: Marek Behún
---
arch/arm/mach-mvebu/Kconfig | 18 +-
arch/arm/mach-mvebu/Makefile| 2 +-
arch/arm/mach-mvebu/cpu.c
The system-controller driver for 32-bit Armada is currently registered
as UCLASS_RESET, since it only provides enabling/disabling PCIe ports.
Rework it as UCLASS_SYSCON and bind mvebu-reset as a child device.
Signed-off-by: Marek Behún
---
arch/arm/mach-mvebu/Kconfig | 11
uld not be built for SPL. Indeed the PCI_MVEBU driver
is not supported in SPL now, and so the mvebu-reset driver is not needed.
Signed-off-by: Marek Behún
---
arch/arm/mach-mvebu/Makefile | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-mvebu/Makefile b/arch/arm/
If the FEAT_CRYPTO feature bit is present in MCU features, the board
crypto is implemented by MCU and the Atmel SHA chip is not present.
Disable Atmel SHA device-tree node in that case.
Signed-off-by: Marek Behún
---
board/CZ.NIC/turris_omnia/turris_omnia.c | 23 +++
1 file
If MCU supports the FEAT_CRYPTO feature, read board ECDSA public key
from MCU and print it.
Signed-off-by: Marek Behún
---
board/CZ.NIC/turris_omnia/turris_omnia.c | 25 +++-
1 file changed, 24 insertions(+), 1 deletion(-)
diff --git a/board/CZ.NIC/turris_omnia
Implement reading board serial number, first MAC address and board
version from MCU. MCU supports board information if the FEAT_BOARD_INFO
feature bit is set in MCU features.
Prefer getting board information from MCU if supported, fallback to
Atmel SHA chip.
Signed-off-by: Marek Behún
.
Signed-off-by: Marek Behún
---
board/CZ.NIC/turris_omnia/turris_omnia.c | 100 +++
1 file changed, 68 insertions(+), 32 deletions(-)
diff --git a/board/CZ.NIC/turris_omnia/turris_omnia.c
b/board/CZ.NIC/turris_omnia/turris_omnia.c
index 87e33d88c4..6dfde5ee7a 100644
--- a
Add header containing all MCU command definitions and use it in board
code and in MCU driver.
Signed-off-by: Marek Behún
---
board/CZ.NIC/turris_omnia/turris_omnia.c | 81 +++-
drivers/gpio/turris_omnia_mcu.c | 54 +
include/turris-omnia-mcu-interface.h | 248
he second print.
Fixes: 8cd4bf7dc9ba ("turris: Use checkboard() instead of show_board_info()")
Signed-off-by: Marek Behún
---
board/CZ.NIC/turris_mox/turris_mox.c | 5 +
board/CZ.NIC/turris_omnia/turris_omnia.c | 1 -
2 files changed, 1 insertion(+), 5 deletions(-)
diff --git
1 - 100 of 1051 matches
Mail list logo