1*4882a593Smuzhiyun /* SPDX-License-Identifier: GPL-2.0-only */ 2*4882a593Smuzhiyun /* 3*4882a593Smuzhiyun * MMC crypto engine (inline encryption) support 4*4882a593Smuzhiyun * 5*4882a593Smuzhiyun * Copyright 2020 Google LLC 6*4882a593Smuzhiyun */ 7*4882a593Smuzhiyun 8*4882a593Smuzhiyun #ifndef _MMC_CORE_CRYPTO_H 9*4882a593Smuzhiyun #define _MMC_CORE_CRYPTO_H 10*4882a593Smuzhiyun 11*4882a593Smuzhiyun struct mmc_host; 12*4882a593Smuzhiyun struct mmc_queue_req; 13*4882a593Smuzhiyun struct request_queue; 14*4882a593Smuzhiyun 15*4882a593Smuzhiyun #ifdef CONFIG_MMC_CRYPTO 16*4882a593Smuzhiyun 17*4882a593Smuzhiyun void mmc_crypto_set_initial_state(struct mmc_host *host); 18*4882a593Smuzhiyun 19*4882a593Smuzhiyun void mmc_crypto_setup_queue(struct request_queue *q, struct mmc_host *host); 20*4882a593Smuzhiyun 21*4882a593Smuzhiyun void mmc_crypto_prepare_req(struct mmc_queue_req *mqrq); 22*4882a593Smuzhiyun 23*4882a593Smuzhiyun #else /* CONFIG_MMC_CRYPTO */ 24*4882a593Smuzhiyun mmc_crypto_set_initial_state(struct mmc_host * host)25*4882a593Smuzhiyunstatic inline void mmc_crypto_set_initial_state(struct mmc_host *host) 26*4882a593Smuzhiyun { 27*4882a593Smuzhiyun } 28*4882a593Smuzhiyun mmc_crypto_setup_queue(struct request_queue * q,struct mmc_host * host)29*4882a593Smuzhiyunstatic inline void mmc_crypto_setup_queue(struct request_queue *q, 30*4882a593Smuzhiyun struct mmc_host *host) 31*4882a593Smuzhiyun { 32*4882a593Smuzhiyun } 33*4882a593Smuzhiyun mmc_crypto_prepare_req(struct mmc_queue_req * mqrq)34*4882a593Smuzhiyunstatic inline void mmc_crypto_prepare_req(struct mmc_queue_req *mqrq) 35*4882a593Smuzhiyun { 36*4882a593Smuzhiyun } 37*4882a593Smuzhiyun 38*4882a593Smuzhiyun #endif /* !CONFIG_MMC_CRYPTO */ 39*4882a593Smuzhiyun 40*4882a593Smuzhiyun #endif /* _MMC_CORE_CRYPTO_H */ 41