Lines Matching +full:pre +full:- +full:filled
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
5 * Copyright (c) 2007-2015 Herbert Xu <herbert@gondor.apana.org.au>
16 * struct skcipher_request - Symmetric key cipher request
48 * struct skcipher_alg - symmetric key cipher definition
51 * This must be set to one of the pre-defined values as this is
56 * This must be set to one of the pre-defined values as this is
77 * re-programmed into the hardware in this function. This function
102 * All fields except @ivsize are mandatory and must be filled.
123 * This performs a type-check against the "tfm" argument to make sure
124 * all users have the correct skcipher tfm for doing on-stack requests.
143 * load-balanced on the different CPUs via the process scheduler. To allow
171 * crypto_alloc_skcipher() - allocate symmetric key cipher handle
193 return &tfm->base; in crypto_skcipher_tfm()
197 * crypto_free_skcipher() - zeroize and free cipher handle
209 crypto_free_skcipher(&tfm->base); in crypto_free_sync_skcipher()
213 * crypto_has_skcipher() - Search for the availability of an skcipher.
233 return container_of(crypto_skcipher_tfm(tfm)->__crt_alg, in crypto_skcipher_alg()
239 return alg->ivsize; in crypto_skcipher_alg_ivsize()
243 * crypto_skcipher_ivsize() - obtain IV size
253 return crypto_skcipher_alg(tfm)->ivsize; in crypto_skcipher_ivsize()
259 return crypto_skcipher_ivsize(&tfm->base); in crypto_sync_skcipher_ivsize()
263 * crypto_skcipher_blocksize() - obtain block size of cipher
281 return alg->chunksize; in crypto_skcipher_alg_chunksize()
285 * crypto_skcipher_chunksize() - obtain chunk size
290 * the underlying block size as the IV does not have sub-block
304 return crypto_skcipher_blocksize(&tfm->base); in crypto_sync_skcipher_blocksize()
333 return crypto_skcipher_get_flags(&tfm->base); in crypto_sync_skcipher_get_flags()
339 crypto_skcipher_set_flags(&tfm->base, flags); in crypto_sync_skcipher_set_flags()
345 crypto_skcipher_clear_flags(&tfm->base, flags); in crypto_sync_skcipher_clear_flags()
349 * crypto_skcipher_setkey() - set key for cipher
358 * different cipher modes depending on the key size, such as AES-128 vs AES-192
359 * vs. AES-256. When providing a 16 byte key for an AES cipher handle, AES-128
370 return crypto_skcipher_setkey(&tfm->base, key, keylen); in crypto_sync_skcipher_setkey()
376 return crypto_skcipher_alg(tfm)->min_keysize; in crypto_skcipher_min_keysize()
382 return crypto_skcipher_alg(tfm)->max_keysize; in crypto_skcipher_max_keysize()
386 * crypto_skcipher_reqtfm() - obtain cipher handle from request
397 return __crypto_skcipher_cast(req->base.tfm); in crypto_skcipher_reqtfm()
409 * crypto_skcipher_encrypt() - encrypt plaintext
414 * structure and how it is filled with data is discussed with the
422 * crypto_skcipher_decrypt() - decrypt ciphertext
427 * structure and how it is filled with data is discussed with the
446 * crypto_skcipher_reqsize() - obtain size of the request data structure
453 return tfm->reqsize; in crypto_skcipher_reqsize()
457 * skcipher_request_set_tfm() - update cipher handle reference in request
467 req->base.tfm = crypto_skcipher_tfm(tfm); in skcipher_request_set_tfm()
473 skcipher_request_set_tfm(req, &tfm->base); in skcipher_request_set_sync_tfm()
483 * skcipher_request_alloc() - allocate request data structure
508 * skcipher_request_free() - zeroize and free request data structure
524 * skcipher_request_set_callback() - set asynchronous callback function
553 req->base.complete = compl; in skcipher_request_set_callback()
554 req->base.data = data; in skcipher_request_set_callback()
555 req->base.flags = flags; in skcipher_request_set_callback()
559 * skcipher_request_set_crypt() - set data buffers
572 * reversed - the source is the ciphertext and the destination is the plaintext.
579 req->src = src; in skcipher_request_set_crypt()
580 req->dst = dst; in skcipher_request_set_crypt()
581 req->cryptlen = cryptlen; in skcipher_request_set_crypt()
582 req->iv = iv; in skcipher_request_set_crypt()