Re: [PATCH v2] mmc: mmci_qcom_dml: include mmci_qcom_dml.h and fix #ifdef

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Aug 6, 2017 at 12:26 PM, Srinivas Kandagatla
<srinivas.kandagatla@xxxxxxxxxx> wrote:
>
>
> On 04/08/17 23:10, Arnd Bergmann wrote:
>>
>> How about linking the DML code into the mmci module and making that
>> Kconfig option a 'bool'?
>
>
>
> Yes, I think making this bool and exporting the two symbols should fix this.
> It does not make sense to make dml helpers a module anyway.
>
> If it sounds okay, I can send a proper patch to fix this.

I would say making dml a 'bool' option is not ok unless you also change
the Makefile to link it into the same module as the base mmci driver.

The alternative is to export the symbols and then always build the
dml code as a module when the mmci driver is a module, as below.

Or even just move all the code into the base driver, and call it only
using an if(IS_ENABLED()) check for the bool symbol.

       Arnd

diff --git a/drivers/mmc/host/Makefile b/drivers/mmc/host/Makefile
index 8c46766c000c..5c996cba9f25 100644
--- a/drivers/mmc/host/Makefile
+++ b/drivers/mmc/host/Makefile
@@ -3,7 +3,9 @@
 #

 obj-$(CONFIG_MMC_ARMMMCI) += mmci.o
-obj-$(CONFIG_MMC_QCOM_DML) += mmci_qcom_dml.o
+ifdef CONFIG_MMC_QCOM_DML
+obj-$(CONFIG_MMC_ARMMMCI) += mmci_qcom_dml.o
+endif
 obj-$(CONFIG_MMC_PXA) += pxamci.o
 obj-$(CONFIG_MMC_MXC) += mxcmmc.o
 obj-$(CONFIG_MMC_MXS) += mxs-mmc.o
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux