firmware-utils/tplink-safeloader: soft-version magic is data length
authorSander Vanheule <sander@svanheule.net>
Sat, 11 Jul 2020 20:58:07 +0000 (22:58 +0200)
committerStijn Tintel <stijn@linux-ipv6.be>
Wed, 9 Sep 2020 17:41:50 +0000 (20:41 +0300)
commitd583cca9e201f9b62baded2d1b8e75a60109159d
tree37569c6d6deb03e88122a75d69cb1ba84eb11d37
parent9ac5a269b57cefd81324ac4ab3cbf9a6e80abc45
firmware-utils/tplink-safeloader: soft-version magic is data length

The soft-version partition actually contains a header and trailing data:
* header: {data length, [zero]}
* data: {version, bcd encoded date, revision}

The data length is currently treated as a magic number, but should
contain the length of the partition data.

This header is also present the following partitions (non-exhaustive):
* string-based soft-version
* support-list

Signed-off-by: Sander Vanheule <sander@svanheule.net>
src/tplink-safeloader.c