diff options
author | Baoyou Xie <baoyou.xie@linaro.org> | 2016-09-24 00:37:05 -0400 |
---|---|---|
committer | Vinod Koul <vinod.koul@intel.com> | 2016-10-01 02:11:39 -0400 |
commit | 02aa84860c29f3f5a57e959982c811df46a2736c (patch) | |
tree | d81c14dd3b0fae3a85064b4afbe207a930ffa191 | |
parent | 3770f2a6bfe00869a4b83ee3cced0361ab33289a (diff) |
dmaengine: virt-dma: move function declarations
We get 2 warnings when building kernel with W=1:
drivers/dma/virt-dma.c:22:14: warning: no previous prototype for 'vchan_tx_submit' [-Wmissing-prototypes]
drivers/dma/virt-dma.c:52:5: warning: no previous prototype for 'vchan_tx_desc_free' [-Wmissing-prototypes]
In fact, these two functions are incorrectly declared in a function.
So this patch moves function declarations out of this function.
Signed-off-by: Baoyou Xie <baoyou.xie@linaro.org>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
-rw-r--r-- | drivers/dma/virt-dma.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/dma/virt-dma.h b/drivers/dma/virt-dma.h index a030ae7b1df2..3f776a46a29c 100644 --- a/drivers/dma/virt-dma.h +++ b/drivers/dma/virt-dma.h | |||
@@ -45,6 +45,8 @@ static inline struct virt_dma_chan *to_virt_chan(struct dma_chan *chan) | |||
45 | void vchan_dma_desc_free_list(struct virt_dma_chan *vc, struct list_head *head); | 45 | void vchan_dma_desc_free_list(struct virt_dma_chan *vc, struct list_head *head); |
46 | void vchan_init(struct virt_dma_chan *vc, struct dma_device *dmadev); | 46 | void vchan_init(struct virt_dma_chan *vc, struct dma_device *dmadev); |
47 | struct virt_dma_desc *vchan_find_desc(struct virt_dma_chan *, dma_cookie_t); | 47 | struct virt_dma_desc *vchan_find_desc(struct virt_dma_chan *, dma_cookie_t); |
48 | extern dma_cookie_t vchan_tx_submit(struct dma_async_tx_descriptor *); | ||
49 | extern int vchan_tx_desc_free(struct dma_async_tx_descriptor *); | ||
48 | 50 | ||
49 | /** | 51 | /** |
50 | * vchan_tx_prep - prepare a descriptor | 52 | * vchan_tx_prep - prepare a descriptor |
@@ -55,8 +57,6 @@ struct virt_dma_desc *vchan_find_desc(struct virt_dma_chan *, dma_cookie_t); | |||
55 | static inline struct dma_async_tx_descriptor *vchan_tx_prep(struct virt_dma_chan *vc, | 57 | static inline struct dma_async_tx_descriptor *vchan_tx_prep(struct virt_dma_chan *vc, |
56 | struct virt_dma_desc *vd, unsigned long tx_flags) | 58 | struct virt_dma_desc *vd, unsigned long tx_flags) |
57 | { | 59 | { |
58 | extern dma_cookie_t vchan_tx_submit(struct dma_async_tx_descriptor *); | ||
59 | extern int vchan_tx_desc_free(struct dma_async_tx_descriptor *); | ||
60 | unsigned long flags; | 60 | unsigned long flags; |
61 | 61 | ||
62 | dma_async_tx_descriptor_init(&vd->tx, &vc->chan); | 62 | dma_async_tx_descriptor_init(&vd->tx, &vc->chan); |