There are four exported functions, all suffixed by _bch, which is clearly not the norm. Let's rename them by prefixing them with bch_ instead. This is a mechanical change: init_bch -> bch_init free_bch -> bch_free encode_bch -> bch_encode decode_bch -> bch_decode
Showing the changes to include/linux (1 of 4 files). Show all
Unified · Split
| @@ -53,14 +53,14 @@ struct bch_control { · 52 unmodified lines | |||
| 53 | struct gf_poly *poly_2t[4]; | 53 | struct gf_poly *poly_2t[4]; |
| 54 | }; | 54 | }; |
| 55 | 55 | ||
| 56 | struct bch_control *init_bch(int m, int t, unsigned int prim_poly); | 56 | struct bch_control *bch_init(int m, int t, unsigned int prim_poly); |
| 57 | 57 | ||
| 58 | void free_bch(struct bch_control *bch); | 58 | void bch_free(struct bch_control *bch); |
| 59 | 59 | ||
| 60 | void encode_bch(struct bch_control *bch, const uint8_t *data, | 60 | void bch_encode(struct bch_control *bch, const uint8_t *data, |
| 61 | unsigned int len, uint8_t *ecc); | 61 | unsigned int len, uint8_t *ecc); |
| 62 | 62 | ||
| 63 | int decode_bch(struct bch_control *bch, const uint8_t *data, unsigned int len, | 63 | int bch_decode(struct bch_control *bch, const uint8_t *data, unsigned int len, |
| 64 | const uint8_t *recv_ecc, const uint8_t *calc_ecc, | 64 | const uint8_t *recv_ecc, const uint8_t *calc_ecc, |
| 65 | const unsigned int *syn, unsigned int *errloc); | 65 | const unsigned int *syn, unsigned int *errloc); |
| 66 | 66 | ||