On Fri, May 15, 2020 at 01:47:54PM +0300, Serge Semin wrote:
> Seeing all of the DW SPI driver components like DW SPI DMA/PCI/MMIO
> depend on the DW SPI core code it's better to use the if-endif
> conditional kernel config statement to signify that common dependency.

Makes sense!
Reviewed-by: Andy Shevchenko <andriy.shevche...@linux.intel.com>

> 
> Co-developed-by: Georgy Vlasov <georgy.vla...@baikalelectronics.ru>
> Signed-off-by: Georgy Vlasov <georgy.vla...@baikalelectronics.ru>
> Co-developed-by: Ramil Zaripov <ramil.zari...@baikalelectronics.ru>
> Signed-off-by: Ramil Zaripov <ramil.zari...@baikalelectronics.ru>
> Signed-off-by: Serge Semin <sergey.se...@baikalelectronics.ru>
> Cc: Alexey Malahov <alexey.mala...@baikalelectronics.ru>
> Cc: Thomas Bogendoerfer <tsbog...@alpha.franken.de>
> Cc: Paul Burton <paulbur...@kernel.org>
> Cc: Ralf Baechle <r...@linux-mips.org>
> Cc: Arnd Bergmann <a...@arndb.de>
> Cc: Allison Randal <alli...@lohutok.net>
> Cc: Andy Shevchenko <andriy.shevche...@linux.intel.com>
> Cc: Gareth Williams <gareth.williams...@renesas.com>
> Cc: Rob Herring <robh...@kernel.org>
> Cc: linux-m...@vger.kernel.org
> Cc: devicet...@vger.kernel.org
> ---
>  drivers/spi/Kconfig | 9 ++++++---
>  1 file changed, 6 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/spi/Kconfig b/drivers/spi/Kconfig
> index 6a84f3dad35c..3cdf8310d185 100644
> --- a/drivers/spi/Kconfig
> +++ b/drivers/spi/Kconfig
> @@ -226,17 +226,20 @@ config SPI_DESIGNWARE
>       help
>         general driver for SPI controller core from DesignWare
>  
> +if SPI_DESIGNWARE
> +
>  config SPI_DW_DMA
>       bool "DMA support for DW SPI controller"
> -     depends on SPI_DESIGNWARE
>  
>  config SPI_DW_PCI
>       tristate "PCI interface driver for DW SPI core"
> -     depends on SPI_DESIGNWARE && PCI
> +     depends on PCI
>  
>  config SPI_DW_MMIO
>       tristate "Memory-mapped io interface driver for DW SPI core"
> -     depends on SPI_DESIGNWARE
> +     depends on HAS_IOMEM
> +
> +endif
>  
>  config SPI_DLN2
>         tristate "Diolan DLN-2 USB SPI adapter"
> -- 
> 2.25.1
> 

-- 
With Best Regards,
Andy Shevchenko


Reply via email to