Loading drivers/staging/wlan-ng/prism2sta.c +510 −503 Original line number Diff line number Diff line Loading @@ -130,7 +130,7 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, static void prism2sta_inf_psusercnt(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf); /*---------------------------------------------------------------- /* * prism2sta_open * * WLAN device open method. Called from p80211netdev when kernel Loading @@ -150,7 +150,7 @@ static void prism2sta_inf_psusercnt(wlandevice_t *wlandev, * * Call context: * process thread ----------------------------------------------------------------*/ */ static int prism2sta_open(wlandevice_t *wlandev) { /* We don't currently have to do anything else. Loading @@ -164,7 +164,7 @@ static int prism2sta_open(wlandevice_t *wlandev) return 0; } /*---------------------------------------------------------------- /* * prism2sta_close * * WLAN device close method. Called from p80211netdev when kernel Loading @@ -184,7 +184,7 @@ static int prism2sta_open(wlandevice_t *wlandev) * * Call context: * process thread ----------------------------------------------------------------*/ */ static int prism2sta_close(wlandevice_t *wlandev) { /* We don't currently have to do anything else. Loading @@ -196,7 +196,7 @@ static int prism2sta_close(wlandevice_t *wlandev) return 0; } /*---------------------------------------------------------------- /* * prism2sta_reset * * Currently not implemented. Loading @@ -212,12 +212,12 @@ static int prism2sta_close(wlandevice_t *wlandev) * * Call context: * process thread ----------------------------------------------------------------*/ */ static void prism2sta_reset(wlandevice_t *wlandev) { } /*---------------------------------------------------------------- /* * prism2sta_txframe * * Takes a frame from p80211 and queues it for transmission. Loading @@ -237,7 +237,7 @@ static void prism2sta_reset(wlandevice_t *wlandev) * * Call context: * process thread ----------------------------------------------------------------*/ */ static int prism2sta_txframe(wlandevice_t *wlandev, struct sk_buff *skb, union p80211_hdr *p80211_hdr, struct p80211_metawep *p80211_wep) Loading @@ -253,7 +253,7 @@ static int prism2sta_txframe(wlandevice_t *wlandev, struct sk_buff *skb, return hfa384x_drvr_txframe(hw, skb, p80211_hdr, p80211_wep); } /*---------------------------------------------------------------- /* * prism2sta_mlmerequest * * wlan command message handler. All we do here is pass the message Loading @@ -276,7 +276,7 @@ static int prism2sta_txframe(wlandevice_t *wlandev, struct sk_buff *skb, * * Call context: * process thread ----------------------------------------------------------------*/ */ static int prism2sta_mlmerequest(wlandevice_t *wlandev, struct p80211msg *msg) { hfa384x_t *hw = (hfa384x_t *) wlandev->priv; Loading Loading @@ -386,7 +386,7 @@ static int prism2sta_mlmerequest(wlandevice_t *wlandev, struct p80211msg *msg) return result; } /*---------------------------------------------------------------- /* * prism2sta_ifstate * * Interface state. This is the primary WLAN interface enable/disable Loading @@ -406,7 +406,7 @@ static int prism2sta_mlmerequest(wlandevice_t *wlandev, struct p80211msg *msg) * Call context: * process thread (usually) * interrupt ----------------------------------------------------------------*/ */ u32 prism2sta_ifstate(wlandevice_t *wlandev, u32 ifstate) { hfa384x_t *hw = (hfa384x_t *) wlandev->priv; Loading Loading @@ -561,7 +561,7 @@ u32 prism2sta_ifstate(wlandevice_t *wlandev, u32 ifstate) return result; } /*---------------------------------------------------------------- /* * prism2sta_getcardinfo * * Collect the NICID, firmware version and any other identifiers Loading @@ -579,7 +579,7 @@ u32 prism2sta_ifstate(wlandevice_t *wlandev, u32 ifstate) * * Call context: * Either. ----------------------------------------------------------------*/ */ static int prism2sta_getcardinfo(wlandevice_t *wlandev) { int result = 0; Loading Loading @@ -677,7 +677,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, modem interface supplier fields in byte order */ * fields in byte order */ hw->cap_sup_mfi.role = le16_to_cpu(hw->cap_sup_mfi.role); hw->cap_sup_mfi.id = le16_to_cpu(hw->cap_sup_mfi.id); hw->cap_sup_mfi.variant = le16_to_cpu(hw->cap_sup_mfi.variant); Loading @@ -700,7 +701,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, controller interface supplier fields in byte order */ * fields in byte order */ hw->cap_sup_cfi.role = le16_to_cpu(hw->cap_sup_cfi.role); hw->cap_sup_cfi.id = le16_to_cpu(hw->cap_sup_cfi.id); hw->cap_sup_cfi.variant = le16_to_cpu(hw->cap_sup_cfi.variant); Loading @@ -723,7 +725,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, primary firmware supplier fields in byte order */ * fields in byte order */ hw->cap_sup_pri.role = le16_to_cpu(hw->cap_sup_pri.role); hw->cap_sup_pri.id = le16_to_cpu(hw->cap_sup_pri.id); hw->cap_sup_pri.variant = le16_to_cpu(hw->cap_sup_pri.variant); Loading @@ -746,7 +749,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, station firmware supplier fields in byte order */ * fields in byte order */ hw->cap_sup_sta.role = le16_to_cpu(hw->cap_sup_sta.role); hw->cap_sup_sta.id = le16_to_cpu(hw->cap_sup_sta.id); hw->cap_sup_sta.variant = le16_to_cpu(hw->cap_sup_sta.variant); Loading Loading @@ -777,7 +781,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, primary f/w actor, CFI supplier fields in byte order */ * fields in byte order */ hw->cap_act_pri_cfi.role = le16_to_cpu(hw->cap_act_pri_cfi.role); hw->cap_act_pri_cfi.id = le16_to_cpu(hw->cap_act_pri_cfi.id); hw->cap_act_pri_cfi.variant = le16_to_cpu(hw->cap_act_pri_cfi.variant); Loading @@ -800,7 +805,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, station f/w actor, CFI supplier fields in byte order */ * fields in byte order */ hw->cap_act_sta_cfi.role = le16_to_cpu(hw->cap_act_sta_cfi.role); hw->cap_act_sta_cfi.id = le16_to_cpu(hw->cap_act_sta_cfi.id); hw->cap_act_sta_cfi.variant = le16_to_cpu(hw->cap_act_sta_cfi.variant); Loading @@ -823,7 +829,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, station f/w actor, MFI supplier fields in byte order */ * fields in byte order */ hw->cap_act_sta_mfi.role = le16_to_cpu(hw->cap_act_sta_mfi.role); hw->cap_act_sta_mfi.id = le16_to_cpu(hw->cap_act_sta_mfi.id); hw->cap_act_sta_mfi.variant = le16_to_cpu(hw->cap_act_sta_mfi.variant); Loading Loading @@ -884,7 +891,7 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) return result; } /*---------------------------------------------------------------- /* * prism2sta_globalsetup * * Set any global RIDs that we want to set at device activation. Loading @@ -901,7 +908,7 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) * * Call context: * process thread ----------------------------------------------------------------*/ */ static int prism2sta_globalsetup(wlandevice_t *wlandev) { hfa384x_t *hw = (hfa384x_t *) wlandev->priv; Loading Loading @@ -934,7 +941,7 @@ static int prism2sta_setmulticast(wlandevice_t *wlandev, netdevice_t *dev) return result; } /*---------------------------------------------------------------- /* * prism2sta_inf_handover * * Handles the receipt of a Handover info frame. Should only be present Loading @@ -951,14 +958,14 @@ static int prism2sta_setmulticast(wlandevice_t *wlandev, netdevice_t *dev) * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_handover(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { pr_debug("received infoframe:HANDOVER (unhandled)\n"); } /*---------------------------------------------------------------- /* * prism2sta_inf_tallies * * Handles the receipt of a CommTallies info frame. Loading @@ -974,7 +981,7 @@ static void prism2sta_inf_handover(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_tallies(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading @@ -986,8 +993,8 @@ static void prism2sta_inf_tallies(wlandevice_t *wlandev, int cnt; /* ** Determine if these are 16-bit or 32-bit tallies, based on the ** record length of the info record. * Determine if these are 16-bit or 32-bit tallies, based on the * record length of the info record. */ cnt = sizeof(hfa384x_CommTallies32_t) / sizeof(u32); Loading @@ -1004,7 +1011,7 @@ static void prism2sta_inf_tallies(wlandevice_t *wlandev, } } /*---------------------------------------------------------------- /* * prism2sta_inf_scanresults * * Handles the receipt of a Scan Results info frame. Loading @@ -1020,7 +1027,7 @@ static void prism2sta_inf_tallies(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_scanresults(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading Loading @@ -1060,7 +1067,7 @@ static void prism2sta_inf_scanresults(wlandevice_t *wlandev, } } /*---------------------------------------------------------------- /* * prism2sta_inf_hostscanresults * * Handles the receipt of a Scan Results info frame. Loading @@ -1076,7 +1083,7 @@ static void prism2sta_inf_scanresults(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_hostscanresults(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading @@ -1101,7 +1108,7 @@ static void prism2sta_inf_hostscanresults(wlandevice_t *wlandev, wake_up_interruptible(&hw->cmdq); }; /*---------------------------------------------------------------- /* * prism2sta_inf_chinforesults * * Handles the receipt of a Channel Info Results info frame. Loading @@ -1117,7 +1124,7 @@ static void prism2sta_inf_hostscanresults(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_chinforesults(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading Loading @@ -1414,7 +1421,7 @@ void prism2sta_processing_defer(struct work_struct *data) wlandev->linkstatus = (hw->link_status == HFA384x_LINK_CONNECTED); } /*---------------------------------------------------------------- /* * prism2sta_inf_linkstatus * * Handles the receipt of a Link Status info frame. Loading @@ -1430,7 +1437,7 @@ void prism2sta_processing_defer(struct work_struct *data) * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_linkstatus(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading @@ -1441,7 +1448,7 @@ static void prism2sta_inf_linkstatus(wlandevice_t *wlandev, schedule_work(&hw->link_bh); } /*---------------------------------------------------------------- /* * prism2sta_inf_assocstatus * * Handles the receipt of an Association Status info frame. Should Loading @@ -1458,7 +1465,7 @@ static void prism2sta_inf_linkstatus(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_assocstatus(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading @@ -1471,15 +1478,15 @@ static void prism2sta_inf_assocstatus(wlandevice_t *wlandev, rec.reason = le16_to_cpu(rec.reason); /* ** Find the address in the list of authenticated stations. ** If it wasn't found, then this address has not been previously ** authenticated and something weird has happened if this is ** anything other than an "authentication failed" message. ** If the address was found, then set the "associated" flag for ** that station, based on whether the station is associating or ** losing its association. Something weird has also happened ** if we find the address in the list of authenticated stations ** but we are getting an "authentication failed" message. * Find the address in the list of authenticated stations. * If it wasn't found, then this address has not been previously * authenticated and something weird has happened if this is * anything other than an "authentication failed" message. * If the address was found, then set the "associated" flag for * that station, based on whether the station is associating or * losing its association. Something weird has also happened * if we find the address in the list of authenticated stations * but we are getting an "authentication failed" message. */ for (i = 0; i < hw->authlist.cnt; i++) Loading @@ -1501,7 +1508,7 @@ static void prism2sta_inf_assocstatus(wlandevice_t *wlandev, } } /*---------------------------------------------------------------- /* * prism2sta_inf_authreq * * Handles the receipt of an Authentication Request info frame. Should Loading @@ -1519,7 +1526,7 @@ static void prism2sta_inf_assocstatus(wlandevice_t *wlandev, * Call context: * interrupt * ----------------------------------------------------------------*/ */ static void prism2sta_inf_authreq(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading @@ -1545,23 +1552,23 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, u8 *addr; /* ** Build the AuthenticateStation record. Initialize it for denying ** authentication. * Build the AuthenticateStation record. Initialize it for denying * authentication. */ ether_addr_copy(rec.address, inf->info.authreq.sta_addr); rec.status = P80211ENUM_status_unspec_failure; /* ** Authenticate based on the access mode. * Authenticate based on the access mode. */ switch (hw->accessmode) { case WLAN_ACCESS_NONE: /* ** Deny all new authentications. However, if a station ** is ALREADY authenticated, then accept it. * Deny all new authentications. However, if a station * is ALREADY authenticated, then accept it. */ for (i = 0; i < hw->authlist.cnt; i++) Loading @@ -1576,7 +1583,7 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, case WLAN_ACCESS_ALL: /* ** Allow all authentications. * Allow all authentications. */ rec.status = P80211ENUM_status_successful; Loading @@ -1585,13 +1592,13 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, case WLAN_ACCESS_ALLOW: /* ** Only allow the authentication if the MAC address ** is in the list of allowed addresses. ** ** Since this is the interrupt handler, we may be here ** while the access list is in the middle of being ** updated. Choose the list which is currently okay. ** See "prism2mib_priv_accessallow()" for details. * Only allow the authentication if the MAC address * is in the list of allowed addresses. * * Since this is the interrupt handler, we may be here * while the access list is in the middle of being * updated. Choose the list which is currently okay. * See "prism2mib_priv_accessallow()" for details. */ if (hw->allow.modify == 0) { Loading @@ -1613,13 +1620,13 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, case WLAN_ACCESS_DENY: /* ** Allow the authentication UNLESS the MAC address is ** in the list of denied addresses. ** ** Since this is the interrupt handler, we may be here ** while the access list is in the middle of being ** updated. Choose the list which is currently okay. ** See "prism2mib_priv_accessdeny()" for details. * Allow the authentication UNLESS the MAC address is * in the list of denied addresses. * * Since this is the interrupt handler, we may be here * while the access list is in the middle of being * updated. Choose the list which is currently okay. * See "prism2mib_priv_accessdeny()" for details. */ if (hw->deny.modify == 0) { Loading @@ -1642,12 +1649,12 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, } /* ** If the authentication is okay, then add the MAC address to the ** list of authenticated stations. Don't add the address if it ** is already in the list. (802.11b does not seem to disallow ** a station from issuing an authentication request when the ** station is already authenticated. Does this sort of thing ** ever happen? We might as well do the check just in case.) * If the authentication is okay, then add the MAC address to the * list of authenticated stations. Don't add the address if it * is already in the list. (802.11b does not seem to disallow * a station from issuing an authentication request when the * station is already authenticated. Does this sort of thing * ever happen? We might as well do the check just in case.) */ added = 0; Loading @@ -1672,9 +1679,9 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, } /* ** Send back the results of the authentication. If this doesn't work, ** then make sure to remove the address from the authenticated list if ** it was added. * Send back the results of the authentication. If this doesn't work, * then make sure to remove the address from the authenticated list if * it was added. */ rec.status = cpu_to_le16(rec.status); Loading @@ -1691,7 +1698,7 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, } } /*---------------------------------------------------------------- /* * prism2sta_inf_psusercnt * * Handles the receipt of a PowerSaveUserCount info frame. Should Loading @@ -1708,7 +1715,7 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_psusercnt(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading @@ -1717,7 +1724,7 @@ static void prism2sta_inf_psusercnt(wlandevice_t *wlandev, hw->psusercount = le16_to_cpu(inf->info.psusercnt.usercnt); } /*---------------------------------------------------------------- /* * prism2sta_ev_info * * Handles the Info event. Loading @@ -1733,7 +1740,7 @@ static void prism2sta_inf_psusercnt(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ void prism2sta_ev_info(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { inf->infotype = le16_to_cpu(inf->infotype); Loading Loading @@ -1782,7 +1789,7 @@ void prism2sta_ev_info(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) } } /*---------------------------------------------------------------- /* * prism2sta_ev_txexc * * Handles the TxExc event. A Transmit Exception event indicates Loading @@ -1800,13 +1807,13 @@ void prism2sta_ev_info(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) * * Call context: * interrupt ----------------------------------------------------------------*/ */ void prism2sta_ev_txexc(wlandevice_t *wlandev, u16 status) { pr_debug("TxExc status=0x%x.\n", status); } /*---------------------------------------------------------------- /* * prism2sta_ev_tx * * Handles the Tx event. Loading @@ -1821,7 +1828,7 @@ void prism2sta_ev_txexc(wlandevice_t *wlandev, u16 status) * * Call context: * interrupt ----------------------------------------------------------------*/ */ void prism2sta_ev_tx(wlandevice_t *wlandev, u16 status) { pr_debug("Tx Complete, status=0x%04x\n", status); Loading @@ -1829,7 +1836,7 @@ void prism2sta_ev_tx(wlandevice_t *wlandev, u16 status) wlandev->netdev->stats.tx_packets++; } /*---------------------------------------------------------------- /* * prism2sta_ev_rx * * Handles the Rx event. Loading @@ -1844,13 +1851,13 @@ void prism2sta_ev_tx(wlandevice_t *wlandev, u16 status) * * Call context: * interrupt ----------------------------------------------------------------*/ */ void prism2sta_ev_rx(wlandevice_t *wlandev, struct sk_buff *skb) { p80211netdev_rx(wlandev, skb); } /*---------------------------------------------------------------- /* * prism2sta_ev_alloc * * Handles the Alloc event. Loading @@ -1865,13 +1872,13 @@ void prism2sta_ev_rx(wlandevice_t *wlandev, struct sk_buff *skb) * * Call context: * interrupt ----------------------------------------------------------------*/ */ void prism2sta_ev_alloc(wlandevice_t *wlandev) { netif_wake_queue(wlandev->netdev); } /*---------------------------------------------------------------- /* * create_wlan * * Called at module init time. This creates the wlandevice_t structure Loading @@ -1889,7 +1896,7 @@ void prism2sta_ev_alloc(wlandevice_t *wlandev) * Call context: * process thread * ----------------------------------------------------------------*/ */ static wlandevice_t *create_wlan(void) { wlandevice_t *wlandev = NULL; Loading Loading
drivers/staging/wlan-ng/prism2sta.c +510 −503 Original line number Diff line number Diff line Loading @@ -130,7 +130,7 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, static void prism2sta_inf_psusercnt(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf); /*---------------------------------------------------------------- /* * prism2sta_open * * WLAN device open method. Called from p80211netdev when kernel Loading @@ -150,7 +150,7 @@ static void prism2sta_inf_psusercnt(wlandevice_t *wlandev, * * Call context: * process thread ----------------------------------------------------------------*/ */ static int prism2sta_open(wlandevice_t *wlandev) { /* We don't currently have to do anything else. Loading @@ -164,7 +164,7 @@ static int prism2sta_open(wlandevice_t *wlandev) return 0; } /*---------------------------------------------------------------- /* * prism2sta_close * * WLAN device close method. Called from p80211netdev when kernel Loading @@ -184,7 +184,7 @@ static int prism2sta_open(wlandevice_t *wlandev) * * Call context: * process thread ----------------------------------------------------------------*/ */ static int prism2sta_close(wlandevice_t *wlandev) { /* We don't currently have to do anything else. Loading @@ -196,7 +196,7 @@ static int prism2sta_close(wlandevice_t *wlandev) return 0; } /*---------------------------------------------------------------- /* * prism2sta_reset * * Currently not implemented. Loading @@ -212,12 +212,12 @@ static int prism2sta_close(wlandevice_t *wlandev) * * Call context: * process thread ----------------------------------------------------------------*/ */ static void prism2sta_reset(wlandevice_t *wlandev) { } /*---------------------------------------------------------------- /* * prism2sta_txframe * * Takes a frame from p80211 and queues it for transmission. Loading @@ -237,7 +237,7 @@ static void prism2sta_reset(wlandevice_t *wlandev) * * Call context: * process thread ----------------------------------------------------------------*/ */ static int prism2sta_txframe(wlandevice_t *wlandev, struct sk_buff *skb, union p80211_hdr *p80211_hdr, struct p80211_metawep *p80211_wep) Loading @@ -253,7 +253,7 @@ static int prism2sta_txframe(wlandevice_t *wlandev, struct sk_buff *skb, return hfa384x_drvr_txframe(hw, skb, p80211_hdr, p80211_wep); } /*---------------------------------------------------------------- /* * prism2sta_mlmerequest * * wlan command message handler. All we do here is pass the message Loading @@ -276,7 +276,7 @@ static int prism2sta_txframe(wlandevice_t *wlandev, struct sk_buff *skb, * * Call context: * process thread ----------------------------------------------------------------*/ */ static int prism2sta_mlmerequest(wlandevice_t *wlandev, struct p80211msg *msg) { hfa384x_t *hw = (hfa384x_t *) wlandev->priv; Loading Loading @@ -386,7 +386,7 @@ static int prism2sta_mlmerequest(wlandevice_t *wlandev, struct p80211msg *msg) return result; } /*---------------------------------------------------------------- /* * prism2sta_ifstate * * Interface state. This is the primary WLAN interface enable/disable Loading @@ -406,7 +406,7 @@ static int prism2sta_mlmerequest(wlandevice_t *wlandev, struct p80211msg *msg) * Call context: * process thread (usually) * interrupt ----------------------------------------------------------------*/ */ u32 prism2sta_ifstate(wlandevice_t *wlandev, u32 ifstate) { hfa384x_t *hw = (hfa384x_t *) wlandev->priv; Loading Loading @@ -561,7 +561,7 @@ u32 prism2sta_ifstate(wlandevice_t *wlandev, u32 ifstate) return result; } /*---------------------------------------------------------------- /* * prism2sta_getcardinfo * * Collect the NICID, firmware version and any other identifiers Loading @@ -579,7 +579,7 @@ u32 prism2sta_ifstate(wlandevice_t *wlandev, u32 ifstate) * * Call context: * Either. ----------------------------------------------------------------*/ */ static int prism2sta_getcardinfo(wlandevice_t *wlandev) { int result = 0; Loading Loading @@ -677,7 +677,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, modem interface supplier fields in byte order */ * fields in byte order */ hw->cap_sup_mfi.role = le16_to_cpu(hw->cap_sup_mfi.role); hw->cap_sup_mfi.id = le16_to_cpu(hw->cap_sup_mfi.id); hw->cap_sup_mfi.variant = le16_to_cpu(hw->cap_sup_mfi.variant); Loading @@ -700,7 +701,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, controller interface supplier fields in byte order */ * fields in byte order */ hw->cap_sup_cfi.role = le16_to_cpu(hw->cap_sup_cfi.role); hw->cap_sup_cfi.id = le16_to_cpu(hw->cap_sup_cfi.id); hw->cap_sup_cfi.variant = le16_to_cpu(hw->cap_sup_cfi.variant); Loading @@ -723,7 +725,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, primary firmware supplier fields in byte order */ * fields in byte order */ hw->cap_sup_pri.role = le16_to_cpu(hw->cap_sup_pri.role); hw->cap_sup_pri.id = le16_to_cpu(hw->cap_sup_pri.id); hw->cap_sup_pri.variant = le16_to_cpu(hw->cap_sup_pri.variant); Loading @@ -746,7 +749,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, station firmware supplier fields in byte order */ * fields in byte order */ hw->cap_sup_sta.role = le16_to_cpu(hw->cap_sup_sta.role); hw->cap_sup_sta.id = le16_to_cpu(hw->cap_sup_sta.id); hw->cap_sup_sta.variant = le16_to_cpu(hw->cap_sup_sta.variant); Loading Loading @@ -777,7 +781,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, primary f/w actor, CFI supplier fields in byte order */ * fields in byte order */ hw->cap_act_pri_cfi.role = le16_to_cpu(hw->cap_act_pri_cfi.role); hw->cap_act_pri_cfi.id = le16_to_cpu(hw->cap_act_pri_cfi.id); hw->cap_act_pri_cfi.variant = le16_to_cpu(hw->cap_act_pri_cfi.variant); Loading @@ -800,7 +805,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, station f/w actor, CFI supplier fields in byte order */ * fields in byte order */ hw->cap_act_sta_cfi.role = le16_to_cpu(hw->cap_act_sta_cfi.role); hw->cap_act_sta_cfi.id = le16_to_cpu(hw->cap_act_sta_cfi.id); hw->cap_act_sta_cfi.variant = le16_to_cpu(hw->cap_act_sta_cfi.variant); Loading @@ -823,7 +829,8 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) } /* get all the Compatibility range, station f/w actor, MFI supplier fields in byte order */ * fields in byte order */ hw->cap_act_sta_mfi.role = le16_to_cpu(hw->cap_act_sta_mfi.role); hw->cap_act_sta_mfi.id = le16_to_cpu(hw->cap_act_sta_mfi.id); hw->cap_act_sta_mfi.variant = le16_to_cpu(hw->cap_act_sta_mfi.variant); Loading Loading @@ -884,7 +891,7 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) return result; } /*---------------------------------------------------------------- /* * prism2sta_globalsetup * * Set any global RIDs that we want to set at device activation. Loading @@ -901,7 +908,7 @@ static int prism2sta_getcardinfo(wlandevice_t *wlandev) * * Call context: * process thread ----------------------------------------------------------------*/ */ static int prism2sta_globalsetup(wlandevice_t *wlandev) { hfa384x_t *hw = (hfa384x_t *) wlandev->priv; Loading Loading @@ -934,7 +941,7 @@ static int prism2sta_setmulticast(wlandevice_t *wlandev, netdevice_t *dev) return result; } /*---------------------------------------------------------------- /* * prism2sta_inf_handover * * Handles the receipt of a Handover info frame. Should only be present Loading @@ -951,14 +958,14 @@ static int prism2sta_setmulticast(wlandevice_t *wlandev, netdevice_t *dev) * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_handover(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { pr_debug("received infoframe:HANDOVER (unhandled)\n"); } /*---------------------------------------------------------------- /* * prism2sta_inf_tallies * * Handles the receipt of a CommTallies info frame. Loading @@ -974,7 +981,7 @@ static void prism2sta_inf_handover(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_tallies(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading @@ -986,8 +993,8 @@ static void prism2sta_inf_tallies(wlandevice_t *wlandev, int cnt; /* ** Determine if these are 16-bit or 32-bit tallies, based on the ** record length of the info record. * Determine if these are 16-bit or 32-bit tallies, based on the * record length of the info record. */ cnt = sizeof(hfa384x_CommTallies32_t) / sizeof(u32); Loading @@ -1004,7 +1011,7 @@ static void prism2sta_inf_tallies(wlandevice_t *wlandev, } } /*---------------------------------------------------------------- /* * prism2sta_inf_scanresults * * Handles the receipt of a Scan Results info frame. Loading @@ -1020,7 +1027,7 @@ static void prism2sta_inf_tallies(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_scanresults(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading Loading @@ -1060,7 +1067,7 @@ static void prism2sta_inf_scanresults(wlandevice_t *wlandev, } } /*---------------------------------------------------------------- /* * prism2sta_inf_hostscanresults * * Handles the receipt of a Scan Results info frame. Loading @@ -1076,7 +1083,7 @@ static void prism2sta_inf_scanresults(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_hostscanresults(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading @@ -1101,7 +1108,7 @@ static void prism2sta_inf_hostscanresults(wlandevice_t *wlandev, wake_up_interruptible(&hw->cmdq); }; /*---------------------------------------------------------------- /* * prism2sta_inf_chinforesults * * Handles the receipt of a Channel Info Results info frame. Loading @@ -1117,7 +1124,7 @@ static void prism2sta_inf_hostscanresults(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_chinforesults(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading Loading @@ -1414,7 +1421,7 @@ void prism2sta_processing_defer(struct work_struct *data) wlandev->linkstatus = (hw->link_status == HFA384x_LINK_CONNECTED); } /*---------------------------------------------------------------- /* * prism2sta_inf_linkstatus * * Handles the receipt of a Link Status info frame. Loading @@ -1430,7 +1437,7 @@ void prism2sta_processing_defer(struct work_struct *data) * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_linkstatus(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading @@ -1441,7 +1448,7 @@ static void prism2sta_inf_linkstatus(wlandevice_t *wlandev, schedule_work(&hw->link_bh); } /*---------------------------------------------------------------- /* * prism2sta_inf_assocstatus * * Handles the receipt of an Association Status info frame. Should Loading @@ -1458,7 +1465,7 @@ static void prism2sta_inf_linkstatus(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_assocstatus(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading @@ -1471,15 +1478,15 @@ static void prism2sta_inf_assocstatus(wlandevice_t *wlandev, rec.reason = le16_to_cpu(rec.reason); /* ** Find the address in the list of authenticated stations. ** If it wasn't found, then this address has not been previously ** authenticated and something weird has happened if this is ** anything other than an "authentication failed" message. ** If the address was found, then set the "associated" flag for ** that station, based on whether the station is associating or ** losing its association. Something weird has also happened ** if we find the address in the list of authenticated stations ** but we are getting an "authentication failed" message. * Find the address in the list of authenticated stations. * If it wasn't found, then this address has not been previously * authenticated and something weird has happened if this is * anything other than an "authentication failed" message. * If the address was found, then set the "associated" flag for * that station, based on whether the station is associating or * losing its association. Something weird has also happened * if we find the address in the list of authenticated stations * but we are getting an "authentication failed" message. */ for (i = 0; i < hw->authlist.cnt; i++) Loading @@ -1501,7 +1508,7 @@ static void prism2sta_inf_assocstatus(wlandevice_t *wlandev, } } /*---------------------------------------------------------------- /* * prism2sta_inf_authreq * * Handles the receipt of an Authentication Request info frame. Should Loading @@ -1519,7 +1526,7 @@ static void prism2sta_inf_assocstatus(wlandevice_t *wlandev, * Call context: * interrupt * ----------------------------------------------------------------*/ */ static void prism2sta_inf_authreq(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading @@ -1545,23 +1552,23 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, u8 *addr; /* ** Build the AuthenticateStation record. Initialize it for denying ** authentication. * Build the AuthenticateStation record. Initialize it for denying * authentication. */ ether_addr_copy(rec.address, inf->info.authreq.sta_addr); rec.status = P80211ENUM_status_unspec_failure; /* ** Authenticate based on the access mode. * Authenticate based on the access mode. */ switch (hw->accessmode) { case WLAN_ACCESS_NONE: /* ** Deny all new authentications. However, if a station ** is ALREADY authenticated, then accept it. * Deny all new authentications. However, if a station * is ALREADY authenticated, then accept it. */ for (i = 0; i < hw->authlist.cnt; i++) Loading @@ -1576,7 +1583,7 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, case WLAN_ACCESS_ALL: /* ** Allow all authentications. * Allow all authentications. */ rec.status = P80211ENUM_status_successful; Loading @@ -1585,13 +1592,13 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, case WLAN_ACCESS_ALLOW: /* ** Only allow the authentication if the MAC address ** is in the list of allowed addresses. ** ** Since this is the interrupt handler, we may be here ** while the access list is in the middle of being ** updated. Choose the list which is currently okay. ** See "prism2mib_priv_accessallow()" for details. * Only allow the authentication if the MAC address * is in the list of allowed addresses. * * Since this is the interrupt handler, we may be here * while the access list is in the middle of being * updated. Choose the list which is currently okay. * See "prism2mib_priv_accessallow()" for details. */ if (hw->allow.modify == 0) { Loading @@ -1613,13 +1620,13 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, case WLAN_ACCESS_DENY: /* ** Allow the authentication UNLESS the MAC address is ** in the list of denied addresses. ** ** Since this is the interrupt handler, we may be here ** while the access list is in the middle of being ** updated. Choose the list which is currently okay. ** See "prism2mib_priv_accessdeny()" for details. * Allow the authentication UNLESS the MAC address is * in the list of denied addresses. * * Since this is the interrupt handler, we may be here * while the access list is in the middle of being * updated. Choose the list which is currently okay. * See "prism2mib_priv_accessdeny()" for details. */ if (hw->deny.modify == 0) { Loading @@ -1642,12 +1649,12 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, } /* ** If the authentication is okay, then add the MAC address to the ** list of authenticated stations. Don't add the address if it ** is already in the list. (802.11b does not seem to disallow ** a station from issuing an authentication request when the ** station is already authenticated. Does this sort of thing ** ever happen? We might as well do the check just in case.) * If the authentication is okay, then add the MAC address to the * list of authenticated stations. Don't add the address if it * is already in the list. (802.11b does not seem to disallow * a station from issuing an authentication request when the * station is already authenticated. Does this sort of thing * ever happen? We might as well do the check just in case.) */ added = 0; Loading @@ -1672,9 +1679,9 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, } /* ** Send back the results of the authentication. If this doesn't work, ** then make sure to remove the address from the authenticated list if ** it was added. * Send back the results of the authentication. If this doesn't work, * then make sure to remove the address from the authenticated list if * it was added. */ rec.status = cpu_to_le16(rec.status); Loading @@ -1691,7 +1698,7 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, } } /*---------------------------------------------------------------- /* * prism2sta_inf_psusercnt * * Handles the receipt of a PowerSaveUserCount info frame. Should Loading @@ -1708,7 +1715,7 @@ static void prism2sta_inf_authreq_defer(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ static void prism2sta_inf_psusercnt(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { Loading @@ -1717,7 +1724,7 @@ static void prism2sta_inf_psusercnt(wlandevice_t *wlandev, hw->psusercount = le16_to_cpu(inf->info.psusercnt.usercnt); } /*---------------------------------------------------------------- /* * prism2sta_ev_info * * Handles the Info event. Loading @@ -1733,7 +1740,7 @@ static void prism2sta_inf_psusercnt(wlandevice_t *wlandev, * * Call context: * interrupt ----------------------------------------------------------------*/ */ void prism2sta_ev_info(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) { inf->infotype = le16_to_cpu(inf->infotype); Loading Loading @@ -1782,7 +1789,7 @@ void prism2sta_ev_info(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) } } /*---------------------------------------------------------------- /* * prism2sta_ev_txexc * * Handles the TxExc event. A Transmit Exception event indicates Loading @@ -1800,13 +1807,13 @@ void prism2sta_ev_info(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf) * * Call context: * interrupt ----------------------------------------------------------------*/ */ void prism2sta_ev_txexc(wlandevice_t *wlandev, u16 status) { pr_debug("TxExc status=0x%x.\n", status); } /*---------------------------------------------------------------- /* * prism2sta_ev_tx * * Handles the Tx event. Loading @@ -1821,7 +1828,7 @@ void prism2sta_ev_txexc(wlandevice_t *wlandev, u16 status) * * Call context: * interrupt ----------------------------------------------------------------*/ */ void prism2sta_ev_tx(wlandevice_t *wlandev, u16 status) { pr_debug("Tx Complete, status=0x%04x\n", status); Loading @@ -1829,7 +1836,7 @@ void prism2sta_ev_tx(wlandevice_t *wlandev, u16 status) wlandev->netdev->stats.tx_packets++; } /*---------------------------------------------------------------- /* * prism2sta_ev_rx * * Handles the Rx event. Loading @@ -1844,13 +1851,13 @@ void prism2sta_ev_tx(wlandevice_t *wlandev, u16 status) * * Call context: * interrupt ----------------------------------------------------------------*/ */ void prism2sta_ev_rx(wlandevice_t *wlandev, struct sk_buff *skb) { p80211netdev_rx(wlandev, skb); } /*---------------------------------------------------------------- /* * prism2sta_ev_alloc * * Handles the Alloc event. Loading @@ -1865,13 +1872,13 @@ void prism2sta_ev_rx(wlandevice_t *wlandev, struct sk_buff *skb) * * Call context: * interrupt ----------------------------------------------------------------*/ */ void prism2sta_ev_alloc(wlandevice_t *wlandev) { netif_wake_queue(wlandev->netdev); } /*---------------------------------------------------------------- /* * create_wlan * * Called at module init time. This creates the wlandevice_t structure Loading @@ -1889,7 +1896,7 @@ void prism2sta_ev_alloc(wlandevice_t *wlandev) * Call context: * process thread * ----------------------------------------------------------------*/ */ static wlandevice_t *create_wlan(void) { wlandevice_t *wlandev = NULL; Loading