On 23-03-08 12:01:41, Eric Biggers wrote: > On Wed, Mar 08, 2023 at 05:58:35PM +0200, Abel Vesa wrote: > > * Switched QCOM_INLINE_CRYPTO_ENGINE to tristate and made it built-in > > if any of the UFS or the SDHC drivers are built-in. This is to allow > > the API to be available even if the built-in driver doesn't have > > crypto enabled. > [...] > > diff --git a/drivers/soc/qcom/Kconfig b/drivers/soc/qcom/Kconfig > > index a8f283086a21..c584369e9810 100644 > > --- a/drivers/soc/qcom/Kconfig > > +++ b/drivers/soc/qcom/Kconfig > > @@ -275,4 +275,10 @@ config QCOM_ICC_BWMON > > the fixed bandwidth votes from cpufreq (CPU nodes) thus achieve high > > memory throughput even with lower CPU frequencies. > > > > +config QCOM_INLINE_CRYPTO_ENGINE > > + tristate > > + depends on SCSI_UFS_CRYPTO || MMC_CRYPTO > > + default y if SCSI_UFS_QCOM=y || MMC_SDHCI_MSM=y > > + select QCOM_SCM > > What are the "depends on" and "default y" lines above for? > > You're already selecting this from SCSI_UFS_QCOM and MSM_SDHCI_MSM, as I had > suggested. Isn't that enough? We have the following: (SCSI_UFS_QCOM && SCSI_UFS_CRYPTO) || (MMC_SDHCI_MSM && MMC_CRYPTO) So lets take as example the scenario: (m && y) || (y && n). The QCOM_INLINE_CRYPTO_ENGINE will be set to 'm' and the sdhci driver will not be able to link properly since the ICE API is part of a module. Therefore, if just one of SCSI_UFS_QCOM and MMC_SDHCI_MSM is built-in and at least one of the crypto options are enabled, set the QCOM_INLINE_CRYPTO_ENGINE to 'y' by default in order to make the built-in one linkage will not fail. Might not be the cleanest way to do this, so I'm open to suggestions. > > - Eric