diff options
Diffstat (limited to 'src/ec/google')
-rw-r--r-- | src/ec/google/chromeec/vboot_storage.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ec/google/chromeec/vboot_storage.c b/src/ec/google/chromeec/vboot_storage.c index f708b3e680..63e131448a 100644 --- a/src/ec/google/chromeec/vboot_storage.c +++ b/src/ec/google/chromeec/vboot_storage.c @@ -14,8 +14,8 @@ int vboot_save_hash(void *digest, size_t digest_size) uint32_t lock_status; int num_slots; - /* Ensure the digests being saved match the EC's slot size. */ - assert(digest_size == EC_VSTORE_SLOT_SIZE); + /* Ensure the digests being saved does not exceed the EC's slot size. */ + assert(digest_size > 0 && digest_size <= EC_VSTORE_SLOT_SIZE); if (google_chromeec_vstore_write(slot, digest, digest_size)) return -1; |