Disable verification for now & add memcmp32sparse

When the commit with the configuration will be a available, these 3 options will exist:

- Disable verification
- Sparse verification (Fast)
- Full (Slow)

Sparse will take approx 8 minutes for rawnand.bin and Full will take 4.5 hours.
This commit is contained in:
Kostas Missos
2018-06-24 23:02:35 +03:00
parent 60f4000e9d
commit c215b1c74c
3 changed files with 62 additions and 15 deletions

View File

@@ -49,3 +49,31 @@ u32 crc32c(const void *buf, u32 len)
}
return ~crc;
}
u32 memcmp32sparse(const u32 *buf1, const u32 *buf2, u32 len)
{
u32 len32 = len / 4;
if (!(len32 % 32))
{
while (len32)
{
len32 -= 32;
if(buf1[len32] != buf2[len32])
return 1;
}
}
else
{
while (len32)
{
len32 -= 32;
if(buf1[len32] != buf2[len32])
return 1;
if (len32 < 32)
return 0;
}
}
return 0;
}