linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] dmaengine: qcom_hidma: hide MSI handler when unused
@ 2016-11-08 13:48 Arnd Bergmann
  2016-11-08 14:42 ` Sinan Kaya
  2016-11-14  5:24 ` Vinod Koul
  0 siblings, 2 replies; 3+ messages in thread
From: Arnd Bergmann @ 2016-11-08 13:48 UTC (permalink / raw)
  To: Vinod Koul
  Cc: Arnd Bergmann, Dan Williams, Sinan Kaya, dmaengine, linux-kernel

The newly added MSI support causes a harmless warning when MSI
is disabled:

drivers/dma/qcom/hidma.c:558:20: error: 'hidma_chirq_handler_msi' defined but not used [-Werror=unused-function]

This adds another #ifdef to match that around the users of the function.

Fixes: 1c0e3e82a7fb ("dmaengine: qcom_hidma: add MSI support for interrupts")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/dma/qcom/hidma.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/dma/qcom/hidma.c b/drivers/dma/qcom/hidma.c
index d5e7991ad737..10425e134e06 100644
--- a/drivers/dma/qcom/hidma.c
+++ b/drivers/dma/qcom/hidma.c
@@ -555,6 +555,7 @@ static irqreturn_t hidma_chirq_handler(int chirq, void *arg)
 	return hidma_ll_inthandler(chirq, lldev);
 }
 
+#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
 static irqreturn_t hidma_chirq_handler_msi(int chirq, void *arg)
 {
 	struct hidma_lldev **lldevp = arg;
@@ -563,6 +564,7 @@ static irqreturn_t hidma_chirq_handler_msi(int chirq, void *arg)
 	return hidma_ll_inthandler_msi(chirq, *lldevp,
 				       1 << (chirq - dmadev->msi_virqbase));
 }
+#endif
 
 static ssize_t hidma_show_values(struct device *dev,
 				 struct device_attribute *attr, char *buf)
-- 
2.9.0

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

* Re: [PATCH] dmaengine: qcom_hidma: hide MSI handler when unused
  2016-11-08 13:48 [PATCH] dmaengine: qcom_hidma: hide MSI handler when unused Arnd Bergmann
@ 2016-11-08 14:42 ` Sinan Kaya
  2016-11-14  5:24 ` Vinod Koul
  1 sibling, 0 replies; 3+ messages in thread
From: Sinan Kaya @ 2016-11-08 14:42 UTC (permalink / raw)
  To: Arnd Bergmann, Vinod Koul; +Cc: Dan Williams, dmaengine, linux-kernel

On 11/8/2016 8:48 AM, Arnd Bergmann wrote:
> The newly added MSI support causes a harmless warning when MSI
> is disabled:
> 
> drivers/dma/qcom/hidma.c:558:20: error: 'hidma_chirq_handler_msi' defined but not used [-Werror=unused-function]
> 
> This adds another #ifdef to match that around the users of the function.
> 
> Fixes: 1c0e3e82a7fb ("dmaengine: qcom_hidma: add MSI support for interrupts")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Thanks for the clean up.

Acked-by: Sinan Kaya <okaya@codeaurora.org>

> ---
>  drivers/dma/qcom/hidma.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/dma/qcom/hidma.c b/drivers/dma/qcom/hidma.c
> index d5e7991ad737..10425e134e06 100644
> --- a/drivers/dma/qcom/hidma.c
> +++ b/drivers/dma/qcom/hidma.c
> @@ -555,6 +555,7 @@ static irqreturn_t hidma_chirq_handler(int chirq, void *arg)
>  	return hidma_ll_inthandler(chirq, lldev);
>  }
>  
> +#ifdef CONFIG_GENERIC_MSI_IRQ_DOMAIN
>  static irqreturn_t hidma_chirq_handler_msi(int chirq, void *arg)
>  {
>  	struct hidma_lldev **lldevp = arg;
> @@ -563,6 +564,7 @@ static irqreturn_t hidma_chirq_handler_msi(int chirq, void *arg)
>  	return hidma_ll_inthandler_msi(chirq, *lldevp,
>  				       1 << (chirq - dmadev->msi_virqbase));
>  }
> +#endif
>  
>  static ssize_t hidma_show_values(struct device *dev,
>  				 struct device_attribute *attr, char *buf)
> 


-- 
Sinan Kaya
Qualcomm Datacenter Technologies, Inc. as an affiliate of Qualcomm Technologies, Inc.
Qualcomm Technologies, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project.

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

* Re: [PATCH] dmaengine: qcom_hidma: hide MSI handler when unused
  2016-11-08 13:48 [PATCH] dmaengine: qcom_hidma: hide MSI handler when unused Arnd Bergmann
  2016-11-08 14:42 ` Sinan Kaya
@ 2016-11-14  5:24 ` Vinod Koul
  1 sibling, 0 replies; 3+ messages in thread
From: Vinod Koul @ 2016-11-14  5:24 UTC (permalink / raw)
  To: Arnd Bergmann; +Cc: Dan Williams, Sinan Kaya, dmaengine, linux-kernel

On Tue, Nov 08, 2016 at 02:48:59PM +0100, Arnd Bergmann wrote:
> The newly added MSI support causes a harmless warning when MSI
> is disabled:
> 
> drivers/dma/qcom/hidma.c:558:20: error: 'hidma_chirq_handler_msi' defined but not used [-Werror=unused-function]
> 
> This adds another #ifdef to match that around the users of the function.

Applied, thanks

-- 
~Vinod

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

end of thread, other threads:[~2016-11-14  5:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-08 13:48 [PATCH] dmaengine: qcom_hidma: hide MSI handler when unused Arnd Bergmann
2016-11-08 14:42 ` Sinan Kaya
2016-11-14  5:24 ` Vinod Koul

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).