[PATCH v3 9/9] test: fs: Add test to detect fat type

2023-11-15 Thread christian . taedcke-oss
From: Christian Taedcke Ensure that a large FAT12 filesystem and a small FAT16 filesystem are detected correctly. Signed-off-by: Christian Taedcke --- Changes in v3: - Add test to detect fat fs type test/py/tests/test_fs/conftest.py| 47

[PATCH v3 8/9] test: Add size granularity parameter to mk_fs

2023-11-15 Thread christian . taedcke-oss
From: Christian Taedcke Without this commit it is only possible to create filesystem images with a size granularity of 1MB. This commit adds the option to create file systems with different sizes, e.g 8.5MB. Signed-off-by: Christian Taedcke --- (no changes since v1)

[PATCH v3 7/9] test: fs: Add fat12 to supported fs of some tests

2023-11-15 Thread christian . taedcke-oss
From: Christian Taedcke The tests fs_ext, fs_mkdir and fs_unlink support fat12 without modifications. The fs_basic test uses a partition that is too large for fat12, so it is omitted here. Signed-off-by: Christian Taedcke --- Changes in v3: - Enable some fs tests for FAT12

[PATCH v3 6/9] test: Add support to create a fat12 fs

2023-11-15 Thread christian . taedcke-oss
From: Christian Taedcke This enables to implement tests for fat12 filesystem. Signed-off-by: Christian Taedcke --- (no changes since v1) test/py/tests/fs_helper.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/py/tests/fs_helper.py b/test/py/tests/fs_helper.py

[PATCH v3 5/9] fs: fat: add bootsector validity check

2023-11-15 Thread christian . taedcke-oss
From: Christian Taedcke The performed checks are similar to the checks performed by the Linux kernel in the function fat_read_bpb() in the file fs/fat/inode.c. Signed-off-by: Christian Taedcke --- (no changes since v2) Changes in v2: - Add validity checks for boot sector fs/fat/fat.c | 53

[PATCH v3 3/9] fs: fat: calculate FAT type based on cluster count

2023-11-15 Thread christian . taedcke-oss
From: Christian Taedcke This fixes an issue where the FAT type (FAT12, FAT16) is not correctly detected, e.g. when the BPB field BS_FilSysType contains the valid value "FAT ". According to the FAT spec the field BS_FilSysType has only informational character and does not determine the FAT

[PATCH v3 0/9] fs: fat: calculate FAT type based on cluster count

2023-11-15 Thread christian . taedcke-oss
From: Christian Taedcke This series fixes an issue where the FAT type (FAT12, FAT16) is not correctly detected, e.g. when the BPB field BS_FilSysType contains the valid value "FAT ". This issue occures, for example, if a partition is formatted by swupdate using its diskformat handler.

[PATCH v3 4/9] fs: fat: simplify gotos from read_bootsectandvi

2023-11-15 Thread christian . taedcke-oss
From: Christian Taedcke This simplifies the code a little bit. Signed-off-by: Christian Taedcke --- (no changes since v2) Changes in v2: - Keep one goto label instead of removing both - Move changing gotos from read_bootsectandvi() into separate commit fs/fat/fat.c | 9 - 1 file

[PATCH v3 2/9] test: spl: Remove usage of FAT32_SIGN

2023-11-15 Thread christian . taedcke-oss
From: Christian Taedcke FAT32_SIGN is removed in the following commits. Signed-off-by: Christian Taedcke --- (no changes since v2) Changes in v2: - Move code change in test/image/spl_load_fs.c into separate commit test/image/spl_load_fs.c | 2 +- 1 file changed, 1 insertion(+), 1

[PATCH v3 1/9] fs: fat: use get_unaligned_le16 to convert u8[2] to u16

2023-11-15 Thread christian . taedcke-oss
From: Christian Taedcke This reduces code duplications. Signed-off-by: Christian Taedcke --- (no changes since v2) Changes in v2: - Use get_unaligned_le16 instead of custom macro fs/fat/fat.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/fs/fat/fat.c

[PATCH v2 5/5] fs: fat: add bootsector validity check

2023-11-10 Thread christian . taedcke-oss
From: Christian Taedcke The performed checks are similar to the checks performed by the Linux kernel in the function fat_read_bpb() in the file fs/fat/inode.c. Signed-off-by: Christian Taedcke --- Changes in v2: - Add validity checks for boot sector fs/fat/fat.c | 53

