On Friday 11 October 2019 17:51:29 CEST zhong jiang wrote: [...] > How about the following patch ? > > diff --git a/drivers/staging/wfx/Makefile b/drivers/staging/wfx/Makefile > index 0d9c1ed..77d68b7 100644 > --- a/drivers/staging/wfx/Makefile > +++ b/drivers/staging/wfx/Makefile > @@ -19,6 +19,6 @@ wfx-y := \ > sta.o \ > debug.o > wfx-$(CONFIG_SPI) += bus_spi.o > -wfx-$(subst m,y,$(CONFIG_MMC)) += bus_sdio.o > +wfx-$(CONFIG_MMC) += bus_sdio.o > > obj-$(CONFIG_WFX) += wfx.o > diff --git a/drivers/staging/wfx/main.c b/drivers/staging/wfx/main.c > index d2508bc..26720a4 100644 > --- a/drivers/staging/wfx/main.c > +++ b/drivers/staging/wfx/main.c > @@ -484,16 +484,19 @@ static int __init wfx_core_init(void) > > if (IS_ENABLED(CONFIG_SPI)) > ret = spi_register_driver(&wfx_spi_driver); > - if (IS_ENABLED(CONFIG_MMC) && !ret) > +#ifdef CONFIG_MMC > + if (!ret) > ret = sdio_register_driver(&wfx_sdio_driver); > +#endif > return ret; > } > module_init(wfx_core_init); > > static void __exit wfx_core_exit(void) > { > - if (IS_ENABLED(CONFIG_MMC)) > - sdio_unregister_driver(&wfx_sdio_driver); > +#ifdef CONFIG_MMC > + sdio_unregister_driver(&wfx_sdio_driver); > +#endif > if (IS_ENABLED(CONFIG_SPI)) > spi_unregister_driver(&wfx_spi_driver); > } Hello zhong,
Can you also check the case where CONFIG_SPI is not set? Thank you, -- Jérôme Pouiller