summaryrefslogtreecommitdiff
path: root/verify.h
diff options
context:
space:
mode:
authorJens Axboe <jens.axboe@oracle.com>2009-08-09 22:40:33 +0200
committerJens Axboe <jens.axboe@oracle.com>2009-08-09 22:40:33 +0200
commit7c353ceb3257b132f4c98326046b42201e070731 (patch)
tree3cdd3df7024714a8e46dc0b8cefee05b1af29fec /verify.h
parenta1c58075279454a91ec43366846b93e8dcf9753c (diff)
downloadfio-7c353ceb3257b132f4c98326046b42201e070731.tar.gz
fio-7c353ceb3257b132f4c98326046b42201e070731.tar.bz2
Add Linus' optimized sha1 hash for checksum
It does appear to be pretty fast. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'verify.h')
-rw-r--r--verify.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/verify.h b/verify.h
index 50c8e432..c12bc7d0 100644
--- a/verify.h
+++ b/verify.h
@@ -15,6 +15,7 @@ enum {
VERIFY_SHA256, /* sha256 sum data blocks */
VERIFY_SHA512, /* sha512 sum data blocks */
VERIFY_META, /* block_num, timestamp etc. */
+ VERIFY_SHA1, /* sha1 sum data blocks */
VERIFY_NULL, /* pretend to verify */
};
@@ -38,6 +39,9 @@ struct vhdr_sha512 {
struct vhdr_sha256 {
uint8_t sha256[128];
};
+struct vhdr_sha1 {
+ uint32_t sha1[5];
+};
struct vhdr_crc64 {
uint64_t crc64;
};