Lines Matching defs:pdesc
92 static int hmac_export(struct shash_desc *pdesc, void *out)
94 struct shash_desc *desc = shash_desc_ctx(pdesc);
96 desc->flags = pdesc->flags & CRYPTO_TFM_REQ_MAY_SLEEP;
101 static int hmac_import(struct shash_desc *pdesc, const void *in)
103 struct shash_desc *desc = shash_desc_ctx(pdesc);
104 struct hmac_ctx *ctx = hmac_ctx(pdesc->tfm);
107 desc->flags = pdesc->flags & CRYPTO_TFM_REQ_MAY_SLEEP;
112 static int hmac_init(struct shash_desc *pdesc)
114 return hmac_import(pdesc, crypto_shash_ctx_aligned(pdesc->tfm));
117 static int hmac_update(struct shash_desc *pdesc,
120 struct shash_desc *desc = shash_desc_ctx(pdesc);
122 desc->flags = pdesc->flags & CRYPTO_TFM_REQ_MAY_SLEEP;
127 static int hmac_final(struct shash_desc *pdesc, u8 *out)
129 struct crypto_shash *parent = pdesc->tfm;
133 struct shash_desc *desc = shash_desc_ctx(pdesc);
135 desc->flags = pdesc->flags & CRYPTO_TFM_REQ_MAY_SLEEP;
142 static int hmac_finup(struct shash_desc *pdesc, const u8 *data,
146 struct crypto_shash *parent = pdesc->tfm;
150 struct shash_desc *desc = shash_desc_ctx(pdesc);
152 desc->flags = pdesc->flags & CRYPTO_TFM_REQ_MAY_SLEEP;