Skip to contentSkip to conversation

net: sxgbe: make "core_ops" static

PATCH Applied Dan Carpenter 2 participants 2 messages Apr 1, 2014

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

PATCH 3/3 net: sxgbe: make "core_ops" static

The "core_ops" variable isn't referenced outside this file and Sparse complains about it:

drivers/net/ethernet/samsung/sxgbe/sxgbe_core.c:239:29: warning:
symbol 'core_ops' was not declared. Should it be static?

drivers/net/ethernet/samsung/sxgbe/sxgbe_core.c +1 -1
index 2e11da0..c4da7a2 100644
@@ -236,7 +236,7 @@ static void sxgbe_disable_rx_csum(void __iomem *ioaddr)
 	writel(ctrl, ioaddr + SXGBE_CORE_RX_CONFIG_REG);
 }
 
-const struct sxgbe_core_ops core_ops = {
+static const struct sxgbe_core_ops core_ops = {
 	.core_init		= sxgbe_core_init,
 	.dump_regs		= sxgbe_core_dump_regs,
 	.host_irq_status	= sxgbe_core_host_irq_status,
maintainer Applied
#1 lore raw

From: Dan Carpenter <[email protected]>
Date: Tue, 1 Apr 2014 16:39:18 +0300

Quoted 7 lines

The "core_ops" variable isn't referenced outside this file and Sparse complains about it:

drivers/net/ethernet/samsung/sxgbe/sxgbe_core.c:239:29: warning:
symbol 'core_ops' was not declared. Should it be static?

Applied.