]> rtime.felk.cvut.cz Git - zynq/linux.git/commitdiff
v4l: xilinx: scd: Make local functions static
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Wed, 3 Apr 2019 20:01:42 +0000 (13:01 -0700)
committerMichal Simek <michal.simek@xilinx.com>
Fri, 5 Apr 2019 11:05:25 +0000 (13:05 +0200)
Several of the xscd_dma_* functions are only used in their compilation
unit. Make them static and remove their declaration from the common
header.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Hyun Kwon <hyun.kwon@xilinx.com>
drivers/media/platform/xilinx/xilinx-scenechange-dma.c
drivers/media/platform/xilinx/xilinx-scenechange.h

index b4f3b53c5c00b7795cca82f84c7dd3262c6c2d49..4621cbd26ae39225810417aec62ebe90e9e527c9 100644 (file)
@@ -82,7 +82,7 @@ static irqreturn_t xscd_dma_irq_handler(int irq, void *data)
  *
  * Return: The allocated descriptor on success and NULL on failure.
  */
-struct xscd_dma_tx_descriptor *
+static struct xscd_dma_tx_descriptor *
 xscd_dma_alloc_tx_descriptor(struct xscd_dma_chan *chan)
 {
        struct xscd_dma_tx_descriptor *desc;
@@ -100,7 +100,7 @@ xscd_dma_alloc_tx_descriptor(struct xscd_dma_chan *chan)
  *
  * Return: cookie value on success and failure value on error
  */
-dma_cookie_t xscd_dma_tx_submit(struct dma_async_tx_descriptor *tx)
+static dma_cookie_t xscd_dma_tx_submit(struct dma_async_tx_descriptor *tx)
 {
        struct xscd_dma_tx_descriptor *desc = to_xscd_dma_tx_descriptor(tx);
        struct xscd_dma_chan *chan = to_xscd_dma_chan(tx->chan);
@@ -183,8 +183,8 @@ void xscd_dma_start_transfer(struct xscd_dma_chan *chan)
  * @chan: Driver specific dma channel
  * @list: List to parse and delete the descriptor
  */
-void xscd_dma_free_desc_list(struct xscd_dma_chan *chan,
-                            struct list_head *list)
+static void xscd_dma_free_desc_list(struct xscd_dma_chan *chan,
+                                   struct list_head *list)
 {
        struct xscd_dma_tx_descriptor *desc, *next;
 
@@ -198,7 +198,7 @@ void xscd_dma_free_desc_list(struct xscd_dma_chan *chan,
  * xscd_dma_free_descriptors - Free channel descriptors
  * @chan: Driver specific dma channel
  */
-void xscd_dma_free_descriptors(struct xscd_dma_chan *chan)
+static void xscd_dma_free_descriptors(struct xscd_dma_chan *chan)
 {
        unsigned long flags;
 
@@ -221,7 +221,7 @@ void xscd_dma_free_descriptors(struct xscd_dma_chan *chan)
  * scd_dma_chan_desc_cleanup - Clean channel descriptors
  * @chan: Driver specific dma channel
  */
-void xscd_dma_chan_desc_cleanup(struct xscd_dma_chan *chan)
+static void xscd_dma_chan_desc_cleanup(struct xscd_dma_chan *chan)
 {
        struct xscd_dma_tx_descriptor *desc, *next;
        unsigned long flags;
@@ -253,7 +253,7 @@ void xscd_dma_chan_desc_cleanup(struct xscd_dma_chan *chan)
  * xscd_dma_chan_remove - Per Channel remove function
  * @chan: Driver specific DMA channel
  */
-void xscd_dma_chan_remove(struct xscd_dma_chan *chan)
+static void xscd_dma_chan_remove(struct xscd_dma_chan *chan)
 {
        list_del(&chan->common.device_node);
 }
index d53595fba4e136eeb8596fe8c0f62f02629ecdad..aee1c4af85d05fbd66a1a54d5623ca2f34116e00 100644 (file)
@@ -255,17 +255,9 @@ static inline void xscd_set(void __iomem *iomem, u32 addr, u32 set)
        xscd_write(iomem, addr, xscd_read(iomem, addr) | set);
 }
 
-struct xscd_dma_tx_descriptor *
-xscd_dma_alloc_tx_descriptor(struct xscd_dma_chan *chan);
 void xscd_dma_start_transfer(struct xscd_dma_chan *chan);
 void xscd_dma_start(struct xscd_dma_chan *chan);
 void xscd_dma_chan_enable(struct xscd_dma_chan *chan, int chan_en);
 void xscd_dma_reset(struct xscd_dma_chan *chan);
 void xscd_dma_halt(struct xscd_dma_chan *chan);
-void xscd_dma_free_desc_list(struct xscd_dma_chan *chan,
-                            struct list_head *list);
-void xscd_dma_free_descriptors(struct xscd_dma_chan *chan);
-dma_cookie_t xscd_dma_tx_submit(struct dma_async_tx_descriptor *tx);
-void xscd_dma_chan_desc_cleanup(struct xscd_dma_chan *chan);
-void xscd_dma_chan_remove(struct xscd_dma_chan *chan);
 #endif