diff options
author | Mithlesh Thukral <mithlesh@linsyssoft.com> | 2009-05-25 09:36:16 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-06-19 14:00:38 -0400 |
commit | 75f49e07520d036c2a0903694fdc0bcfb5523b76 (patch) | |
tree | c049a32d58d6406aee35d2dac769ef758f5f499b /drivers/staging/wlan-ng/p80211netdev.c | |
parent | 1611a52c395e6036725104af3a74a0cef8ea42b8 (diff) |
Staging: wlan-ng: Lindent cleanups
Lindent script cleanups in wlan-ng driver in the staging tree.
This is a item in the TODO list.
Signed-off-by: Mithlesh Thukral <mithlesh@linsyssoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/wlan-ng/p80211netdev.c')
-rw-r--r-- | drivers/staging/wlan-ng/p80211netdev.c | 84 |
1 files changed, 42 insertions, 42 deletions
diff --git a/drivers/staging/wlan-ng/p80211netdev.c b/drivers/staging/wlan-ng/p80211netdev.c index ef8e459214b..90f499e00dc 100644 --- a/drivers/staging/wlan-ng/p80211netdev.c +++ b/drivers/staging/wlan-ng/p80211netdev.c | |||
@@ -94,18 +94,18 @@ | |||
94 | static void p80211netdev_rx_bh(unsigned long arg); | 94 | static void p80211netdev_rx_bh(unsigned long arg); |
95 | 95 | ||
96 | /* netdevice method functions */ | 96 | /* netdevice method functions */ |
97 | static int p80211knetdev_init(netdevice_t *netdev); | 97 | static int p80211knetdev_init(netdevice_t * netdev); |
98 | static struct net_device_stats *p80211knetdev_get_stats(netdevice_t *netdev); | 98 | static struct net_device_stats *p80211knetdev_get_stats(netdevice_t * netdev); |
99 | static int p80211knetdev_open(netdevice_t *netdev); | 99 | static int p80211knetdev_open(netdevice_t * netdev); |
100 | static int p80211knetdev_stop(netdevice_t *netdev); | 100 | static int p80211knetdev_stop(netdevice_t * netdev); |
101 | static int p80211knetdev_hard_start_xmit(struct sk_buff *skb, | 101 | static int p80211knetdev_hard_start_xmit(struct sk_buff *skb, |
102 | netdevice_t *netdev); | 102 | netdevice_t * netdev); |
103 | static void p80211knetdev_set_multicast_list(netdevice_t *dev); | 103 | static void p80211knetdev_set_multicast_list(netdevice_t * dev); |
104 | static int p80211knetdev_do_ioctl(netdevice_t *dev, struct ifreq *ifr, | 104 | static int p80211knetdev_do_ioctl(netdevice_t * dev, struct ifreq *ifr, |
105 | int cmd); | 105 | int cmd); |
106 | static int p80211knetdev_set_mac_address(netdevice_t *dev, void *addr); | 106 | static int p80211knetdev_set_mac_address(netdevice_t * dev, void *addr); |
107 | static void p80211knetdev_tx_timeout(netdevice_t *netdev); | 107 | static void p80211knetdev_tx_timeout(netdevice_t * netdev); |
108 | static int p80211_rx_typedrop(wlandevice_t *wlandev, u16 fc); | 108 | static int p80211_rx_typedrop(wlandevice_t * wlandev, u16 fc); |
109 | 109 | ||
110 | int wlan_watchdog = 5000; | 110 | int wlan_watchdog = 5000; |
111 | module_param(wlan_watchdog, int, 0644); | 111 | module_param(wlan_watchdog, int, 0644); |
@@ -127,7 +127,7 @@ MODULE_PARM_DESC(wlan_wext_write, "enable write wireless extensions"); | |||
127 | * Returns: | 127 | * Returns: |
128 | * nothing | 128 | * nothing |
129 | ----------------------------------------------------------------*/ | 129 | ----------------------------------------------------------------*/ |
130 | static int p80211knetdev_init(netdevice_t *netdev) | 130 | static int p80211knetdev_init(netdevice_t * netdev) |
131 | { | 131 | { |
132 | /* Called in response to register_netdev */ | 132 | /* Called in response to register_netdev */ |
133 | /* This is usually the probe function, but the probe has */ | 133 | /* This is usually the probe function, but the probe has */ |
@@ -150,7 +150,7 @@ static int p80211knetdev_init(netdevice_t *netdev) | |||
150 | * Returns: | 150 | * Returns: |
151 | * the address of the statistics structure | 151 | * the address of the statistics structure |
152 | ----------------------------------------------------------------*/ | 152 | ----------------------------------------------------------------*/ |
153 | static struct net_device_stats *p80211knetdev_get_stats(netdevice_t *netdev) | 153 | static struct net_device_stats *p80211knetdev_get_stats(netdevice_t * netdev) |
154 | { | 154 | { |
155 | wlandevice_t *wlandev = netdev->ml_priv; | 155 | wlandevice_t *wlandev = netdev->ml_priv; |
156 | 156 | ||
@@ -174,7 +174,7 @@ static struct net_device_stats *p80211knetdev_get_stats(netdevice_t *netdev) | |||
174 | * Returns: | 174 | * Returns: |
175 | * zero on success, non-zero otherwise | 175 | * zero on success, non-zero otherwise |
176 | ----------------------------------------------------------------*/ | 176 | ----------------------------------------------------------------*/ |
177 | static int p80211knetdev_open(netdevice_t *netdev) | 177 | static int p80211knetdev_open(netdevice_t * netdev) |
178 | { | 178 | { |
179 | int result = 0; /* success */ | 179 | int result = 0; /* success */ |
180 | wlandevice_t *wlandev = netdev->ml_priv; | 180 | wlandevice_t *wlandev = netdev->ml_priv; |
@@ -209,7 +209,7 @@ static int p80211knetdev_open(netdevice_t *netdev) | |||
209 | * Returns: | 209 | * Returns: |
210 | * zero on success, non-zero otherwise | 210 | * zero on success, non-zero otherwise |
211 | ----------------------------------------------------------------*/ | 211 | ----------------------------------------------------------------*/ |
212 | static int p80211knetdev_stop(netdevice_t *netdev) | 212 | static int p80211knetdev_stop(netdevice_t * netdev) |
213 | { | 213 | { |
214 | int result = 0; | 214 | int result = 0; |
215 | wlandevice_t *wlandev = netdev->ml_priv; | 215 | wlandevice_t *wlandev = netdev->ml_priv; |
@@ -236,7 +236,7 @@ static int p80211knetdev_stop(netdevice_t *netdev) | |||
236 | * Side effects: | 236 | * Side effects: |
237 | * | 237 | * |
238 | ----------------------------------------------------------------*/ | 238 | ----------------------------------------------------------------*/ |
239 | void p80211netdev_rx(wlandevice_t *wlandev, struct sk_buff *skb) | 239 | void p80211netdev_rx(wlandevice_t * wlandev, struct sk_buff *skb) |
240 | { | 240 | { |
241 | /* Enqueue for post-irq processing */ | 241 | /* Enqueue for post-irq processing */ |
242 | skb_queue_tail(&wlandev->nsd_rxq, skb); | 242 | skb_queue_tail(&wlandev->nsd_rxq, skb); |
@@ -345,7 +345,7 @@ static void p80211netdev_rx_bh(unsigned long arg) | |||
345 | * zero on success, non-zero on failure. | 345 | * zero on success, non-zero on failure. |
346 | ----------------------------------------------------------------*/ | 346 | ----------------------------------------------------------------*/ |
347 | static int p80211knetdev_hard_start_xmit(struct sk_buff *skb, | 347 | static int p80211knetdev_hard_start_xmit(struct sk_buff *skb, |
348 | netdevice_t *netdev) | 348 | netdevice_t * netdev) |
349 | { | 349 | { |
350 | int result = 0; | 350 | int result = 0; |
351 | int txresult = -1; | 351 | int txresult = -1; |
@@ -409,7 +409,7 @@ static int p80211knetdev_hard_start_xmit(struct sk_buff *skb, | |||
409 | &p80211_wep) != 0) { | 409 | &p80211_wep) != 0) { |
410 | /* convert failed */ | 410 | /* convert failed */ |
411 | pr_debug("ether_to_80211(%d) failed.\n", | 411 | pr_debug("ether_to_80211(%d) failed.\n", |
412 | wlandev->ethconv); | 412 | wlandev->ethconv); |
413 | result = 1; | 413 | result = 1; |
414 | goto failed; | 414 | goto failed; |
415 | } | 415 | } |
@@ -472,7 +472,7 @@ failed: | |||
472 | * Returns: | 472 | * Returns: |
473 | * nothing | 473 | * nothing |
474 | ----------------------------------------------------------------*/ | 474 | ----------------------------------------------------------------*/ |
475 | static void p80211knetdev_set_multicast_list(netdevice_t *dev) | 475 | static void p80211knetdev_set_multicast_list(netdevice_t * dev) |
476 | { | 476 | { |
477 | wlandevice_t *wlandev = dev->ml_priv; | 477 | wlandevice_t *wlandev = dev->ml_priv; |
478 | 478 | ||
@@ -485,7 +485,7 @@ static void p80211knetdev_set_multicast_list(netdevice_t *dev) | |||
485 | 485 | ||
486 | #ifdef SIOCETHTOOL | 486 | #ifdef SIOCETHTOOL |
487 | 487 | ||
488 | static int p80211netdev_ethtool(wlandevice_t *wlandev, void __user *useraddr) | 488 | static int p80211netdev_ethtool(wlandevice_t * wlandev, void __user * useraddr) |
489 | { | 489 | { |
490 | u32 ethcmd; | 490 | u32 ethcmd; |
491 | struct ethtool_drvinfo info; | 491 | struct ethtool_drvinfo info; |
@@ -557,7 +557,7 @@ static int p80211netdev_ethtool(wlandevice_t *wlandev, void __user *useraddr) | |||
557 | * Process thread (ioctl caller). TODO: SMP support may require | 557 | * Process thread (ioctl caller). TODO: SMP support may require |
558 | * locks. | 558 | * locks. |
559 | ----------------------------------------------------------------*/ | 559 | ----------------------------------------------------------------*/ |
560 | static int p80211knetdev_do_ioctl(netdevice_t *dev, struct ifreq *ifr, int cmd) | 560 | static int p80211knetdev_do_ioctl(netdevice_t * dev, struct ifreq *ifr, int cmd) |
561 | { | 561 | { |
562 | int result = 0; | 562 | int result = 0; |
563 | p80211ioctl_req_t *req = (p80211ioctl_req_t *) ifr; | 563 | p80211ioctl_req_t *req = (p80211ioctl_req_t *) ifr; |
@@ -634,7 +634,7 @@ bail: | |||
634 | * | 634 | * |
635 | * by: Collin R. Mulliner <collin@mulliner.org> | 635 | * by: Collin R. Mulliner <collin@mulliner.org> |
636 | ----------------------------------------------------------------*/ | 636 | ----------------------------------------------------------------*/ |
637 | static int p80211knetdev_set_mac_address(netdevice_t *dev, void *addr) | 637 | static int p80211knetdev_set_mac_address(netdevice_t * dev, void *addr) |
638 | { | 638 | { |
639 | struct sockaddr *new_addr = addr; | 639 | struct sockaddr *new_addr = addr; |
640 | p80211msg_dot11req_mibset_t dot11req; | 640 | p80211msg_dot11req_mibset_t dot11req; |
@@ -649,7 +649,7 @@ static int p80211knetdev_set_mac_address(netdevice_t *dev, void *addr) | |||
649 | 649 | ||
650 | /* Set up some convenience pointers. */ | 650 | /* Set up some convenience pointers. */ |
651 | mibattr = &dot11req.mibattribute; | 651 | mibattr = &dot11req.mibattribute; |
652 | macaddr = (p80211item_pstr6_t *)&mibattr->data; | 652 | macaddr = (p80211item_pstr6_t *) & mibattr->data; |
653 | resultcode = &dot11req.resultcode; | 653 | resultcode = &dot11req.resultcode; |
654 | 654 | ||
655 | /* Set up a dot11req_mibset */ | 655 | /* Set up a dot11req_mibset */ |
@@ -677,7 +677,7 @@ static int p80211knetdev_set_mac_address(netdevice_t *dev, void *addr) | |||
677 | resultcode->data = 0; | 677 | resultcode->data = 0; |
678 | 678 | ||
679 | /* now fire the request */ | 679 | /* now fire the request */ |
680 | result = p80211req_dorequest(dev->ml_priv, (u8 *)&dot11req); | 680 | result = p80211req_dorequest(dev->ml_priv, (u8 *) & dot11req); |
681 | 681 | ||
682 | /* If the request wasn't successful, report an error and don't | 682 | /* If the request wasn't successful, report an error and don't |
683 | * change the netdev address | 683 | * change the netdev address |
@@ -694,7 +694,7 @@ static int p80211knetdev_set_mac_address(netdevice_t *dev, void *addr) | |||
694 | return result; | 694 | return result; |
695 | } | 695 | } |
696 | 696 | ||
697 | static int wlan_change_mtu(netdevice_t *dev, int new_mtu) | 697 | static int wlan_change_mtu(netdevice_t * dev, int new_mtu) |
698 | { | 698 | { |
699 | /* 2312 is max 802.11 payload, 20 is overhead, (ether + llc +snap) | 699 | /* 2312 is max 802.11 payload, 20 is overhead, (ether + llc +snap) |
700 | and another 8 for wep. */ | 700 | and another 8 for wep. */ |
@@ -707,17 +707,17 @@ static int wlan_change_mtu(netdevice_t *dev, int new_mtu) | |||
707 | } | 707 | } |
708 | 708 | ||
709 | static const struct net_device_ops p80211_netdev_ops = { | 709 | static const struct net_device_ops p80211_netdev_ops = { |
710 | .ndo_init = p80211knetdev_init, | 710 | .ndo_init = p80211knetdev_init, |
711 | .ndo_open = p80211knetdev_open, | 711 | .ndo_open = p80211knetdev_open, |
712 | .ndo_stop = p80211knetdev_stop, | 712 | .ndo_stop = p80211knetdev_stop, |
713 | .ndo_get_stats = p80211knetdev_get_stats, | 713 | .ndo_get_stats = p80211knetdev_get_stats, |
714 | .ndo_start_xmit = p80211knetdev_hard_start_xmit, | 714 | .ndo_start_xmit = p80211knetdev_hard_start_xmit, |
715 | .ndo_set_multicast_list = p80211knetdev_set_multicast_list, | 715 | .ndo_set_multicast_list = p80211knetdev_set_multicast_list, |
716 | .ndo_do_ioctl = p80211knetdev_do_ioctl, | 716 | .ndo_do_ioctl = p80211knetdev_do_ioctl, |
717 | .ndo_set_mac_address = p80211knetdev_set_mac_address, | 717 | .ndo_set_mac_address = p80211knetdev_set_mac_address, |
718 | .ndo_tx_timeout = p80211knetdev_tx_timeout, | 718 | .ndo_tx_timeout = p80211knetdev_tx_timeout, |
719 | .ndo_change_mtu = wlan_change_mtu, | 719 | .ndo_change_mtu = wlan_change_mtu, |
720 | .ndo_validate_addr = eth_validate_addr, | 720 | .ndo_validate_addr = eth_validate_addr, |
721 | }; | 721 | }; |
722 | 722 | ||
723 | /*---------------------------------------------------------------- | 723 | /*---------------------------------------------------------------- |
@@ -742,7 +742,7 @@ static const struct net_device_ops p80211_netdev_ops = { | |||
742 | * compiled drivers, this function will be called in the | 742 | * compiled drivers, this function will be called in the |
743 | * context of the kernel startup code. | 743 | * context of the kernel startup code. |
744 | ----------------------------------------------------------------*/ | 744 | ----------------------------------------------------------------*/ |
745 | int wlan_setup(wlandevice_t *wlandev) | 745 | int wlan_setup(wlandevice_t * wlandev) |
746 | { | 746 | { |
747 | int result = 0; | 747 | int result = 0; |
748 | netdevice_t *dev; | 748 | netdevice_t *dev; |
@@ -800,7 +800,7 @@ int wlan_setup(wlandevice_t *wlandev) | |||
800 | * compiled drivers, this function will be called in the | 800 | * compiled drivers, this function will be called in the |
801 | * context of the kernel startup code. | 801 | * context of the kernel startup code. |
802 | ----------------------------------------------------------------*/ | 802 | ----------------------------------------------------------------*/ |
803 | int wlan_unsetup(wlandevice_t *wlandev) | 803 | int wlan_unsetup(wlandevice_t * wlandev) |
804 | { | 804 | { |
805 | int result = 0; | 805 | int result = 0; |
806 | 806 | ||
@@ -836,7 +836,7 @@ int wlan_unsetup(wlandevice_t *wlandev) | |||
836 | * Call Context: | 836 | * Call Context: |
837 | * Can be either interrupt or not. | 837 | * Can be either interrupt or not. |
838 | ----------------------------------------------------------------*/ | 838 | ----------------------------------------------------------------*/ |
839 | int register_wlandev(wlandevice_t *wlandev) | 839 | int register_wlandev(wlandevice_t * wlandev) |
840 | { | 840 | { |
841 | int i = 0; | 841 | int i = 0; |
842 | 842 | ||
@@ -864,7 +864,7 @@ int register_wlandev(wlandevice_t *wlandev) | |||
864 | * Call Context: | 864 | * Call Context: |
865 | * Can be either interrupt or not. | 865 | * Can be either interrupt or not. |
866 | ----------------------------------------------------------------*/ | 866 | ----------------------------------------------------------------*/ |
867 | int unregister_wlandev(wlandevice_t *wlandev) | 867 | int unregister_wlandev(wlandevice_t * wlandev) |
868 | { | 868 | { |
869 | struct sk_buff *skb; | 869 | struct sk_buff *skb; |
870 | 870 | ||
@@ -907,7 +907,7 @@ int unregister_wlandev(wlandevice_t *wlandev) | |||
907 | * Call context: | 907 | * Call context: |
908 | * Usually interrupt. | 908 | * Usually interrupt. |
909 | ----------------------------------------------------------------*/ | 909 | ----------------------------------------------------------------*/ |
910 | void p80211netdev_hwremoved(wlandevice_t *wlandev) | 910 | void p80211netdev_hwremoved(wlandevice_t * wlandev) |
911 | { | 911 | { |
912 | wlandev->hwremoved = 1; | 912 | wlandev->hwremoved = 1; |
913 | if (wlandev->state == WLAN_DEVICE_OPEN) | 913 | if (wlandev->state == WLAN_DEVICE_OPEN) |
@@ -937,7 +937,7 @@ void p80211netdev_hwremoved(wlandevice_t *wlandev) | |||
937 | * Call context: | 937 | * Call context: |
938 | * interrupt | 938 | * interrupt |
939 | ----------------------------------------------------------------*/ | 939 | ----------------------------------------------------------------*/ |
940 | static int p80211_rx_typedrop(wlandevice_t *wlandev, u16 fc) | 940 | static int p80211_rx_typedrop(wlandevice_t * wlandev, u16 fc) |
941 | { | 941 | { |
942 | u16 ftype; | 942 | u16 ftype; |
943 | u16 fstype; | 943 | u16 fstype; |
@@ -1095,7 +1095,7 @@ static int p80211_rx_typedrop(wlandevice_t *wlandev, u16 fc) | |||
1095 | return drop; | 1095 | return drop; |
1096 | } | 1096 | } |
1097 | 1097 | ||
1098 | static void p80211knetdev_tx_timeout(netdevice_t *netdev) | 1098 | static void p80211knetdev_tx_timeout(netdevice_t * netdev) |
1099 | { | 1099 | { |
1100 | wlandevice_t *wlandev = netdev->ml_priv; | 1100 | wlandevice_t *wlandev = netdev->ml_priv; |
1101 | 1101 | ||