return s32Error;
}
-
-/**
- * @brief sends certain Configuration Packet based on the input WIDs pstrWIDs
- * using driver config layer
- *
- * @details
- * @param[in] pstrWIDs WIDs to be sent in the configuration packet
- * @param[in] u32WIDsCount number of WIDs to be sent in the configuration packet
- * @param[out] pu8RxResp The received Packet Response
- * @param[out] ps32RxRespLen Length of the received Packet Response
- * @return Error code indicating success/failure
- * @note
- * @author mabubakr
- * @date 1 Mar 2012
- * @version 1.0
- */
-s32 wilc_send_config_pkt(struct wilc *wilc, u8 mode, struct wid *wids,
- u32 count, u32 drv)
-{
- s32 counter = 0, ret = 0;
-
- if (mode == GET_CFG) {
- for (counter = 0; counter < count; counter++) {
- PRINT_INFO(CORECONFIG_DBG, "Sending CFG packet [%d][%d]\n", !counter,
- (counter == count - 1));
- if (!wilc_wlan_cfg_get(wilc, !counter,
- wids[counter].id,
- (counter == count - 1),
- drv)) {
- ret = -ETIMEDOUT;
- printk("[Sendconfigpkt]Get Timed out\n");
- break;
- }
- }
- counter = 0;
- for (counter = 0; counter < count; counter++) {
- wids[counter].size = wilc_wlan_cfg_get_val(
- wids[counter].id,
- wids[counter].val,
- wids[counter].size);
- }
- } else if (mode == SET_CFG) {
- for (counter = 0; counter < count; counter++) {
- PRINT_D(CORECONFIG_DBG, "Sending config SET PACKET WID:%x\n", wids[counter].id);
- if (!wilc_wlan_cfg_set(wilc, !counter,
- wids[counter].id,
- wids[counter].val,
- wids[counter].size,
- (counter == count - 1),
- drv)) {
- ret = -ETIMEDOUT;
- printk("[Sendconfigpkt]Set Timed out\n");
- break;
- }
- }
- }
-
- return ret;
-}
CONNECT_STS_FORCE_16_BIT = 0xFFFF
} tenuConnectSts;
-struct wid {
- u16 id;
- enum wid_type type;
- s32 size;
- s8 *val;
-};
-
typedef struct {
u8 u8Full;
u8 u8Index;
size_t ie_len;
} tstrDisconnectNotifInfo;
-s32 wilc_send_config_pkt(struct wilc *wilc, u8 mode, struct wid *wids,
- u32 count, u32 drv);
s32 wilc_parse_network_info(u8 *pu8MsgBuffer, tstrNetworkInfo **ppstrNetworkInfo);
s32 wilc_dealloc_network_info(tstrNetworkInfo *pstrNetworkInfo);
return ret;
}
+s32 wilc_send_config_pkt(struct wilc *wilc, u8 mode, struct wid *wids,
+ u32 count, u32 drv)
+{
+ s32 counter = 0, ret = 0;
+
+ if (mode == GET_CFG) {
+ for (counter = 0; counter < count; counter++) {
+ if (!wilc_wlan_cfg_get(wilc, !counter,
+ wids[counter].id,
+ (counter == count - 1),
+ drv)) {
+ ret = -ETIMEDOUT;
+ break;
+ }
+ }
+ counter = 0;
+ for (counter = 0; counter < count; counter++) {
+ wids[counter].size = wilc_wlan_cfg_get_val(
+ wids[counter].id,
+ wids[counter].val,
+ wids[counter].size);
+ }
+ } else if (mode == SET_CFG) {
+ for (counter = 0; counter < count; counter++) {
+ if (!wilc_wlan_cfg_set(wilc, !counter,
+ wids[counter].id,
+ wids[counter].val,
+ wids[counter].size,
+ (counter == count - 1),
+ drv)) {
+ ret = -ETIMEDOUT;
+ break;
+ }
+ }
+ }
+
+ return ret;
+}
+
static u32 init_chip(struct net_device *dev)
{
u32 chipid;