crc32.h File Reference

CRC-32 utility functions. More...

Functions

uint32_t spdk_crc32_ieee_update (const void *buf, size_t len, uint32_t crc)
 Calculate a partial CRC-32 IEEE checksum. More...
 
uint32_t spdk_crc32c_update (const void *buf, size_t len, uint32_t crc)
 Calculate a partial CRC-32C checksum. More...
 
uint32_t spdk_crc32c_iov_update (struct iovec *iov, int iovcnt, uint32_t crc32c)
 Calculate a partial CRC-32C checksum. More...
 

Detailed Description

CRC-32 utility functions.

Function Documentation

◆ spdk_crc32_ieee_update()

uint32_t spdk_crc32_ieee_update ( const void *  buf,
size_t  len,
uint32_t  crc 
)

Calculate a partial CRC-32 IEEE checksum.

Parameters
bufData buffer to checksum.
lenLength of buf in bytes.
crcPrevious CRC-32 value.
Returns
Updated CRC-32 value.

◆ spdk_crc32c_iov_update()

uint32_t spdk_crc32c_iov_update ( struct iovec *  iov,
int  iovcnt,
uint32_t  crc32c 
)

Calculate a partial CRC-32C checksum.

Parameters
iovData buffer vectors to checksum.
iovcntsize of iov parameter.
crc32cPrevious CRC-32C value.
Returns
Updated CRC-32C value.

◆ spdk_crc32c_update()

uint32_t spdk_crc32c_update ( const void *  buf,
size_t  len,
uint32_t  crc 
)

Calculate a partial CRC-32C checksum.

Parameters
bufData buffer to checksum.
lenLength of buf in bytes.
crcPrevious CRC-32C value.
Returns
Updated CRC-32C value.