Skip to content

Commit

Permalink
staging: wlan-ng: scripts/checkpatch.pl error fixes.
Browse files Browse the repository at this point in the history
scripts/checkpatch.pl error fixes. This is a TODO item.
This patch fixes most of the errors reported by checkpatch.pl in
wlan-ng directory of staging tree.

Signed-off-by: Mithlesh Thukral <mithlesh@linsyssoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Mithlesh Thukral authored and Greg Kroah-Hartman committed Sep 15, 2009
1 parent 0984e56 commit 297f06c
Show file tree
Hide file tree
Showing 11 changed files with 365 additions and 361 deletions.
202 changes: 101 additions & 101 deletions drivers/staging/wlan-ng/hfa384x_usb.c

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions drivers/staging/wlan-ng/p80211conv.c
Original file line number Diff line number Diff line change
Expand Up @@ -102,9 +102,9 @@ static u8 oui_8021h[] = { 0x00, 0x00, 0xf8 };
* Call context:
* May be called in interrupt or non-interrupt context
----------------------------------------------------------------*/
int skb_ether_to_p80211(wlandevice_t * wlandev, u32 ethconv,
struct sk_buff *skb, p80211_hdr_t * p80211_hdr,
p80211_metawep_t * p80211_wep)
int skb_ether_to_p80211(wlandevice_t *wlandev, u32 ethconv,
struct sk_buff *skb, p80211_hdr_t *p80211_hdr,
p80211_metawep_t *p80211_wep)
{

u16 fc;
Expand Down Expand Up @@ -230,8 +230,8 @@ int skb_ether_to_p80211(wlandevice_t * wlandev, u32 ethconv,
}

/* jkriegl: from orinoco, modified */
static void orinoco_spy_gather(wlandevice_t * wlandev, char *mac,
p80211_rxmeta_t * rxmeta)
static void orinoco_spy_gather(wlandevice_t *wlandev, char *mac,
p80211_rxmeta_t *rxmeta)
{
int i;

Expand Down Expand Up @@ -272,7 +272,7 @@ static void orinoco_spy_gather(wlandevice_t * wlandev, char *mac,
* Call context:
* May be called in interrupt or non-interrupt context
----------------------------------------------------------------*/
int skb_p80211_to_ether(wlandevice_t * wlandev, u32 ethconv,
int skb_p80211_to_ether(wlandevice_t *wlandev, u32 ethconv,
struct sk_buff *skb)
{
netdevice_t *netdev = wlandev->netdev;
Expand Down
54 changes: 27 additions & 27 deletions drivers/staging/wlan-ng/p80211netdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,18 +94,18 @@
static void p80211netdev_rx_bh(unsigned long arg);

/* netdevice method functions */
static int p80211knetdev_init(netdevice_t * netdev);
static struct net_device_stats *p80211knetdev_get_stats(netdevice_t * netdev);
static int p80211knetdev_open(netdevice_t * netdev);
static int p80211knetdev_stop(netdevice_t * netdev);
static int p80211knetdev_init(netdevice_t *netdev);
static struct net_device_stats *p80211knetdev_get_stats(netdevice_t *netdev);
static int p80211knetdev_open(netdevice_t *netdev);
static int p80211knetdev_stop(netdevice_t *netdev);
static int p80211knetdev_hard_start_xmit(struct sk_buff *skb,
netdevice_t * netdev);
static void p80211knetdev_set_multicast_list(netdevice_t * dev);
static int p80211knetdev_do_ioctl(netdevice_t * dev, struct ifreq *ifr,
netdevice_t *netdev);
static void p80211knetdev_set_multicast_list(netdevice_t *dev);
static int p80211knetdev_do_ioctl(netdevice_t *dev, struct ifreq *ifr,
int cmd);
static int p80211knetdev_set_mac_address(netdevice_t * dev, void *addr);
static void p80211knetdev_tx_timeout(netdevice_t * netdev);
static int p80211_rx_typedrop(wlandevice_t * wlandev, u16 fc);
static int p80211knetdev_set_mac_address(netdevice_t *dev, void *addr);
static void p80211knetdev_tx_timeout(netdevice_t *netdev);
static int p80211_rx_typedrop(wlandevice_t *wlandev, u16 fc);

int wlan_watchdog = 5000;
module_param(wlan_watchdog, int, 0644);
Expand All @@ -127,7 +127,7 @@ MODULE_PARM_DESC(wlan_wext_write, "enable write wireless extensions");
* Returns:
* nothing
----------------------------------------------------------------*/
static int p80211knetdev_init(netdevice_t * netdev)
static int p80211knetdev_init(netdevice_t *netdev)
{
/* Called in response to register_netdev */
/* This is usually the probe function, but the probe has */
Expand Down Expand Up @@ -174,7 +174,7 @@ static struct net_device_stats *p80211knetdev_get_stats(netdevice_t * netdev)
* Returns:
* zero on success, non-zero otherwise
----------------------------------------------------------------*/
static int p80211knetdev_open(netdevice_t * netdev)
static int p80211knetdev_open(netdevice_t *netdev)
{
int result = 0; /* success */
wlandevice_t *wlandev = netdev->ml_priv;
Expand Down Expand Up @@ -209,7 +209,7 @@ static int p80211knetdev_open(netdevice_t * netdev)
* Returns:
* zero on success, non-zero otherwise
----------------------------------------------------------------*/
static int p80211knetdev_stop(netdevice_t * netdev)
static int p80211knetdev_stop(netdevice_t *netdev)
{
int result = 0;
wlandevice_t *wlandev = netdev->ml_priv;
Expand All @@ -236,7 +236,7 @@ static int p80211knetdev_stop(netdevice_t * netdev)
* Side effects:
*
----------------------------------------------------------------*/
void p80211netdev_rx(wlandevice_t * wlandev, struct sk_buff *skb)
void p80211netdev_rx(wlandevice_t *wlandev, struct sk_buff *skb)
{
/* Enqueue for post-irq processing */
skb_queue_tail(&wlandev->nsd_rxq, skb);
Expand Down Expand Up @@ -345,7 +345,7 @@ static void p80211netdev_rx_bh(unsigned long arg)
* zero on success, non-zero on failure.
----------------------------------------------------------------*/
static int p80211knetdev_hard_start_xmit(struct sk_buff *skb,
netdevice_t * netdev)
netdevice_t *netdev)
{
int result = 0;
int txresult = -1;
Expand Down Expand Up @@ -472,7 +472,7 @@ static int p80211knetdev_hard_start_xmit(struct sk_buff *skb,
* Returns:
* nothing
----------------------------------------------------------------*/
static void p80211knetdev_set_multicast_list(netdevice_t * dev)
static void p80211knetdev_set_multicast_list(netdevice_t *dev)
{
wlandevice_t *wlandev = dev->ml_priv;

Expand All @@ -485,7 +485,7 @@ static void p80211knetdev_set_multicast_list(netdevice_t * dev)

#ifdef SIOCETHTOOL

static int p80211netdev_ethtool(wlandevice_t * wlandev, void __user * useraddr)
static int p80211netdev_ethtool(wlandevice_t *wlandev, void __user *useraddr)
{
u32 ethcmd;
struct ethtool_drvinfo info;
Expand Down Expand Up @@ -557,7 +557,7 @@ static int p80211netdev_ethtool(wlandevice_t * wlandev, void __user * useraddr)
* Process thread (ioctl caller). TODO: SMP support may require
* locks.
----------------------------------------------------------------*/
static int p80211knetdev_do_ioctl(netdevice_t * dev, struct ifreq *ifr, int cmd)
static int p80211knetdev_do_ioctl(netdevice_t *dev, struct ifreq *ifr, int cmd)
{
int result = 0;
p80211ioctl_req_t *req = (p80211ioctl_req_t *) ifr;
Expand Down Expand Up @@ -634,7 +634,7 @@ static int p80211knetdev_do_ioctl(netdevice_t * dev, struct ifreq *ifr, int cmd)
*
* by: Collin R. Mulliner <collin@mulliner.org>
----------------------------------------------------------------*/
static int p80211knetdev_set_mac_address(netdevice_t * dev, void *addr)
static int p80211knetdev_set_mac_address(netdevice_t *dev, void *addr)
{
struct sockaddr *new_addr = addr;
p80211msg_dot11req_mibset_t dot11req;
Expand Down Expand Up @@ -694,7 +694,7 @@ static int p80211knetdev_set_mac_address(netdevice_t * dev, void *addr)
return result;
}

static int wlan_change_mtu(netdevice_t * dev, int new_mtu)
static int wlan_change_mtu(netdevice_t *dev, int new_mtu)
{
/* 2312 is max 802.11 payload, 20 is overhead, (ether + llc +snap)
and another 8 for wep. */
Expand Down Expand Up @@ -742,7 +742,7 @@ static const struct net_device_ops p80211_netdev_ops = {
* compiled drivers, this function will be called in the
* context of the kernel startup code.
----------------------------------------------------------------*/
int wlan_setup(wlandevice_t * wlandev)
int wlan_setup(wlandevice_t *wlandev)
{
int result = 0;
netdevice_t *dev;
Expand Down Expand Up @@ -800,7 +800,7 @@ int wlan_setup(wlandevice_t * wlandev)
* compiled drivers, this function will be called in the
* context of the kernel startup code.
----------------------------------------------------------------*/
int wlan_unsetup(wlandevice_t * wlandev)
int wlan_unsetup(wlandevice_t *wlandev)
{
int result = 0;

Expand Down Expand Up @@ -836,7 +836,7 @@ int wlan_unsetup(wlandevice_t * wlandev)
* Call Context:
* Can be either interrupt or not.
----------------------------------------------------------------*/
int register_wlandev(wlandevice_t * wlandev)
int register_wlandev(wlandevice_t *wlandev)
{
int i = 0;

Expand Down Expand Up @@ -864,7 +864,7 @@ int register_wlandev(wlandevice_t * wlandev)
* Call Context:
* Can be either interrupt or not.
----------------------------------------------------------------*/
int unregister_wlandev(wlandevice_t * wlandev)
int unregister_wlandev(wlandevice_t *wlandev)
{
struct sk_buff *skb;

Expand Down Expand Up @@ -907,7 +907,7 @@ int unregister_wlandev(wlandevice_t * wlandev)
* Call context:
* Usually interrupt.
----------------------------------------------------------------*/
void p80211netdev_hwremoved(wlandevice_t * wlandev)
void p80211netdev_hwremoved(wlandevice_t *wlandev)
{
wlandev->hwremoved = 1;
if (wlandev->state == WLAN_DEVICE_OPEN)
Expand Down Expand Up @@ -937,7 +937,7 @@ void p80211netdev_hwremoved(wlandevice_t * wlandev)
* Call context:
* interrupt
----------------------------------------------------------------*/
static int p80211_rx_typedrop(wlandevice_t * wlandev, u16 fc)
static int p80211_rx_typedrop(wlandevice_t *wlandev, u16 fc)
{
u16 ftype;
u16 fstype;
Expand Down Expand Up @@ -1095,7 +1095,7 @@ static int p80211_rx_typedrop(wlandevice_t * wlandev, u16 fc)
return drop;
}

static void p80211knetdev_tx_timeout(netdevice_t * netdev)
static void p80211knetdev_tx_timeout(netdevice_t *netdev)
{
wlandevice_t *wlandev = netdev->ml_priv;

Expand Down
12 changes: 6 additions & 6 deletions drivers/staging/wlan-ng/p80211req.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,9 @@
#include "p80211metastruct.h"
#include "p80211req.h"

static void p80211req_handlemsg(wlandevice_t * wlandev, p80211msg_t * msg);
static int p80211req_mibset_mibget(wlandevice_t * wlandev,
p80211msg_dot11req_mibget_t * mib_msg,
static void p80211req_handlemsg(wlandevice_t *wlandev, p80211msg_t *msg);
static int p80211req_mibset_mibget(wlandevice_t *wlandev,
p80211msg_dot11req_mibget_t *mib_msg,
int isget);

/*----------------------------------------------------------------
Expand Down Expand Up @@ -150,7 +150,7 @@ int p80211req_dorequest(wlandevice_t * wlandev, u8 * msgbuf)
* Call context:
* Process thread
----------------------------------------------------------------*/
static void p80211req_handlemsg(wlandevice_t * wlandev, p80211msg_t * msg)
static void p80211req_handlemsg(wlandevice_t *wlandev, p80211msg_t *msg)
{
switch (msg->msgcode) {

Expand Down Expand Up @@ -180,8 +180,8 @@ static void p80211req_handlemsg(wlandevice_t * wlandev, p80211msg_t * msg)
return;
}

static int p80211req_mibset_mibget(wlandevice_t * wlandev,
p80211msg_dot11req_mibget_t * mib_msg,
static int p80211req_mibset_mibget(wlandevice_t *wlandev,
p80211msg_dot11req_mibget_t *mib_msg,
int isget)
{
p80211itemd_t *mibitem = (p80211itemd_t *) mib_msg->mibattribute.data;
Expand Down
12 changes: 6 additions & 6 deletions drivers/staging/wlan-ng/p80211wep.c
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
#include <linux/random.h>
#include <linux/kernel.h>

// #define WEP_DEBUG
/* #define WEP_DEBUG */

/*================================================================*/
/* Project Includes */
Expand Down Expand Up @@ -136,7 +136,7 @@ static const u32 wep_crc32_table[256] = {

/* keylen in bytes! */

int wep_change_key(wlandevice_t * wlandev, int keynum, u8 * key, int keylen)
int wep_change_key(wlandevice_t *wlandev, int keynum, u8 *key, int keylen)
{
if (keylen < 0)
return -1;
Expand Down Expand Up @@ -166,8 +166,8 @@ int wep_change_key(wlandevice_t * wlandev, int keynum, u8 * key, int keylen)
4-byte IV at start of buffer, 4-byte ICV at end of buffer.
if successful, buf start is payload begin, length -= 8;
*/
int wep_decrypt(wlandevice_t * wlandev, u8 * buf, u32 len, int key_override,
u8 * iv, u8 * icv)
int wep_decrypt(wlandevice_t *wlandev, u8 *buf, u32 len, int key_override,
u8 *iv, u8 *icv)
{
u32 i, j, k, crc, keylen;
u8 s[256], key[64], c_crc[4];
Expand Down Expand Up @@ -245,8 +245,8 @@ int wep_decrypt(wlandevice_t * wlandev, u8 * buf, u32 len, int key_override,
}

/* encrypts in-place. */
int wep_encrypt(wlandevice_t * wlandev, u8 * buf, u8 * dst, u32 len, int keynum,
u8 * iv, u8 * icv)
int wep_encrypt(wlandevice_t *wlandev, u8 *buf, u8 *dst, u32 len, int keynum,
u8 *iv, u8 *icv)
{
u32 i, j, k, crc, keylen;
u8 s[256], key[64];
Expand Down
Loading

0 comments on commit 297f06c

Please sign in to comment.