SHA-256 hash verification of flash slots, pico_hash_binary, flash:: namespace, ring_buffer iterator, non-destructive log
This commit is contained in:
@@ -8,6 +8,7 @@
|
||||
#include "msgpack.h"
|
||||
#include "halfsiphash.h"
|
||||
#include "static_vector.h"
|
||||
#include "flash.h"
|
||||
|
||||
struct Envelope {
|
||||
static constexpr int8_t ext_id = 0;
|
||||
@@ -128,19 +129,11 @@ struct RequestFlashStatus {
|
||||
auto as_tuple() { return std::tie(); }
|
||||
};
|
||||
|
||||
struct SlotInfo {
|
||||
bool valid;
|
||||
uint32_t version;
|
||||
bool hash_ok;
|
||||
auto as_tuple() const { return std::tie(valid, version, hash_ok); }
|
||||
auto as_tuple() { return std::tie(valid, version, hash_ok); }
|
||||
};
|
||||
|
||||
struct ResponseFlashStatus {
|
||||
static constexpr int8_t ext_id = 15;
|
||||
int8_t boot_partition;
|
||||
SlotInfo slot_a;
|
||||
SlotInfo slot_b;
|
||||
flash::slot slot_a;
|
||||
flash::slot slot_b;
|
||||
auto as_tuple() const { return std::tie(boot_partition, slot_a, slot_b); }
|
||||
auto as_tuple() { return std::tie(boot_partition, slot_a, slot_b); }
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user