module: icp: remove unused kcf_mac operations

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes #12901
This commit is contained in:
наб 2021-12-23 20:11:01 +01:00 committed by Brian Behlendorf
parent 2c2f955aae
commit bf3fffe70d
2 changed files with 2 additions and 52 deletions

View File

@ -90,15 +90,9 @@ extern int crypto_digest_final(crypto_context_t ctx, crypto_data_t *digest,
extern int crypto_mac(crypto_mechanism_t *mech, crypto_data_t *data,
crypto_key_t *key, crypto_ctx_template_t tmpl, crypto_data_t *mac,
crypto_call_req_t *cr);
extern int crypto_mac_prov(crypto_provider_t, crypto_session_id_t,
crypto_mechanism_t *, crypto_data_t *, crypto_key_t *,
crypto_ctx_template_t, crypto_data_t *, crypto_call_req_t *);
extern int crypto_mac_verify(crypto_mechanism_t *mech, crypto_data_t *data,
crypto_key_t *key, crypto_ctx_template_t tmpl, crypto_data_t *mac,
crypto_call_req_t *cr);
extern int crypto_mac_verify_prov(crypto_provider_t, crypto_session_id_t,
crypto_mechanism_t *, crypto_data_t *, crypto_key_t *,
crypto_ctx_template_t, crypto_data_t *, crypto_call_req_t *);
extern int crypto_mac_init(crypto_mechanism_t *mech, crypto_key_t *key,
crypto_ctx_template_t tmpl, crypto_context_t *ctxp, crypto_call_req_t *cr);
extern int crypto_mac_init_prov(crypto_provider_t, crypto_session_id_t,

View File

@ -79,6 +79,7 @@
* the specified session id.
* When complete and successful, 'mac' will contain the message
* authentication code.
* Relies on the KCF scheduler to choose a provider.
*
* Context:
* Process or interrupt, according to the semantics dictated by the 'crq'.
@ -87,29 +88,6 @@
* See comment in the beginning of the file.
*/
int
crypto_mac_prov(crypto_provider_t provider, crypto_session_id_t sid,
crypto_mechanism_t *mech, crypto_data_t *data, crypto_key_t *key,
crypto_ctx_template_t tmpl, crypto_data_t *mac, crypto_call_req_t *crq)
{
kcf_req_params_t params;
kcf_provider_desc_t *pd = provider;
kcf_provider_desc_t *real_provider = pd;
int rv;
ASSERT(KCF_PROV_REFHELD(pd));
KCF_WRAP_MAC_OPS_PARAMS(&params, KCF_OP_ATOMIC, sid, mech, key,
data, mac, tmpl);
rv = kcf_submit_request(real_provider, NULL, crq, &params);
return (rv);
}
/*
* Same as crypto_mac_prov(), but relies on the KCF scheduler to choose
* a provider. See crypto_mac() comments for more information.
*/
int
crypto_mac(crypto_mechanism_t *mech, crypto_data_t *data,
crypto_key_t *key, crypto_ctx_template_t tmpl, crypto_data_t *mac,
crypto_call_req_t *crq)
@ -183,27 +161,7 @@ retry:
* Single part operation to compute the MAC corresponding to the specified
* 'data' and to verify that it matches the MAC specified by 'mac'.
* The other arguments are the same as the function crypto_mac_prov().
*/
int
crypto_mac_verify_prov(crypto_provider_t provider, crypto_session_id_t sid,
crypto_mechanism_t *mech, crypto_data_t *data, crypto_key_t *key,
crypto_ctx_template_t tmpl, crypto_data_t *mac, crypto_call_req_t *crq)
{
kcf_req_params_t params;
kcf_provider_desc_t *pd = provider;
kcf_provider_desc_t *real_provider = pd;
ASSERT(KCF_PROV_REFHELD(pd));
KCF_WRAP_MAC_OPS_PARAMS(&params, KCF_OP_MAC_VERIFY_ATOMIC, sid, mech,
key, data, mac, tmpl);
return (kcf_submit_request(real_provider, NULL, crq, &params));
}
/*
* Same as crypto_mac_verify_prov(), but relies on the KCF scheduler to choose
* a provider. See crypto_mac_verify_prov() comments for more information.
* Relies on the KCF scheduler to choose a provider.
*/
int
crypto_mac_verify(crypto_mechanism_t *mech, crypto_data_t *data,
@ -511,9 +469,7 @@ crypto_mac_final(crypto_context_t context, crypto_data_t *mac,
}
#if defined(_KERNEL)
EXPORT_SYMBOL(crypto_mac_prov);
EXPORT_SYMBOL(crypto_mac);
EXPORT_SYMBOL(crypto_mac_verify_prov);
EXPORT_SYMBOL(crypto_mac_verify);
EXPORT_SYMBOL(crypto_mac_init_prov);
EXPORT_SYMBOL(crypto_mac_init);