diff options
Diffstat (limited to 'tools/firmware-utils/src/fw.h')
-rw-r--r-- | tools/firmware-utils/src/fw.h | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/tools/firmware-utils/src/fw.h b/tools/firmware-utils/src/fw.h index 53a92a573c..778143d2c4 100644 --- a/tools/firmware-utils/src/fw.h +++ b/tools/firmware-utils/src/fw.h @@ -19,6 +19,7 @@ #ifndef FW_INCLUDED #define FW_INCLUDED +#include <stdint.h> #include <sys/types.h> #define MAGIC_HEADER "OPEN" @@ -30,16 +31,16 @@ #define PART_NAME_LENGTH 16 typedef struct header { - char magic[MAGIC_LENGTH]; - char version[256]; + uint8_t magic[MAGIC_LENGTH]; + uint8_t version[256]; u_int32_t crc; u_int32_t pad; } __attribute__ ((packed)) header_t; typedef struct part { - char magic[MAGIC_LENGTH]; - char name[PART_NAME_LENGTH]; - char pad[12]; + uint8_t magic[MAGIC_LENGTH]; + uint8_t name[PART_NAME_LENGTH]; + uint8_t pad[12]; u_int32_t memaddr; u_int32_t index; u_int32_t baseaddr; @@ -54,13 +55,13 @@ typedef struct part_crc { } __attribute__ ((packed)) part_crc_t; typedef struct signature { - char magic[MAGIC_LENGTH]; + uint8_t magic[MAGIC_LENGTH]; u_int32_t crc; u_int32_t pad; } __attribute__ ((packed)) signature_t; typedef struct signature_rsa { - char magic[MAGIC_LENGTH]; + uint8_t magic[MAGIC_LENGTH]; // u_int32_t crc; unsigned char rsa_signature[256]; u_int32_t pad; |