|
XWOS API
4.0
XWOS C/C++ API参考手册
|
XWOS通用库:CRC32 更多...

函数 | |
| xwer_t | soc_crc32_cal (xwu32_t *crc32, bool refin, xwu32_t plynml, xwu32_t direction, const xwu8_t stream[], xwsz_t *size) |
| static void | xwlib_crc32_swcal_ls (xwu32_t *crc32, bool refin, const xwu32_t table[], const xwu8_t stream[], xwsz_t *size) |
| 左移计算一段数据的CRC32校验值(直驱表法) | |
| static void | xwlib_crc32_swcal_rs (xwu32_t *crc32, bool refin, const xwu32_t table[], const xwu8_t stream[], xwsz_t *size) |
| 右移计算一段数据的CRC32校验值(直驱表法) | |
| static xwer_t | xwlib_crc32_swcal (xwu32_t *crc32, bool refin, xwu32_t plynml, xwu32_t direction, const xwu8_t stream[], xwsz_t *size) |
| 软件方式计算一段数据的CRC32校验值 | |
| xwer_t | xwlib_crc32_cal (xwu32_t *crc32, xwu32_t xorout, bool refin, bool refout, xwu32_t plynml, xwu32_t direction, const xwu8_t stream[], xwsz_t *size) |
| 计算一段数据的CRC32校验值 | |
| xwu32_t | xwlib_crc32_calms (const xwu8_t stream[], xwsz_t *size) |
| 用主流CRC32参数模型计算一段数据的校验值 | |
变量 | |
| const xwu32_t | xwlib_crc32tbl_0x04c11db7 [256] |
| CRC32多项式0x04C11DB7的查询表 | |
| const xwu32_t | xwlib_crc32tbl_0xedb88320 [256] |
| CRC32多项式0XEDB88320的查询表 | |
XWOS通用库:CRC32
This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
在文件 crc32.c 中定义.
| xwer_t soc_crc32_cal | ( | xwu32_t * | crc32, |
| bool | refin, | ||
| xwu32_t | plynml, | ||
| xwu32_t | direction, | ||
| const xwu8_t | stream[], | ||
| xwsz_t * | size | ||
| ) |

|
static |
软件方式计算一段数据的CRC32校验值
| [in,out] | crc32 | 指向缓冲区的指针,此缓冲区:
|
| [in] | refin | 是否按位镜像翻转输入的每个字节(xwbop_rbit8) |
| [in] | plynml | 多项式 |
| [in] | direction | 数据移位的方向 |
| [in] | stream | 指向数据的指针 |
| [in,out] | size | 指向缓冲区的指针,此缓冲区:
|
| XWOK | 没有错误,计算结果有效 |
| -EOPNOTSUPP | 不支持的多项式 |
<No error
<No error
< 去除未使用变量的警告
< 去除未使用变量的警告
< 去除未使用变量的警告
< 去除未使用变量的警告
< 去除未使用变量的警告
< 去除未使用变量的警告


|
static |
左移计算一段数据的CRC32校验值(直驱表法)
| [in,out] | crc32 | 指向缓冲区的指针,此缓冲区:
|
| [in] | refin | 是否按位镜像翻转输入的每个字节(xwbop_rbit8) |
| [in] | table | CRC32查询表 |
| [in] | stream | 指向数据的指针 |
| [in,out] | size | 指向缓冲区的指针,此缓冲区:
|


|
static |
右移计算一段数据的CRC32校验值(直驱表法)
| [in,out] | crc32 | 指向缓冲区的指针,此缓冲区:
|
| [in] | refin | 是否按位镜像翻转输入的每个字节(xwbop_rbit8) |
| [in] | table | CRC32查询表 |
| [in] | stream | 指向数据的指针 |
| [in,out] | size | 指向缓冲区的指针,此缓冲区:
|

