Wojciech Nizinski 355aab94d1 fastboot: fix CRC32 chunk size checking
genimage create android-sparse file with CRC32 chunk at end. When
U-Boot's fastboot receives this chunk it returns error message:
`Fail Bogus chunk size for chunk type Dont Care`

According to reference implementation of Android's sparse file format:

<https://android.googlesource.com/platform/system/core/+/refs/heads/main/
libsparse/output_file.cpp#513>

the chunk_header.total_sz is CHUNK_HEADER_LEN + 4 (CRC32 size).

Signed-off-by: Wojciech Nizinski <niziak@spox.org>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
Tested-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> # on vim3
Link: https://lore.kernel.org/r/20230925103714.4153612-1-niziak@spox.org
Signed-off-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
2023-10-31 14:36:30 +01:00
..
2023-06-12 14:55:33 -04:00
2022-01-18 08:31:02 -05:00
2023-10-12 08:32:27 +02:00
2023-08-25 13:54:33 -04:00
2022-01-19 18:11:34 +01:00
2022-08-12 08:14:23 -04:00
2023-01-20 12:27:24 -05:00
2021-09-04 12:26:01 -04:00
2022-03-15 16:19:29 -04:00
2023-01-16 18:01:10 +08:00
2021-07-14 16:57:35 -04:00
2023-02-11 12:22:34 -05:00
2021-07-15 18:42:05 -04:00
2022-01-19 18:11:34 +01:00
2023-10-27 13:14:47 +03:00
2023-08-25 17:55:19 -04:00