Skip to contentSkip to conversation

warning introduced in "DMA: AT91: Get residual bytes in dma buffer"

PATCH Arnd Bergmann 2 participants 2 messages May 31, 2013 – Jun 3, 2013

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

Patch 7c407d3e "DMA: AT91: Get residual bytes in dma buffer" causes a build warning

/git/arm-soc/drivers/dma/at_hdmac.c:424:13: warning: 'atc_cleanup_descriptors' defined but not used [-Wunused-function]
static void atc_cleanup_descriptors(struct at_dma_chan *atchan)

             ^

---

This may not be the right solution, but it should get fixed in linux-next in some way.

Elen, please address this appropriately.

Arnd

drivers/dma/at_hdmac.c +1 -1
index 6db5228..09929c8 100644
@@ -421,7 +421,7 @@ static void atc_complete_all(struct at_dma_chan *atchan)
  *
  * Called with atchan->lock held and bh disabled
  */
-static void atc_cleanup_descriptors(struct at_dma_chan *atchan)
+static void __maybe_unused atc_cleanup_descriptors(struct at_dma_chan *atchan)
 {
 	struct at_desc	*desc, *_desc;
 	struct at_desc	*child;
#1 lore raw

Hi Arnd:

Quoted 7 lines · Arnd Bergmann

Patch 7c407d3e "DMA: AT91: Get residual bytes in dma buffer" causes a build warning

/git/arm-soc/drivers/dma/at_hdmac.c:424:13: warning: 'atc_cleanup_descriptors' defined but not used [-Wunused-function]
static void atc_cleanup_descriptors(struct at_dma_chan *atchan)

              ^
Quoted 7 lines

---

This may not be the right solution, but it should get fixed in linux-next in some way.

Elen, please address this appropriately.

OK.

Quoted 9 lines

Arnd

drivers/dma/at_hdmac.c +0 -0
index 6db5228..09929c8 100644

drivers/dma/at_hdmac.c static void atc_complete_all(struct at_dma_chan *atchan) · line 427

Quoted 8 lines
drivers/dma/at_hdmac.c +1 -1
@@ -421,7 +421,7 @@ static void atc_complete_all(struct at_dma_chan *atchan)
   *
   * Called with atchan->lock held and bh disabled
   */
-static void atc_cleanup_descriptors(struct at_dma_chan *atchan)
+static void __maybe_unused atc_cleanup_descriptors(struct at_dma_chan *atchan)
  {
  	struct at_desc	*desc, *_desc;
  	struct at_desc	*child;

Hi Nicolas and Ludovic:

I think atc_cleanup_descriptors could be removed, because ATC_DONE will no longer support, what you think?

Best Regards
Elen song