Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
[linux-drm-fsl-dcu.git] / net / ieee80211 / softmac / ieee80211softmac_assoc.c
index e3f37fdda65f6d34cee54693640bad4b5543774f..cc8110bdd5799359e95be983db36ba1616b6dff1 100644 (file)
@@ -30,7 +30,7 @@
  * Overview
  *
  * Before you can associate, you have to authenticate.
- * 
+ *
  */
 
 /* Sends out an association request to the desired AP */
@@ -41,10 +41,10 @@ ieee80211softmac_assoc(struct ieee80211softmac_device *mac, struct ieee80211soft
 
        /* Switch to correct channel for this network */
        mac->set_channel(mac->dev, net->channel);
-       
+
        /* Send association request */
        ieee80211softmac_send_mgt_frame(mac, net, IEEE80211_STYPE_ASSOC_REQ, 0);
-       
+
        dprintk(KERN_INFO PFX "sent association request!\n");
 
        spin_lock_irqsave(&mac->lock, flags);
@@ -153,7 +153,7 @@ network_matches_request(struct ieee80211softmac_device *mac, struct ieee80211_ne
        }
 
        /* if 'ANY' network requested, take any that doesn't have privacy enabled */
-       if (mac->associnfo.req_essid.len == 0 
+       if (mac->associnfo.req_essid.len == 0
            && !(net->capability & WLAN_CAPABILITY_PRIVACY))
                return 1;
        if (net->ssid_len != mac->associnfo.req_essid.len)
@@ -167,7 +167,7 @@ static void
 ieee80211softmac_assoc_notify_scan(struct net_device *dev, int event_type, void *context)
 {
        struct ieee80211softmac_device *mac = ieee80211_priv(dev);
-       ieee80211softmac_assoc_work((void*)mac);
+       ieee80211softmac_assoc_work(&mac->associnfo.work.work);
 }
 
 static void
@@ -177,7 +177,7 @@ ieee80211softmac_assoc_notify_auth(struct net_device *dev, int event_type, void
 
        switch (event_type) {
        case IEEE80211SOFTMAC_EVENT_AUTHENTICATED:
-               ieee80211softmac_assoc_work((void*)mac);
+               ieee80211softmac_assoc_work(&mac->associnfo.work.work);
                break;
        case IEEE80211SOFTMAC_EVENT_AUTH_FAILED:
        case IEEE80211SOFTMAC_EVENT_AUTH_TIMEOUT:
@@ -212,8 +212,8 @@ ieee80211softmac_assoc_work(struct work_struct *work)
 
        /* try to find the requested network in our list, if we found one already */
        if (bssvalid || mac->associnfo.bssfixed)
-               found = ieee80211softmac_get_network_by_bssid(mac, mac->associnfo.bssid);       
-       
+               found = ieee80211softmac_get_network_by_bssid(mac, mac->associnfo.bssid);
+
        /* Search the ieee80211 networks for this network if we didn't find it by bssid,
         * but only if we've scanned at least once (to get a better list of networks to
         * select from). If we have not scanned before, the !found logic below will be
@@ -265,7 +265,7 @@ ieee80211softmac_assoc_work(struct work_struct *work)
                if (mac->associnfo.scan_retry > 0) {
                        mac->associnfo.scan_retry--;
 
-                       /* We know of no such network. Let's scan. 
+                       /* We know of no such network. Let's scan.
                         * NB: this also happens if we had no memory to copy the network info...
                         * Maybe we can hope to have more memory after scanning finishes ;)
                         */
@@ -353,7 +353,7 @@ ieee80211softmac_associated(struct ieee80211softmac_device *mac,
                mac->set_bssid_filter(mac->dev, net->bssid);
        memcpy(mac->ieee->bssid, net->bssid, ETH_ALEN);
        netif_carrier_on(mac->dev);
-       
+
        mac->association_id = le16_to_cpup(&resp->aid);
 }
 
@@ -374,7 +374,7 @@ ieee80211softmac_handle_assoc_response(struct net_device * dev,
 
        if (unlikely(!mac->running))
                return -ENODEV;
-       
+
        spin_lock_irqsave(&mac->lock, flags);
 
        if (!mac->associnfo.associating) {
@@ -426,7 +426,7 @@ ieee80211softmac_handle_assoc_response(struct net_device * dev,
                        mac->associnfo.associated = 0;
                        ieee80211softmac_call_events_locked(mac, IEEE80211SOFTMAC_EVENT_ASSOCIATE_FAILED, network);
        }
-       
+
        spin_unlock_irqrestore(&mac->lock, flags);
        return 0;
 }