| 109 | 0x9090000000000000}; |
| 110 | |
| 111 | crc_t crc_update(crc_t crc, const void *data, size_t data_len) { |
| 112 | const unsigned char *d = (const unsigned char *)data; |
| 113 | unsigned int tbl_idx; |
| 114 | |
| 115 | while (data_len--) { |
| 116 | tbl_idx = (crc ^ *d) & 0xff; |
| 117 | crc = (crc_table[tbl_idx] ^ (crc >> 8)) & 0xffffffffffffffff; |
| 118 | d++; |
| 119 | } |
| 120 | return crc & 0xffffffffffffffff; |
| 121 | } |