[PATCH v2 3/5] fs: fat: calculate FAT type based on cluster count

2023-11-10 Thread christian . taedcke-oss
From: Christian Taedcke This fixes an issue where the FAT type (FAT12, FAT16) is not correctly detected, e.g. when the BPB field BS_FilSysType contains the valid value "FAT ". According to the FAT spec the field BS_FilSysType has only informational character and does not determine the FAT

[PATCH v2 4/5] fs: fat: simplify gotos from read_bootsectandvi

2023-11-10 Thread christian . taedcke-oss
From: Christian Taedcke This simplifies the code a little bit. Signed-off-by: Christian Taedcke --- Changes in v2: - Keep one goto label instead of removing both - Move changing gotos from read_bootsectandvi() into separate commit fs/fat/fat.c | 9 - 1 file changed, 4 insertions(+),

[PATCH v2 2/5] test: spl: Remove usage of FAT32_SIGN

2023-11-10 Thread christian . taedcke-oss
From: Christian Taedcke FAT32_SIGN is removed in the following commits. Signed-off-by: Christian Taedcke --- Changes in v2: - Move code change in test/image/spl_load_fs.c into separate commit test/image/spl_load_fs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH v2 0/5] fs: fat: calculate FAT type based on cluster count

2023-11-10 Thread christian . taedcke-oss
From: Christian Taedcke This series fixes an issue where the FAT type (FAT12, FAT16) is not correctly detected, e.g. when the BPB field BS_FilSysType contains the valid value "FAT ". This issue occures, for example, if a partition is formatted by swupdate using its diskformat handler.

[PATCH v2 1/5] fs: fat: use get_unaligned_le16 to convert u8[2] to u16

2023-11-10 Thread christian . taedcke-oss
From: Christian Taedcke This reduces code duplications. Signed-off-by: Christian Taedcke --- Changes in v2: - Use get_unaligned_le16 instead of custom macro fs/fat/fat.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/fs/fat/fat.c b/fs/fat/fat.c index

[PATCH v1 2/2] fs: fat: calculate FAT type based on cluster count

2023-11-08 Thread christian . taedcke-oss
From: Christian Taedcke This fixes an issue where the FAT type (FAT12, FAT16) is not correctly detected, e.g. when the BPB field BS_FilSysType contains the valid value "FAT ". According to the FAT spec the field BS_FilSysType has only informational character and does not determine the FAT

[PATCH v1 1/2] fs: fat: add macro to convert u8[2] to u16

2023-11-08 Thread christian . taedcke-oss
From: Christian Taedcke This reduces code duplications. Signed-off-by: Christian Taedcke --- fs/fat/fat.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/fs/fat/fat.c b/fs/fat/fat.c index 8ff1fd0ec8..8a0f4e4e6c 100644 --- a/fs/fat/fat.c +++ b/fs/fat/fat.c @@

[PATCH v1 0/2] fs: fat: calculate FAT type based on cluster count

2023-11-08 Thread christian . taedcke-oss
From: Christian Taedcke This series fixes an issue where the FAT type (FAT12, FAT16) is not correctly detected, e.g. when the BPB field BS_FilSysType contains the valid value "FAT ". This issue occures, for example, if a partition is formatted by swupdate using its diskformat handler.

[PATCH v4] xilinx: zynqmp: Extract aes operation into new file

2023-07-25 Thread christian . taedcke-oss
From: Christian Taedcke This moves the aes operation that is performed by the pmu into a separate file. This way it can be called not just from the shell command, but also e.g. from board initialization code. Signed-off-by: Christian Taedcke --- Changes in v4: - remove redundant () around

[PATCH v7 3/3] binman: Add tests for etype encrypted

2023-07-24 Thread christian . taedcke-oss
From: Christian Taedcke Add tests to reach 100% code coverage for the added etype encrypted. Signed-off-by: Christian Taedcke Reviewed-by: Simon Glass --- (no changes since v5) Changes in v5: - add comments to test functions Changes in v4: - fix failing test testEncryptedKeyFile Changes

[PATCH v7 2/3] binman: Allow cipher node as special section

2023-07-24 Thread christian . taedcke-oss
From: Christian Taedcke The new encrypted etype generates a cipher node in the device tree that should not be evaluated by binman, but still be kept in the output device tree. Signed-off-by: Christian Taedcke Reviewed-by: Simon Glass --- (no changes since v3) Changes in v3: - rebase on

