android_kernel_xiaomi_sm8350/drivers/mmc/host/cqhci-crypto-qti.h
Vaibhav Agrawal 1e2b270925 mmc: host: Add recovery_finish crypto vops
Define recovery_finish crypto vops to support
MMC CQE recovery handler path.

Test: Initiate CQE recovery, which calls into crypto
specific recovery method. If the crypto vops are
registered on the device, this flow does not lead to
a null pointer dereference with this fix included.

Change-Id: I6dfaf52a303b9ffa71b6b65779f8e657d6ca051a
Signed-off-by: Vaibhav Agrawal <vagrawa@codeaurora.org>
2021-07-12 02:31:20 -07:00

34 lines
888 B
C

/* SPDX-License-Identifier: GPL-2.0-only */
/*
* Copyright (c) 2020 - 2021, The Linux Foundation. All rights reserved.
*/
#ifndef _UFSHCD_CRYPTO_QTI_H
#define _UFSHCD_CRYPTO_QTI_H
#include "cqhci-crypto.h"
void cqhci_crypto_qti_enable(struct cqhci_host *host);
void cqhci_crypto_qti_disable(struct cqhci_host *host);
#ifdef CONFIG_BLK_INLINE_ENCRYPTION
int cqhci_crypto_qti_init_crypto(struct cqhci_host *host,
const struct keyslot_mgmt_ll_ops *ksm_ops);
#endif
int cqhci_crypto_qti_debug(struct cqhci_host *host);
#if IS_ENABLED(CONFIG_MMC_CQHCI_CRYPTO_QTI)
void cqhci_crypto_qti_set_vops(struct cqhci_host *host);
#else
void cqhci_crypto_qti_set_vops(struct cqhci_host *host)
{}
#endif /* CONFIG_MMC_CQHCI_CRYPTO_QTI) */
int cqhci_crypto_qti_resume(struct cqhci_host *host);
int cqhci_crypto_qti_recovery_finish(struct cqhci_host *host);
#endif /* _UFSHCD_ICE_QTI_H */