函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\bch.c Create Date:2022-07-27 07:57:26
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:mpute generator polynomial remainder tables for fast encoding

函数原型:static void build_mod8_tables(struct bch_control *bch, const uint32_t *g)

返回类型:void

参数:

类型参数名称
struct bch_control *bch
const uint32_t *g
1093  l等于BCH_ECC_WORDS(bch)
1094  plen等于DIV_ROUND_UP(ecc_bits + 1, 32)
1095  ecclen等于DIV_ROUND_UP(ecc_bits, 32)
1097  memset(mod8_tab, 0, 4 * 256 * l * mod8_tab的长度)
1099 i小于256循环
1101 b小于4循环
1103  tab等于mod8_tabb乘256加i的和乘l
1104  data等于i左移8乘b
1105 data循环
1106  d等于deg(data)
1108  data异或等于g[0]右移31减d
1109 j小于ecclen循环
1110  hi等于如果d小于31则g[j]左移d加1位否则0
1111  lo等于如果j加1小于pleng[j + 1]右移31减d位否则0
1113  tab[j]异或等于hi按位或lo
调用者
名称描述
init_bch_bch - initialize a BCH encoder/decoder*@m: Galois field order, should be in the range 5-15*@t: maximum error correction capability, in bits*@prim_poly: user-provided primitive polynomial (or 0 to use default)* Returns:* a newly allocated BCH control