[PATCH v7 1/3] binman: Add support for externally encrypted blobs

2023-07-24 Thread christian . taedcke-oss
From: Christian Taedcke This adds a new etype encrypted. It creates a new cipher node in the related image similar to the cipher node used by u-boot, see boot/image-cipher.c. Signed-off-by: Christian Taedcke Reviewed-by: Simon Glass --- Changes in v7: - add revieved-by to all commits -

[PATCH v7 0/3] binman: Add support for externally encrypted blobs

2023-07-24 Thread christian . taedcke-oss
From: Christian Taedcke This series adds the functionality to handle externally encrypted blobs to binman. It includes the functionality itself and the corresponding unit tests. The following block shows an example on how to use this functionality. In the device tree that is parsed by binman a

[PATCH v5] event: Add fpga load event

2023-07-20 Thread christian . taedcke-oss
From: Christian Taedcke This enables implementing custom logic after a bitstream was loaded into the fpga. Signed-off-by: Christian Taedcke Reviewed-by: Simon Glass --- Changes in v5: - remove changes from kmcent2 board file - add missing include to event.h Changes in v4: - add include

[PATCH v4 2/2] event: Add fpga load event

2023-07-19 Thread christian . taedcke-oss
From: Christian Taedcke This enables implementing custom logic after a bitstream was loaded into the fpga. Signed-off-by: Christian Taedcke Reviewed-by: Simon Glass --- (no changes since v3) Changes in v3: - replace #if with if - remove previously added printf - return notification error

[PATCH v4 1/2] board/km/cent2: add include common.h

2023-07-19 Thread christian . taedcke-oss
From: Christian Taedcke Including common.h before event.h is required, because the new fpga load event in event.h uses the size_t type. Signed-off-by: Christian Taedcke --- Changes in v4: - add include common.h to kmcent2 board file board/keymile/kmcent2/kmcent2.c | 1 + 1 file changed, 1

[PATCH v3] xilinx: zynqmp: Extract aes operation into new file

2023-07-18 Thread christian . taedcke-oss
From: Christian Taedcke This moves the aes operation that is performed by the pmu into a separate file. This way it can be called not just from the shell command, but also e.g. from board initialization code. Signed-off-by: Christian Taedcke --- Changes in v3: - fix function doc format

[PATCH v6 3/3] binman: Add tests for etype encrypted

2023-07-17 Thread christian . taedcke-oss
From: Christian Taedcke Add tests to reach 100% code coverage for the added etype encrypted. Signed-off-by: Christian Taedcke --- (no changes since v5) Changes in v5: - add comments to test functions Changes in v4: - fix failing test testEncryptedKeyFile Changes in v3: - rebase on

[PATCH v6 1/3] binman: Add support for externally encrypted blobs

2023-07-17 Thread christian . taedcke-oss
From: Christian Taedcke This adds a new etype encrypted. It creates a new cipher node in the related image similar to the cipher node used by u-boot, see boot/image-cipher.c. Signed-off-by: Christian Taedcke --- Changes in v6: - fix documentation of encrypted etype Changes in v5: -

[PATCH v6 2/3] binman: Allow cipher node as special section

2023-07-17 Thread christian . taedcke-oss
From: Christian Taedcke The new encrypted etype generates a cipher node in the device tree that should not be evaluated by binman, but still be kept in the output device tree. Signed-off-by: Christian Taedcke --- (no changes since v3) Changes in v3: - rebase on u-boot-dm/mkim-working

[PATCH v6 0/3] binman: Add support for externally encrypted blobs

2023-07-17 Thread christian . taedcke-oss
From: Christian Taedcke This series adds the functionality to handle externally encrypted blobs to binman. It includes the functionality itself and the corresponding unit tests. The following block shows an example on how to use this functionality. In the device tree that is parsed by binman a

[PATCH v5 3/3] binman: Add tests for etype encrypted

2023-07-14 Thread christian . taedcke-oss
From: Christian Taedcke Add tests to reach 100% code coverage for the added etype encrypted. Signed-off-by: Christian Taedcke --- Changes in v5: - add comments to test functions Changes in v4: - fix failing test testEncryptedKeyFile Changes in v3: - rebase on u-boot-dm/mkim-working - remove

[PATCH v5 2/3] binman: Allow cipher node as special section

