aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorstephen hemminger <shemminger@vyatta.com>2011-11-16 08:42:57 -0500
committerDavid S. Miller <davem@davemloft.net>2011-11-16 20:27:11 -0500
commit926d0977b28793533a99ec66484385b5f602e9c8 (patch)
tree0f396bb2f2deb46650779be4342a634a32a168f5 /drivers
parentf9687c44d322ca1bcbc362c8a54084425fda3ab8 (diff)
sky2: rename up/down functions
The code is clearer if the up/down functions are renamed to open/close like other drivers. Purely syntax change. Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/ethernet/marvell/sky2.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/drivers/net/ethernet/marvell/sky2.c b/drivers/net/ethernet/marvell/sky2.c
index 98ad38a5588f..98d435a187b1 100644
--- a/drivers/net/ethernet/marvell/sky2.c
+++ b/drivers/net/ethernet/marvell/sky2.c
@@ -1728,7 +1728,7 @@ static int sky2_setup_irq(struct sky2_hw *hw, const char *name)
1728 1728
1729 1729
1730/* Bring up network interface. */ 1730/* Bring up network interface. */
1731static int sky2_up(struct net_device *dev) 1731static int sky2_open(struct net_device *dev)
1732{ 1732{
1733 struct sky2_port *sky2 = netdev_priv(dev); 1733 struct sky2_port *sky2 = netdev_priv(dev);
1734 struct sky2_hw *hw = sky2->hw; 1734 struct sky2_hw *hw = sky2->hw;
@@ -2098,7 +2098,7 @@ static void sky2_hw_down(struct sky2_port *sky2)
2098} 2098}
2099 2099
2100/* Network shutdown */ 2100/* Network shutdown */
2101static int sky2_down(struct net_device *dev) 2101static int sky2_close(struct net_device *dev)
2102{ 2102{
2103 struct sky2_port *sky2 = netdev_priv(dev); 2103 struct sky2_port *sky2 = netdev_priv(dev);
2104 struct sky2_hw *hw = sky2->hw; 2104 struct sky2_hw *hw = sky2->hw;
@@ -2601,7 +2601,7 @@ static inline void sky2_tx_done(struct net_device *dev, u16 last)
2601 if (netif_running(dev)) { 2601 if (netif_running(dev)) {
2602 sky2_tx_complete(sky2, last); 2602 sky2_tx_complete(sky2, last);
2603 2603
2604 /* Wake unless it's detached, and called e.g. from sky2_down() */ 2604 /* Wake unless it's detached, and called e.g. from sky2_close() */
2605 if (tx_avail(sky2) > MAX_SKB_TX_LE + 4) 2605 if (tx_avail(sky2) > MAX_SKB_TX_LE + 4)
2606 netif_wake_queue(dev); 2606 netif_wake_queue(dev);
2607 } 2607 }
@@ -3391,7 +3391,7 @@ static void sky2_detach(struct net_device *dev)
3391 netif_tx_lock(dev); 3391 netif_tx_lock(dev);
3392 netif_device_detach(dev); /* stop txq */ 3392 netif_device_detach(dev); /* stop txq */
3393 netif_tx_unlock(dev); 3393 netif_tx_unlock(dev);
3394 sky2_down(dev); 3394 sky2_close(dev);
3395 } 3395 }
3396} 3396}
3397 3397
@@ -3401,7 +3401,7 @@ static int sky2_reattach(struct net_device *dev)
3401 int err = 0; 3401 int err = 0;
3402 3402
3403 if (netif_running(dev)) { 3403 if (netif_running(dev)) {
3404 err = sky2_up(dev); 3404 err = sky2_open(dev);
3405 if (err) { 3405 if (err) {
3406 netdev_info(dev, "could not restart %d\n", err); 3406 netdev_info(dev, "could not restart %d\n", err);
3407 dev_close(dev); 3407 dev_close(dev);
@@ -4568,7 +4568,7 @@ static int sky2_device_event(struct notifier_block *unused,
4568 struct net_device *dev = ptr; 4568 struct net_device *dev = ptr;
4569 struct sky2_port *sky2 = netdev_priv(dev); 4569 struct sky2_port *sky2 = netdev_priv(dev);
4570 4570
4571 if (dev->netdev_ops->ndo_open != sky2_up || !sky2_debug) 4571 if (dev->netdev_ops->ndo_open != sky2_open || !sky2_debug)
4572 return NOTIFY_DONE; 4572 return NOTIFY_DONE;
4573 4573
4574 switch (event) { 4574 switch (event) {
@@ -4633,8 +4633,8 @@ static __exit void sky2_debug_cleanup(void)
4633 not allowing netpoll on second port */ 4633 not allowing netpoll on second port */
4634static const struct net_device_ops sky2_netdev_ops[2] = { 4634static const struct net_device_ops sky2_netdev_ops[2] = {
4635 { 4635 {
4636 .ndo_open = sky2_up, 4636 .ndo_open = sky2_open,
4637 .ndo_stop = sky2_down, 4637 .ndo_stop = sky2_close,
4638 .ndo_start_xmit = sky2_xmit_frame, 4638 .ndo_start_xmit = sky2_xmit_frame,
4639 .ndo_do_ioctl = sky2_ioctl, 4639 .ndo_do_ioctl = sky2_ioctl,
4640 .ndo_validate_addr = eth_validate_addr, 4640 .ndo_validate_addr = eth_validate_addr,
@@ -4650,8 +4650,8 @@ static const struct net_device_ops sky2_netdev_ops[2] = {
4650#endif 4650#endif
4651 }, 4651 },
4652 { 4652 {
4653 .ndo_open = sky2_up, 4653 .ndo_open = sky2_open,
4654 .ndo_stop = sky2_down, 4654 .ndo_stop = sky2_close,
4655 .ndo_start_xmit = sky2_xmit_frame, 4655 .ndo_start_xmit = sky2_xmit_frame,
4656 .ndo_do_ioctl = sky2_ioctl, 4656 .ndo_do_ioctl = sky2_ioctl,
4657 .ndo_validate_addr = eth_validate_addr, 4657 .ndo_validate_addr = eth_validate_addr,