All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] dmaengine: core: Use IS_ENABLED() instead of checking for built-in or module
@ 2016-05-11 17:39 Javier Martinez Canillas
  2016-05-14  8:02 ` Vinod Koul
  0 siblings, 1 reply; 2+ messages in thread
From: Javier Martinez Canillas @ 2016-05-11 17:39 UTC (permalink / raw)
  To: linux-kernel
  Cc: Javier Martinez Canillas, Dan Williams, dmaengine, Vinod Koul

The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either
built-in or as a module, use that macro instead of open coding the same.

Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
---

 drivers/dma/dmaengine.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/dma/dmaengine.c b/drivers/dma/dmaengine.c
index 5ff79a0bac77..f4552959a8ed 100644
--- a/drivers/dma/dmaengine.c
+++ b/drivers/dma/dmaengine.c
@@ -866,12 +866,12 @@ static bool device_has_all_tx_types(struct dma_device *device)
 		return false;
 	#endif
 
-	#if defined(CONFIG_ASYNC_MEMCPY) || defined(CONFIG_ASYNC_MEMCPY_MODULE)
+	#if IS_ENABLED(CONFIG_ASYNC_MEMCPY)
 	if (!dma_has_cap(DMA_MEMCPY, device->cap_mask))
 		return false;
 	#endif
 
-	#if defined(CONFIG_ASYNC_XOR) || defined(CONFIG_ASYNC_XOR_MODULE)
+	#if IS_ENABLED(CONFIG_ASYNC_XOR)
 	if (!dma_has_cap(DMA_XOR, device->cap_mask))
 		return false;
 
@@ -881,7 +881,7 @@ static bool device_has_all_tx_types(struct dma_device *device)
 	#endif
 	#endif
 
-	#if defined(CONFIG_ASYNC_PQ) || defined(CONFIG_ASYNC_PQ_MODULE)
+	#if IS_ENABLED(CONFIG_ASYNC_PQ)
 	if (!dma_has_cap(DMA_PQ, device->cap_mask))
 		return false;
 
-- 
2.5.5

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] dmaengine: core: Use IS_ENABLED() instead of checking for built-in or module
  2016-05-11 17:39 [PATCH] dmaengine: core: Use IS_ENABLED() instead of checking for built-in or module Javier Martinez Canillas
@ 2016-05-14  8:02 ` Vinod Koul
  0 siblings, 0 replies; 2+ messages in thread
From: Vinod Koul @ 2016-05-14  8:02 UTC (permalink / raw)
  To: Javier Martinez Canillas; +Cc: linux-kernel, Dan Williams, dmaengine

On Wed, May 11, 2016 at 01:39:27PM -0400, Javier Martinez Canillas wrote:
> The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either
> built-in or as a module, use that macro instead of open coding the same.

Applied, thanks

-- 
~Vinod

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-05-14  7:56 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-05-11 17:39 [PATCH] dmaengine: core: Use IS_ENABLED() instead of checking for built-in or module Javier Martinez Canillas
2016-05-14  8:02 ` Vinod Koul

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.