Re: çå: [PATCH v5,1/2] misc: rtsx: Move Realtek Card Reader Driver to misc
From: Arnd Bergmann
Date: Wed Nov 22 2017 - 04:35:15 EST
On Wed, Nov 22, 2017 at 4:24 AM, åé <rui_feng@xxxxxxxxxxxxxx> wrote:
> Dear all:
>
> I checked the file ".config", I found " CONFIG_MMC_REALTEK_USB=y " but its dependence MISC_RTSX_USB is not selected, so compile errors occurred.
> What should I do to fix it?
The problem is this bit in the Makefile:
--- a/drivers/misc/Makefile
+++ b/drivers/misc/Makefile
@@ -55,6 +55,7 @@ obj-$(CONFIG_CXL_BASE) += cxl/
obj-$(CONFIG_ASPEED_LPC_CTRL) += aspeed-lpc-ctrl.o
obj-$(CONFIG_ASPEED_LPC_SNOOP) += aspeed-lpc-snoop.o
obj-$(CONFIG_PCI_ENDPOINT_TEST) += pci_endpoint_test.o
+obj-$(CONFIG_MISC_RTSX_PCI) += cardreader/
lkdtm-$(CONFIG_LKDTM) += lkdtm_core.o
lkdtm-$(CONFIG_LKDTM) += lkdtm_bugs.o
I would suggest changing this to CONFIG_MISC_RTSX, and adding that symbol like
config MISC_RTSX
tristate
default MISC_RTSX_PCI || MISC_RTSX_USB
Then we enter the directory if one of the two gets selected.
You could also use "obj-y += cardreader/" in the Makefile, but I
think the extra
symbol is a bit nicer, as it avoids entering the subdirectory when we
don't need it.
Arnd