Lines Matching refs:nbytes
155 struct scatterlist *src, unsigned int nbytes) in ecb_encrypt() argument
157 return glue_ecb_crypt_128bit(&camellia_enc, desc, dst, src, nbytes); in ecb_encrypt()
161 struct scatterlist *src, unsigned int nbytes) in ecb_decrypt() argument
163 return glue_ecb_crypt_128bit(&camellia_dec, desc, dst, src, nbytes); in ecb_decrypt()
167 struct scatterlist *src, unsigned int nbytes) in cbc_encrypt() argument
170 dst, src, nbytes); in cbc_encrypt()
174 struct scatterlist *src, unsigned int nbytes) in cbc_decrypt() argument
177 nbytes); in cbc_decrypt()
181 struct scatterlist *src, unsigned int nbytes) in ctr_crypt() argument
183 return glue_ctr_crypt_128bit(&camellia_ctr, desc, dst, src, nbytes); in ctr_crypt()
186 static inline bool camellia_fpu_begin(bool fpu_enabled, unsigned int nbytes) in camellia_fpu_begin() argument
190 nbytes); in camellia_fpu_begin()
210 static void encrypt_callback(void *priv, u8 *srcdst, unsigned int nbytes) in encrypt_callback() argument
216 ctx->fpu_enabled = camellia_fpu_begin(ctx->fpu_enabled, nbytes); in encrypt_callback()
218 if (nbytes >= CAMELLIA_AESNI_AVX2_PARALLEL_BLOCKS * bsize) { in encrypt_callback()
221 nbytes -= bsize * CAMELLIA_AESNI_AVX2_PARALLEL_BLOCKS; in encrypt_callback()
224 if (nbytes >= CAMELLIA_AESNI_PARALLEL_BLOCKS * bsize) { in encrypt_callback()
227 nbytes -= bsize * CAMELLIA_AESNI_PARALLEL_BLOCKS; in encrypt_callback()
230 while (nbytes >= CAMELLIA_PARALLEL_BLOCKS * bsize) { in encrypt_callback()
233 nbytes -= bsize * CAMELLIA_PARALLEL_BLOCKS; in encrypt_callback()
236 for (i = 0; i < nbytes / bsize; i++, srcdst += bsize) in encrypt_callback()
240 static void decrypt_callback(void *priv, u8 *srcdst, unsigned int nbytes) in decrypt_callback() argument
246 ctx->fpu_enabled = camellia_fpu_begin(ctx->fpu_enabled, nbytes); in decrypt_callback()
248 if (nbytes >= CAMELLIA_AESNI_AVX2_PARALLEL_BLOCKS * bsize) { in decrypt_callback()
251 nbytes -= bsize * CAMELLIA_AESNI_AVX2_PARALLEL_BLOCKS; in decrypt_callback()
254 if (nbytes >= CAMELLIA_AESNI_PARALLEL_BLOCKS * bsize) { in decrypt_callback()
257 nbytes -= bsize * CAMELLIA_AESNI_PARALLEL_BLOCKS; in decrypt_callback()
260 while (nbytes >= CAMELLIA_PARALLEL_BLOCKS * bsize) { in decrypt_callback()
263 nbytes -= bsize * CAMELLIA_PARALLEL_BLOCKS; in decrypt_callback()
266 for (i = 0; i < nbytes / bsize; i++, srcdst += bsize) in decrypt_callback()
271 struct scatterlist *src, unsigned int nbytes) in lrw_encrypt() argument
290 ret = lrw_crypt(desc, dst, src, nbytes, &req); in lrw_encrypt()
297 struct scatterlist *src, unsigned int nbytes) in lrw_decrypt() argument
316 ret = lrw_crypt(desc, dst, src, nbytes, &req); in lrw_decrypt()
323 struct scatterlist *src, unsigned int nbytes) in xts_encrypt() argument
327 return glue_xts_crypt_128bit(&camellia_enc_xts, desc, dst, src, nbytes, in xts_encrypt()
333 struct scatterlist *src, unsigned int nbytes) in xts_decrypt() argument
337 return glue_xts_crypt_128bit(&camellia_dec_xts, desc, dst, src, nbytes, in xts_decrypt()