Lines Matching refs:mode_num
600 int blk_crypto_fallback_start_using_mode(enum blk_crypto_mode_num mode_num)
602 const char *cipher_str = blk_crypto_modes[mode_num].cipher_str;
609 * Ensure that updates to blk_crypto_keyslots[i].tfms[mode_num]
612 if (likely(smp_load_acquire(&tfms_inited[mode_num])))
616 if (tfms_inited[mode_num])
625 slotp->tfms[mode_num] = crypto_alloc_skcipher(cipher_str, 0, 0);
626 if (IS_ERR(slotp->tfms[mode_num])) {
627 err = PTR_ERR(slotp->tfms[mode_num]);
633 slotp->tfms[mode_num] = NULL;
637 crypto_skcipher_set_flags(slotp->tfms[mode_num],
642 * Ensure that updates to blk_crypto_keyslots[i].tfms[mode_num]
643 * for each i are visible before we set tfms_inited[mode_num].
645 smp_store_release(&tfms_inited[mode_num], true);
651 crypto_free_skcipher(slotp->tfms[mode_num]);
652 slotp->tfms[mode_num] = NULL;