2023-07-14 Thread christian . taedcke-oss
From: Christian Taedcke The new encrypted etype generates a cipher node in the device tree that should not be evaluated by binman, but still be kept in the output device tree. Signed-off-by: Christian Taedcke --- (no changes since v3) Changes in v3: - rebase on u-boot-dm/mkim-working

[PATCH v5 1/3] binman: Add support for externally encrypted blobs

2023-07-14 Thread christian . taedcke-oss
From: Christian Taedcke This adds a new etype encrypted. It creates a new cipher node in the related image similar to the cipher node used by u-boot, see boot/image-cipher.c. Signed-off-by: Christian Taedcke --- Changes in v5: - encrypted entry now inherits from Entry - remove unnecessary

[PATCH v5 0/3] binman: Add support for externally encrypted blobs

2023-07-14 Thread christian . taedcke-oss
From: Christian Taedcke This series adds the functionality to handle externally encrypted blobs to binman. It includes the functionality itself and the corresponding unit tests. The following block shows an example on how to use this functionality. In the device tree that is parsed by binman a

[PATCH v3] event: Add fpga load event

2023-07-12 Thread christian . taedcke-oss
From: Christian Taedcke This enables implementing custom logic after a bitstream was loaded into the fpga. Signed-off-by: Christian Taedcke --- Changes in v3: - replace #if with if - remove previously added printf - return notification error from fpga_load() - fix static_assert checking event

[PATCH v2] event: Add fpga load event

2023-07-11 Thread christian . taedcke-oss
From: Christian Taedcke This enables implementing custom logic after a bitstream was loaded into the fpga. Signed-off-by: Christian Taedcke --- Changes in v2: - replace __weak function with a new event drivers/fpga/fpga.c | 18 ++ include/event.h | 16 2

[PATCH v2] xilinx: zynqmp: Extract aes operation into new file

2023-07-10 Thread christian . taedcke-oss
From: Christian Taedcke This moves the aes operation that is performed by the pmu into a separate file. This way it can be called not just from the shell command, but also e.g. from board initialization code. Signed-off-by: Christian Taedcke --- Changes in v2: - convert doxygen comments to

[PATCH v4 3/3] binman: Add tests for etype encrypted

2023-07-10 Thread christian . taedcke-oss
From: Christian Taedcke Add tests to reach 100% code coverage for the added etype encrypted. Signed-off-by: Christian Taedcke --- Changes in v4: - fix failing test testEncryptedKeyFile Changes in v3: - rebase on u-boot-dm/mkim-working - remove unnecessary test testEncryptedNoContent - wrap

[PATCH v4 2/3] binman: Allow cipher node as special section

2023-07-10 Thread christian . taedcke-oss
From: Christian Taedcke The new encrypted etype generates a cipher node in the device tree that should not be evaluated by binman, but still be kept in the output device tree. Signed-off-by: Christian Taedcke --- (no changes since v3) Changes in v3: - rebase on u-boot-dm/mkim-working

[PATCH v4 1/3] binman: Add support for externally encrypted blobs

2023-07-10 Thread christian . taedcke-oss
From: Christian Taedcke This adds a new etype encrypted that is derived from collection. It creates a new cipher node in the related image similar to the cipher node used by u-boot, see boot/image-cipher.c. Signed-off-by: Christian Taedcke --- (no changes since v3) Changes in v3: - rebase

[PATCH v4 0/3] binman: Add support for externally encrypted blobs

2023-07-10 Thread christian . taedcke-oss
From: Christian Taedcke This series adds the functionality to handle externally encrypted blobs to binman. It includes the functionality itself and the corresponding unit tests. The following block shows an example on how to use this functionality. In the device tree that is parsed by binman a

[PATCH v3 3/3] binman: Add tests for etype encrypted

2023-07-10 Thread christian . taedcke-oss
From: Christian Taedcke Add tests to reach 100% code coverage for the added etype encrypted. Signed-off-by: Christian Taedcke --- Changes in v3: - rebase on u-boot-dm/mkim-working - remove unnecessary test testEncryptedNoContent - wrap some lines at 80 cols Changes in v2: - adapt tests for

[PATCH v3 2/3] binman: Allow cipher node as special section

2023-07-10 Thread christian . taedcke-oss
From: Christian Taedcke The new encrypted etype generates a cipher node in the device tree that should not be evaluated by binman, but still be kept in the output device tree. Signed-off-by: Christian Taedcke --- Changes in v3: - rebase on u-boot-dm/mkim-working

