#define ORINOCO_INTEN          (HERMES_EV_RX | HERMES_EV_ALLOC \
                                 | HERMES_EV_TX | HERMES_EV_TXEXC \
                                 | HERMES_EV_WTERR | HERMES_EV_INFO \
-                                | HERMES_EV_INFDROP )
+                                | HERMES_EV_INFDROP)
 
 #define MAX_RID_LEN 1024
 
 
        err = __orinoco_up(dev);
 
-       if (! err)
+       if (!err)
                priv->open = 1;
 
        orinoco_unlock(priv, &flags);
        int err;
        unsigned long flags;
 
-       if (! netif_device_present(dev)) {
+       if (!netif_device_present(dev)) {
                printk(KERN_WARNING "%s: get_wireless_stats() called while device not present\n",
                       dev->name);
                return NULL; /* FIXME: Can we do better than this? */
 {
        struct orinoco_private *priv = netdev_priv(dev);
 
-       if ( (new_mtu < ORINOCO_MIN_MTU) || (new_mtu > ORINOCO_MAX_MTU) )
+       if ((new_mtu < ORINOCO_MIN_MTU) || (new_mtu > ORINOCO_MAX_MTU))
                return -EINVAL;
 
        /* MTU + encapsulation + header length */
-       if ( (new_mtu + ENCAPS_OVERHEAD + sizeof(struct ieee80211_hdr)) >
-            (priv->nicbuf_size - ETH_HLEN) )
+       if ((new_mtu + ENCAPS_OVERHEAD + sizeof(struct ieee80211_hdr)) >
+            (priv->nicbuf_size - ETH_HLEN))
                return -EINVAL;
 
        dev->mtu = new_mtu;
        int tx_control;
        unsigned long flags;
 
-       if (! netif_running(dev)) {
+       if (!netif_running(dev)) {
                printk(KERN_ERR "%s: Tx on stopped device!\n",
                       dev->name);
                return NETDEV_TX_BUSY;
                return NETDEV_TX_BUSY;
        }
 
-       if (! netif_carrier_ok(dev) || (priv->iw_mode == IW_MODE_MONITOR)) {
+       if (!netif_carrier_ok(dev) || (priv->iw_mode == IW_MODE_MONITOR)) {
                /* Oops, the firmware hasn't established a connection,
                   silently drop the packet (this seems to be the
                   safest approach). */
         * 00:00:f8 - we need both because different APs appear to use
         * different OUIs for some reason */
        return (memcmp(hdr, &encaps_hdr, 5) == 0)
-               && ( (hdr[5] == 0x00) || (hdr[5] == 0xf8) );
+               && ((hdr[5] == 0x00) || (hdr[5] == 0xf8));
 }
 
 static inline void orinoco_spy_gather(struct net_device *dev, u_char *mac,
 
        /* Allocate buffer for scan results */
        buf = kmalloc(MAX_SCAN_LEN, GFP_KERNEL);
-       if (! buf)
+       if (!buf)
                return;
 
        if (orinoco_lock(priv, &flags) != 0)
                goto fail_lock;
 
        /* Sanity checks in case user changed something in the meantime */
-       if (! priv->bssid_fixed)
+       if (!priv->bssid_fixed)
                goto out;
 
        if (strlen(priv->desired_essid) == 0)
                }
        }
 
-       if (! found) {
+       if (!found) {
                DEBUG(1, "%s: Requested AP not found in scan results\n",
                      dev->name);
                goto out;
                {
                        int     i;
                        printk(KERN_DEBUG "Scan result [%02X", buf[0]);
-                       for(i = 1; i < (len * 2); i++)
+                       for (i = 1; i < (len * 2); i++)
                                printk(":%02X", buf[i]);
                        printk("]\n");
                }
 
        netif_stop_queue(dev);
 
-       if (! priv->hw_unavailable) {
-               if (! priv->broken_disableport) {
+       if (!priv->hw_unavailable) {
+               if (!priv->broken_disableport) {
                        err = hermes_disable_port(hw, 0);
                        if (err) {
                                /* Some firmwares (e.g. Intersil 1.3.x) seem
                        }
 
                        /* Write all 4 keys */
-                       for(i = 0; i < ORINOCO_MAX_KEYS; i++) {
+                       for (i = 0; i < ORINOCO_MAX_KEYS; i++) {
                                err = hermes_write_ltv(hw, USER_BAP,
                                                       HERMES_RID_CNFDEFAULTKEY0 + i,
                                                       HERMES_BYTES_TO_RECLEN(keylen),
 
        /* The Hermes doesn't seem to have an allmulti mode, so we go
         * into promiscuous mode and let the upper levels deal. */
-       if ( (dev->flags & IFF_PROMISC) || (dev->flags & IFF_ALLMULTI) ||
-            (dev->mc_count > MAX_MULTICAST(priv)) ) {
+       if ((dev->flags & IFF_PROMISC) || (dev->flags & IFF_ALLMULTI) ||
+            (dev->mc_count > MAX_MULTICAST(priv))) {
                promisc = 1;
                mc_count = 0;
        } else {
        /* If we're not in promiscuous mode, then we need to set the
         * group address if either we want to multicast, or if we were
         * multicasting and want to stop */
-       if (! promisc && (mc_count || priv->mc_count) ) {
+       if (!promisc && (mc_count || priv->mc_count)) {
                struct dev_mc_list *p = dev->mc_list;
                struct hermes_multicast mclist;
                int i;
 
                for (i = 0; i < mc_count; i++) {
                        /* paranoia: is list shorter than mc_count? */
-                       BUG_ON(! p);
+                       BUG_ON(!p);
                        /* paranoia: bad address size in list? */
                        BUG_ON(p->dmi_addrlen != ETH_ALEN);
 
 
        /* priv->open or priv->hw_unavailable might have changed while
         * we dropped the lock */
-       if (priv->open && (! priv->hw_unavailable)) {
+       if (priv->open && (!priv->hw_unavailable)) {
                err = __orinoco_up(dev);
                if (err) {
                        printk(KERN_ERR "%s: orinoco_reset: Error %d reenabling card\n",
 
        evstat = hermes_read_regn(hw, EVSTAT);
        events = evstat & hw->inten;
-       if (! events) {
+       if (!events) {
                orinoco_unlock(priv, &flags);
                return IRQ_NONE;
        }
                }
 
                /* Check the card hasn't been removed */
-               if (! hermes_present(hw)) {
+               if (!hermes_present(hw)) {
                        DEBUG(0, "orinoco_interrupt(): card removed\n");
                        break;
                }
        /* Set up the default configuration */
        priv->iw_mode = IW_MODE_INFRA;
        /* By default use IEEE/IBSS ad-hoc mode if we have it */
-       priv->prefer_port3 = priv->has_port3 && (! priv->has_ibss);
+       priv->prefer_port3 = priv->has_port3 && (!priv->has_ibss);
        set_port_type(priv);
        priv->channel = 0; /* use firmware default */
 
                goto out;
        }
 
-       if ( (channel < 1) || (channel > NUM_CHANNELS) ) {
+       if ((channel < 1) || (channel > NUM_CHANNELS)) {
                printk(KERN_WARNING "%s: Channel out of range (%d)!\n",
                       priv->ndev->name, channel);
                err = -EBUSY;
        if (priv->has_wpa)
                range->enc_capa = IW_ENC_CAPA_WPA | IW_ENC_CAPA_CIPHER_TKIP;
 
-       if ((priv->iw_mode == IW_MODE_ADHOC) && (!SPY_NUMBER(priv))){
+       if ((priv->iw_mode == IW_MODE_ADHOC) && (!SPY_NUMBER(priv))) {
                /* Quality stats meaningless in ad-hoc mode */
        } else {
                range->max_qual.qual = 0x8b - 0x2f;
        int err = -EINPROGRESS;         /* Call commit handler */
        unsigned long flags;
 
-       if (! priv->has_wep)
+       if (!priv->has_wep)
                return -EOPNOTSUPP;
 
        if (erq->pointer) {
                if (erq->length > LARGE_KEY_SIZE)
                        return -E2BIG;
 
-               if ( (erq->length > SMALL_KEY_SIZE) && !priv->has_big_wep )
+               if ((erq->length > SMALL_KEY_SIZE) && !priv->has_big_wep)
                        return -E2BIG;
        }
 
                 * we will arrive there with an index of -1. This is valid
                 * but need to be taken care off... Jean II */
                if ((index < 0) || (index >= ORINOCO_MAX_KEYS)) {
-                       if((index != -1) || (erq->flags == 0)) {
+                       if ((index != -1) || (erq->flags == 0)) {
                                err = -EINVAL;
                                goto out;
                        }
                } else {
                        /* Set the index : Check that the key is valid */
-                       if(priv->keys[index].len == 0) {
+                       if (priv->keys[index].len == 0) {
                                err = -EINVAL;
                                goto out;
                        }
        u16 xlen = 0;
        unsigned long flags;
 
-       if (! priv->has_wep)
+       if (!priv->has_wep)
                return -EOPNOTSUPP;
 
        if (orinoco_lock(priv, &flags) != 0)
        if (priv->iw_mode == IW_MODE_INFRA)
                return -EBUSY;
 
-       if ( (frq->e == 0) && (frq->m <= 1000) ) {
+       if ((frq->e == 0) && (frq->m <= 1000)) {
                /* Setting by channel number */
                chan = frq->m;
        } else {
                chan = ieee80211_freq_to_dsss_chan(frq->m / denom);
        }
 
-       if ( (chan < 1) || (chan > NUM_CHANNELS) ||
-            ! (priv->channel_mask & (1 << (chan-1)) ) )
+       if ((chan < 1) || (chan > NUM_CHANNELS) ||
+            !(priv->channel_mask & (1 << (chan-1))))
                return -EINVAL;
 
        if (orinoco_lock(priv, &flags) != 0)
        if (rrq->disabled)
                val = 2347;
 
-       if ( (val < 0) || (val > 2347) )
+       if ((val < 0) || (val > 2347))
                return -EINVAL;
 
        if (orinoco_lock(priv, &flags) != 0)
                if (frq->disabled)
                        priv->frag_thresh = 2346;
                else {
-                       if ( (frq->value < 256) || (frq->value > 2346) )
+                       if ((frq->value < 256) || (frq->value > 2346))
                                err = -EINVAL;
                        else
                                priv->frag_thresh = frq->value & ~0x1; /* must be even */
                        val = 0;
 
                frq->value = val ? 2347 : 0;
-               frq->disabled = ! val;
+               frq->disabled = !val;
                frq->fixed = 0;
        } else {
                err = hermes_read_wordrec(hw, USER_BAP, HERMES_RID_CNFFRAGMENTATIONTHRESHOLD,
                bitrate = rrq->value / 100000;
        }
 
-       if ( (bitrate != 10) && (bitrate != 20) &&
-            (bitrate != 55) && (bitrate != 110) )
+       if ((bitrate != 10) && (bitrate != 20) &&
+           (bitrate != 55) && (bitrate != 110))
                return -EINVAL;
 
        for (i = 0; i < BITRATE_TABLE_SIZE; i++)
-               if ( (bitrate_table[i].bitrate == bitrate) &&
-                    (bitrate_table[i].automatic == ! rrq->fixed) ) {
+               if ((bitrate_table[i].bitrate == bitrate) &&
+                   (bitrate_table[i].automatic == !rrq->fixed)) {
                        ratemode = i;
                        break;
                }
        BUG_ON((ratemode < 0) || (ratemode >= BITRATE_TABLE_SIZE));
 
        rrq->value = bitrate_table[ratemode].bitrate * 100000;
-       rrq->fixed = ! bitrate_table[ratemode].automatic;
+       rrq->fixed = !bitrate_table[ratemode].automatic;
        rrq->disabled = 0;
 
        /* If the interface is running we try to find more about the
                }
                /* It's valid to not have a value if we are just toggling
                 * the flags... Jean II */
-               if(!priv->pm_on) {
+               if (!priv->pm_on) {
                        err = -EINVAL;
                        goto out;
                }
                } else {
                        rrq->flags = IW_RETRY_LIMIT;
                        rrq->value = short_limit;
-                       if(short_limit != long_limit)
+                       if (short_limit != long_limit)
                                rrq->flags |= IW_RETRY_SHORT;
                }
        }
 {
        struct orinoco_private *priv = netdev_priv(dev);
 
-       if (! capable(CAP_NET_ADMIN))
+       if (!capable(CAP_NET_ADMIN))
                return -EPERM;
 
        if (info->cmd == (SIOCIWFIRSTPRIV + 0x1)) {
 
 {
        struct orinoco_private *priv = netdev_priv(dev);
-       int val = *( (int *) extra );
+       int val = *((int *) extra);
        unsigned long flags;
 
        if (orinoco_lock(priv, &flags) != 0)
                                  char *extra)
 {
        struct orinoco_private *priv = netdev_priv(dev);
-       int val = *( (int *) extra );
+       int val = *((int *) extra);
        int err = 0;
        unsigned long flags;
 
 
        switch (val) {
        case 0: /* Try to do IEEE ad-hoc mode */
-               if (! priv->has_ibss) {
+               if (!priv->has_ibss) {
                        err = -EINVAL;
                        break;
                }
                break;
 
        case 1: /* Try to do Lucent proprietary ad-hoc mode */
-               if (! priv->has_port3) {
+               if (!priv->has_port3) {
                        err = -EINVAL;
                        break;
                }
                err = -EINVAL;
        }
 
-       if (! err) {
+       if (!err) {
                /* Actually update the mode we are using */
                set_port_type(priv);
                err = -EINPROGRESS;
        unsigned long flags;
        int val;
 
-       if (! priv->has_preamble)
+       if (!priv->has_preamble)
                return -EOPNOTSUPP;
 
        /* 802.11b has recently defined some short preamble.
         * This increase performance, especially at high rates
         * (the preamble is transmitted at 1Mb/s), unfortunately
         * this give compatibility troubles... - Jean II */
-       val = *( (int *) extra );
+       val = *((int *) extra);
 
        if (orinoco_lock(priv, &flags) != 0)
                return -EBUSY;
        struct orinoco_private *priv = netdev_priv(dev);
        int *val = (int *) extra;
 
-       if (! priv->has_preamble)
+       if (!priv->has_preamble)
                return -EOPNOTSUPP;
 
        *val = priv->preamble;
 
        /* It's a "get" function, but we don't want users to access the
         * WEP key and other raw firmware data */
-       if (! capable(CAP_NET_ADMIN))
+       if (!capable(CAP_NET_ADMIN))
                return -EPERM;
 
        if (rid < 0xfc00 || rid > 0xffff)
                err = hermes_inquire(hw, HERMES_INQ_SCAN);
 
        /* One more client */
-       if (! err)
+       if (!err)
                priv->scan_inprogress = 1;
 
  out: