diff options
author | Thomas Huth <thuth@redhat.com> | 2016-08-03 21:34:44 +0200 |
---|---|---|
committer | Alexey Kardashevskiy <aik@ozlabs.ru> | 2016-08-16 18:53:05 +1000 |
commit | 1bf942576814e1b3dd745b51ad2b8de050ce5e62 (patch) | |
tree | d7ba6cbc4fc4d0a3f118fe07dff9c48e803eb575 /include | |
parent | a518b808658f37d329b88254c0016780d3c4d5ba (diff) | |
download | SLOF-1bf942576814e1b3dd745b51ad2b8de050ce5e62.zip SLOF-1bf942576814e1b3dd745b51ad2b8de050ce5e62.tar.gz SLOF-1bf942576814e1b3dd745b51ad2b8de050ce5e62.tar.bz2 |
Remove misleading padding fields from ROM header definition
The first two bytes of the date field are unused - and the date
is indeed encoded in the following six bytes, i.e. also using
the padding bytes. So the header definition is currently very
confusing. Let's simply remove the padding fields and make the
date field a little bit bigger instead - and add a proper comment
about the encoding of the date field.
Signed-off-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Adrian Reber <areber@redhat.com>
Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Diffstat (limited to 'include')
-rw-r--r-- | include/calculatecrc.h | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/include/calculatecrc.h b/include/calculatecrc.h index 26a90df..a19a229 100644 --- a/include/calculatecrc.h +++ b/include/calculatecrc.h @@ -26,10 +26,8 @@ struct stH { uint64_t flashlen; // dyn char version[16]; // $DRIVER_INFO alignment! char platform_name[32]; // (hardware) headerfile - char date[6]; // dyn (format -> JB) - char padding1[2]; // padding byte - char mdate[6]; // modify date - char padding2[2]; // padding byte + char date[8]; // BCD encoded creation date (first two bytes unused) + char mdate[8]; // BCD encoded modification date (first two bytes unused) char platform_revision[4];// (hardware) headerfile uint32_t padding; uint64_t ui64CRC; // insert calculated CRC here |