[PATCH v3 1/3] binman: Add support for externally encrypted blobs

2023-07-10 Thread christian . taedcke-oss
From: Christian Taedcke This adds a new etype encrypted that is derived from collection. It creates a new cipher node in the related image similar to the cipher node used by u-boot, see boot/image-cipher.c. Signed-off-by: Christian Taedcke --- Changes in v3: - rebase on

[PATCH v3 0/3] binman: Add support for externally encrypted blobs

2023-07-10 Thread christian . taedcke-oss
From: Christian Taedcke This series adds the functionality to handle externally encrypted blobs to binman. It includes the functionality itself and the corresponding unit tests. The following block shows an example on how to use this functionality. In the device tree that is parsed by binman a

[PATCH v2 3/3] binman: Add tests for etype encrypted

2023-07-04 Thread christian . taedcke-oss
From: Christian Taedcke Add tests to reach 100% code coverage for the added etype encrypted. Signed-off-by: Christian Taedcke --- Changes in v2: - adapt tests for changed entry implementation tools/binman/ftest.py | 52 +++

[PATCH v2 2/3] binman: Allow cipher node as special section

2023-07-04 Thread christian . taedcke-oss
From: Christian Taedcke The new encrypted etype generates a cipher node in the device tree that should not be evaluated by binman, but still be kept in the output device tree. Signed-off-by: Christian Taedcke --- (no changes since v1) tools/binman/etype/section.py | 2 +- 1 file changed, 1

[PATCH v2 1/3] binman: Add support for externally encrypted blobs

2023-07-04 Thread christian . taedcke-oss
From: Christian Taedcke This adds a new etype encrypted that is derived from collection. It creates a new cipher node in the related image similar to the cipher node used by u-boot, see boot/image-cipher.c. Signed-off-by: Christian Taedcke --- Changes in v2: - remove global /cipher node -

[PATCH v2 0/3] binman: Add support for externally encrypted blobs

2023-07-04 Thread christian . taedcke-oss
From: Christian Taedcke This series adds the functionality to handle externally encrypted blobs to binman. It includes the functionality itself and the corresponding unit tests. The following block shows an example on how to use this functionality. In the device tree that is parsed by binman a

[PATCH] spl: Add function called after fpga image upload

2023-06-27 Thread christian . taedcke-oss
From: Christian Taedcke This way custom logic can be implemented per board after the fpga image is uploaded. Signed-off-by: Christian Taedcke --- common/spl/spl_fit.c | 13 + 1 file changed, 13 insertions(+) diff --git a/common/spl/spl_fit.c b/common/spl/spl_fit.c index

[PATCH] xilinx: zynqmp: Extract aes operation into new file

2023-06-27 Thread christian . taedcke-oss
From: Christian Taedcke This moves the aes operation that is perfomed by the pmu into a separate file. This way it can be called not just from the shell command, but also e.g. from board initialization code. Signed-off-by: Christian Taedcke --- arch/arm/mach-zynqmp/Makefile |

[PATCH 3/3] binman: Add tests for etype encrypted

2023-06-27 Thread christian . taedcke-oss
From: Christian Taedcke Add tests to reach 100% code coverage for the added etype encrypted. Signed-off-by: Christian Taedcke --- tools/binman/ftest.py | 69 +++ .../binman/test/282_encrypted_no_content.dts | 15

[PATCH 2/3] binman: Allow cipher node as special section

2023-06-27 Thread christian . taedcke-oss
From: Christian Taedcke The new encrypted etype generates a cipher node in the device tree that should not be evaluated by binman, but still be kept in the output device tree. Signed-off-by: Christian Taedcke --- tools/binman/etype/section.py | 2 +- 1 file changed, 1 insertion(+), 1

[PATCH 1/3] binman: Add support for externally encrypted blobs

2023-06-27 Thread christian . taedcke-oss
From: Christian Taedcke This adds a new etype encrypted that is derived from collection. It creates a new cipher node in the related image similar to the cipher node used by u-boot, see boot/image-cipher.c. Optionally it creates a global /cipher node containing a key and iv using the same

[PATCH 0/3] binman: Add support for externally encrypted blobs

2023-06-27 Thread christian . taedcke-oss
From: Christian Taedcke This series adds the functionality to handle externally encrypted blobs to binman. It includes the functionality itself and the corresponding unit tests. The generated device tree structure is similar to the structure used in the already implemented cipher node in