diff mbox

dmaengine: shdma: fix a build failure on platforms with no DMA support

Message ID 1373422152-29976-1-git-send-email-horms+renesas@verge.net.au (mailing list archive)
State New, archived
Headers show

Commit Message

Simon Horman July 10, 2013, 2:09 a.m. UTC
From: Guennadi Liakhovetski <g.liakhovetski@gmx.de>

On platforms with no support for the shdma dmaengine driver build is
currently failing with

drivers/built-in.o: In function `sh_mobile_sdhi_probe':
drivers/mmc/host/sh_mobile_sdhi.c:170: undefined reference to`shdma_chan_filter'

Fix the breakage by defining shdma_chan_filter to NULL in such
configurations.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski+renesas@gmail.com>
[horms+renesas@verge.net.au: Apply change to shdma-base.h instead of sh_dma.h]
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
---
 include/linux/shdma-base.h | 4 ++++
 1 file changed, 4 insertions(+)

Hi Vinod,

please consider this fix from Guennadi for v3.11 which I have rebased on top of
next-20130709. It fixes a build problem on a number of shmobile defconfigs
including bockw.

Comments

Simon Horman July 16, 2013, 1:20 a.m. UTC | #1
On Wed, Jul 10, 2013 at 11:09:12AM +0900, Simon Horman wrote:
> From: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
> 
> On platforms with no support for the shdma dmaengine driver build is
> currently failing with
> 
> drivers/built-in.o: In function `sh_mobile_sdhi_probe':
> drivers/mmc/host/sh_mobile_sdhi.c:170: undefined reference to`shdma_chan_filter'
> 
> Fix the breakage by defining shdma_chan_filter to NULL in such
> configurations.
> 
> Signed-off-by: Guennadi Liakhovetski <g.liakhovetski+renesas@gmail.com>
> [horms+renesas@verge.net.au: Apply change to shdma-base.h instead of sh_dma.h]
> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
> ---
>  include/linux/shdma-base.h | 4 ++++
>  1 file changed, 4 insertions(+)

> 
> Hi Vinod,
> 
> please consider this fix from Guennadi for v3.11 which I have rebased on top of
> next-20130709. It fixes a build problem on a number of shmobile defconfigs
> including bockw.

Ping.

Would it be appropriate for me to take this change through my tree?
It seems to resolve a regression in v3.11-rc1.

> diff --git a/include/linux/shdma-base.h b/include/linux/shdma-base.h
> index 382cf71..5b1c984 100644
> --- a/include/linux/shdma-base.h
> +++ b/include/linux/shdma-base.h
> @@ -124,6 +124,10 @@ void shdma_chan_remove(struct shdma_chan *schan);
>  int shdma_init(struct device *dev, struct shdma_dev *sdev,
>  		    int chan_num);
>  void shdma_cleanup(struct shdma_dev *sdev);
> +#if IS_ENABLED(CONFIG_SH_DMAE_BASE)
>  bool shdma_chan_filter(struct dma_chan *chan, void *arg);
> +#else
> +#define shdma_chan_filter NULL
> +#endif
>  
>  #endif
> -- 
> 1.8.2.1
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sh" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Olof Johansson July 23, 2013, 2:39 a.m. UTC | #2
On Tue, Jul 16, 2013 at 10:20:41AM +0900, Simon Horman wrote:
> On Wed, Jul 10, 2013 at 11:09:12AM +0900, Simon Horman wrote:
> > From: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
> > 
> > On platforms with no support for the shdma dmaengine driver build is
> > currently failing with
> > 
> > drivers/built-in.o: In function `sh_mobile_sdhi_probe':
> > drivers/mmc/host/sh_mobile_sdhi.c:170: undefined reference to`shdma_chan_filter'
> > 
> > Fix the breakage by defining shdma_chan_filter to NULL in such
> > configurations.
> > 
> > Signed-off-by: Guennadi Liakhovetski <g.liakhovetski+renesas@gmail.com>
> > [horms+renesas@verge.net.au: Apply change to shdma-base.h instead of sh_dma.h]
> > Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
> > ---
> >  include/linux/shdma-base.h | 4 ++++
> >  1 file changed, 4 insertions(+)
> 
> > 
> > Hi Vinod,
> > 
> > please consider this fix from Guennadi for v3.11 which I have rebased on top of
> > next-20130709. It fixes a build problem on a number of shmobile defconfigs
> > including bockw.
> 
> Ping.
> 
> Would it be appropriate for me to take this change through my tree?
> It seems to resolve a regression in v3.11-rc1.

I'll take it through arm-soc since there's no response from Vinod. I've
applied it in the fixes branch we have.


-Olof
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Simon Horman July 23, 2013, 4:12 a.m. UTC | #3
On Mon, Jul 22, 2013 at 07:39:07PM -0700, Olof Johansson wrote:
> On Tue, Jul 16, 2013 at 10:20:41AM +0900, Simon Horman wrote:
> > On Wed, Jul 10, 2013 at 11:09:12AM +0900, Simon Horman wrote:
> > > From: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
> > > 
> > > On platforms with no support for the shdma dmaengine driver build is
> > > currently failing with
> > > 
> > > drivers/built-in.o: In function `sh_mobile_sdhi_probe':
> > > drivers/mmc/host/sh_mobile_sdhi.c:170: undefined reference to`shdma_chan_filter'
> > > 
> > > Fix the breakage by defining shdma_chan_filter to NULL in such
> > > configurations.
> > > 
> > > Signed-off-by: Guennadi Liakhovetski <g.liakhovetski+renesas@gmail.com>
> > > [horms+renesas@verge.net.au: Apply change to shdma-base.h instead of sh_dma.h]
> > > Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
> > > ---
> > >  include/linux/shdma-base.h | 4 ++++
> > >  1 file changed, 4 insertions(+)
> > 
> > > 
> > > Hi Vinod,
> > > 
> > > please consider this fix from Guennadi for v3.11 which I have rebased on top of
> > > next-20130709. It fixes a build problem on a number of shmobile defconfigs
> > > including bockw.
> > 
> > Ping.
> > 
> > Would it be appropriate for me to take this change through my tree?
> > It seems to resolve a regression in v3.11-rc1.
> 
> I'll take it through arm-soc since there's no response from Vinod. I've
> applied it in the fixes branch we have.

Thanks!

Very much appreciated.
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/include/linux/shdma-base.h b/include/linux/shdma-base.h
index 382cf71..5b1c984 100644
--- a/include/linux/shdma-base.h
+++ b/include/linux/shdma-base.h
@@ -124,6 +124,10 @@  void shdma_chan_remove(struct shdma_chan *schan);
 int shdma_init(struct device *dev, struct shdma_dev *sdev,
 		    int chan_num);
 void shdma_cleanup(struct shdma_dev *sdev);
+#if IS_ENABLED(CONFIG_SH_DMAE_BASE)
 bool shdma_chan_filter(struct dma_chan *chan, void *arg);
+#else
+#define shdma_chan_filter NULL
+#endif
 
 #endif