diff options
author | Kees Cook <keescook@chromium.org> | 2017-10-25 06:53:42 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-10-26 23:09:16 -0400 |
commit | e2009be038143b4a8c7d4b51b74da63220739a74 (patch) | |
tree | 7bc7bba2f946a36db5f12bb212e1c97be23a561a /drivers/net/wan/dscc4.c | |
parent | c37631c7f686518157de4aa5fb456a54f27607b6 (diff) |
drivers/net: wan/dscc4: Remove unused timer
This removes an entirely unused timer, which avoids needing to convert it
to timer_setup().
Cc: Francois Romieu <romieu@fr.zoreil.com>
Cc: netdev@vger.kernel.org
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/wan/dscc4.c')
-rw-r--r-- | drivers/net/wan/dscc4.c | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/drivers/net/wan/dscc4.c b/drivers/net/wan/dscc4.c index 64f176496da4..c0b0f525c87c 100644 --- a/drivers/net/wan/dscc4.c +++ b/drivers/net/wan/dscc4.c | |||
@@ -223,8 +223,6 @@ struct dscc4_dev_priv { | |||
223 | 223 | ||
224 | u32 scc_regs[SCC_REGISTERS_MAX]; /* Cf errata DS5 p.4 */ | 224 | u32 scc_regs[SCC_REGISTERS_MAX]; /* Cf errata DS5 p.4 */ |
225 | 225 | ||
226 | struct timer_list timer; | ||
227 | |||
228 | struct dscc4_pci_priv *pci_priv; | 226 | struct dscc4_pci_priv *pci_priv; |
229 | spinlock_t lock; | 227 | spinlock_t lock; |
230 | 228 | ||
@@ -369,7 +367,6 @@ static int dscc4_close(struct net_device *); | |||
369 | static int dscc4_ioctl(struct net_device *dev, struct ifreq *rq, int cmd); | 367 | static int dscc4_ioctl(struct net_device *dev, struct ifreq *rq, int cmd); |
370 | static int dscc4_init_ring(struct net_device *); | 368 | static int dscc4_init_ring(struct net_device *); |
371 | static void dscc4_release_ring(struct dscc4_dev_priv *); | 369 | static void dscc4_release_ring(struct dscc4_dev_priv *); |
372 | static void dscc4_timer(unsigned long); | ||
373 | static void dscc4_tx_timeout(struct net_device *); | 370 | static void dscc4_tx_timeout(struct net_device *); |
374 | static irqreturn_t dscc4_irq(int irq, void *dev_id); | 371 | static irqreturn_t dscc4_irq(int irq, void *dev_id); |
375 | static int dscc4_hdlc_attach(struct net_device *, unsigned short, unsigned short); | 372 | static int dscc4_hdlc_attach(struct net_device *, unsigned short, unsigned short); |
@@ -983,19 +980,6 @@ err_out: | |||
983 | return ret; | 980 | return ret; |
984 | }; | 981 | }; |
985 | 982 | ||
986 | /* FIXME: get rid of the unneeded code */ | ||
987 | static void dscc4_timer(unsigned long data) | ||
988 | { | ||
989 | struct net_device *dev = (struct net_device *)data; | ||
990 | struct dscc4_dev_priv *dpriv = dscc4_priv(dev); | ||
991 | // struct dscc4_pci_priv *ppriv; | ||
992 | |||
993 | goto done; | ||
994 | done: | ||
995 | dpriv->timer.expires = jiffies + TX_TIMEOUT; | ||
996 | add_timer(&dpriv->timer); | ||
997 | } | ||
998 | |||
999 | static void dscc4_tx_timeout(struct net_device *dev) | 983 | static void dscc4_tx_timeout(struct net_device *dev) |
1000 | { | 984 | { |
1001 | /* FIXME: something is missing there */ | 985 | /* FIXME: something is missing there */ |
@@ -1127,9 +1111,6 @@ static int dscc4_open(struct net_device *dev) | |||
1127 | done: | 1111 | done: |
1128 | netif_start_queue(dev); | 1112 | netif_start_queue(dev); |
1129 | 1113 | ||
1130 | setup_timer(&dpriv->timer, dscc4_timer, (unsigned long)dev); | ||
1131 | dpriv->timer.expires = jiffies + 10*HZ; | ||
1132 | add_timer(&dpriv->timer); | ||
1133 | netif_carrier_on(dev); | 1114 | netif_carrier_on(dev); |
1134 | 1115 | ||
1135 | return 0; | 1116 | return 0; |
@@ -1197,7 +1178,6 @@ static int dscc4_close(struct net_device *dev) | |||
1197 | { | 1178 | { |
1198 | struct dscc4_dev_priv *dpriv = dscc4_priv(dev); | 1179 | struct dscc4_dev_priv *dpriv = dscc4_priv(dev); |
1199 | 1180 | ||
1200 | del_timer_sync(&dpriv->timer); | ||
1201 | netif_stop_queue(dev); | 1181 | netif_stop_queue(dev); |
1202 | 1182 | ||
1203 | scc_patchl(PowerUp | Vis, 0, dpriv, dev, CCR0); | 1183 | scc_patchl(PowerUp | Vis, 0, dpriv, dev, CCR0); |