All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] [media] vpdma: remove vpdma_enable_list_notify_irq()
@ 2016-11-22 10:20 Mauro Carvalho Chehab
  0 siblings, 0 replies; only message in thread
From: Mauro Carvalho Chehab @ 2016-11-22 10:20 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab, Benoit Parrot, Mauro Carvalho Chehab,
	Hans Verkuil

Despite being exported, there's no prototype for it at the
headers, as warned by sparse:

Fixes this sparse warning:
	drivers/media/platform/ti-vpe/vpdma.c:1000:6: warning: no previous prototype for 'vpdma_enable_list_notify_irq' [-Wmissing-prototypes]
	 void vpdma_enable_list_notify_irq(struct vpdma_data *vpdma, int irq_num,
	      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~

Worse than that, it is not even used, as making it static it
would produce:

	drivers/media/platform/ti-vpe/vpdma.c:1000:13: warning: 'vpdma_enable_list_notify_irq' defined but not used [-Wunused-function]
	 static void vpdma_enable_list_notify_irq(struct vpdma_data *vpdma, int irq_num,
	             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~

So, let's just get rid of the dead code. If needed in the future,
someone could re-add it.

Cc: Benoit Parrot <bparrot@ti.com>
Cc: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 drivers/media/platform/ti-vpe/vpdma.c | 16 ----------------
 1 file changed, 16 deletions(-)

diff --git a/drivers/media/platform/ti-vpe/vpdma.c b/drivers/media/platform/ti-vpe/vpdma.c
index c8f842fd7f75..13bfd7184160 100644
--- a/drivers/media/platform/ti-vpe/vpdma.c
+++ b/drivers/media/platform/ti-vpe/vpdma.c
@@ -996,22 +996,6 @@ void vpdma_enable_list_complete_irq(struct vpdma_data *vpdma, int irq_num,
 }
 EXPORT_SYMBOL(vpdma_enable_list_complete_irq);
 
-/* set or clear the mask for list complete interrupt */
-void vpdma_enable_list_notify_irq(struct vpdma_data *vpdma, int irq_num,
-		int list_num, bool enable)
-{
-	u32 reg_addr = VPDMA_INT_LIST0_MASK + VPDMA_INTX_OFFSET * irq_num;
-	u32 val;
-
-	val = read_reg(vpdma, reg_addr);
-	if (enable)
-		val |= (1 << ((list_num * 2) + 1));
-	else
-		val &= ~(1 << ((list_num * 2) + 1));
-	write_reg(vpdma, reg_addr, val);
-}
-EXPORT_SYMBOL(vpdma_enable_list_notify_irq);
-
 /* get the LIST_STAT register */
 unsigned int vpdma_get_list_stat(struct vpdma_data *vpdma, int irq_num)
 {
-- 
2.9.3


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2016-11-22 10:20 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-22 10:20 [PATCH] [media] vpdma: remove vpdma_enable_list_notify_irq() Mauro Carvalho Chehab

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.