Lines Matching refs:cmd
43 struct wl1271_cmd_header *cmd; in __wlcore_cmd_send() local
54 if (WARN_ON_ONCE(len < sizeof(*cmd))) in __wlcore_cmd_send()
57 cmd = buf; in __wlcore_cmd_send()
58 cmd->id = cpu_to_le16(id); in __wlcore_cmd_send()
59 cmd->status = 0; in __wlcore_cmd_send()
103 ret = wlcore_read(wl, wl->cmd_box_addr, cmd, res_len, false); in __wlcore_cmd_send()
107 status = le16_to_cpu(cmd->status); in __wlcore_cmd_send()
229 struct wl12xx_cmd_role_enable *cmd; in wl12xx_cmd_role_enable() local
237 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_enable()
238 if (!cmd) { in wl12xx_cmd_role_enable()
244 cmd->role_id = find_first_zero_bit(wl->roles_map, WL12XX_MAX_ROLES); in wl12xx_cmd_role_enable()
245 if (cmd->role_id >= WL12XX_MAX_ROLES) { in wl12xx_cmd_role_enable()
250 memcpy(cmd->mac_address, addr, ETH_ALEN); in wl12xx_cmd_role_enable()
251 cmd->role_type = role_type; in wl12xx_cmd_role_enable()
253 ret = wl1271_cmd_send(wl, CMD_ROLE_ENABLE, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_enable()
259 __set_bit(cmd->role_id, wl->roles_map); in wl12xx_cmd_role_enable()
260 *role_id = cmd->role_id; in wl12xx_cmd_role_enable()
263 kfree(cmd); in wl12xx_cmd_role_enable()
271 struct wl12xx_cmd_role_disable *cmd; in wl12xx_cmd_role_disable() local
279 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_disable()
280 if (!cmd) { in wl12xx_cmd_role_disable()
284 cmd->role_id = *role_id; in wl12xx_cmd_role_disable()
286 ret = wl1271_cmd_send(wl, CMD_ROLE_DISABLE, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_disable()
296 kfree(cmd); in wl12xx_cmd_role_disable()
425 struct wl12xx_cmd_role_start *cmd; in wl12xx_cmd_role_start_dev() local
428 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_start_dev()
429 if (!cmd) { in wl12xx_cmd_role_start_dev()
436 cmd->role_id = wlvif->dev_role_id; in wl12xx_cmd_role_start_dev()
438 cmd->band = WLCORE_BAND_5GHZ; in wl12xx_cmd_role_start_dev()
439 cmd->channel = channel; in wl12xx_cmd_role_start_dev()
446 cmd->device.hlid = wlvif->dev_hlid; in wl12xx_cmd_role_start_dev()
447 cmd->device.session = wl->session_ids[wlvif->dev_hlid]; in wl12xx_cmd_role_start_dev()
450 cmd->role_id, cmd->device.hlid, cmd->device.session); in wl12xx_cmd_role_start_dev()
452 ret = wl1271_cmd_send(wl, CMD_ROLE_START, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_start_dev()
465 kfree(cmd); in wl12xx_cmd_role_start_dev()
474 struct wl12xx_cmd_role_stop *cmd; in wl12xx_cmd_role_stop_dev() local
480 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_stop_dev()
481 if (!cmd) { in wl12xx_cmd_role_stop_dev()
488 cmd->role_id = wlvif->dev_role_id; in wl12xx_cmd_role_stop_dev()
489 cmd->disc_type = DISCONNECT_IMMEDIATE; in wl12xx_cmd_role_stop_dev()
490 cmd->reason = cpu_to_le16(WLAN_REASON_UNSPECIFIED); in wl12xx_cmd_role_stop_dev()
492 ret = wl1271_cmd_send(wl, CMD_ROLE_STOP, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_stop_dev()
501 kfree(cmd); in wl12xx_cmd_role_stop_dev()
510 struct wl12xx_cmd_role_start *cmd; in wl12xx_cmd_role_start_sta() local
514 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_start_sta()
515 if (!cmd) { in wl12xx_cmd_role_start_sta()
522 cmd->role_id = wlvif->role_id; in wl12xx_cmd_role_start_sta()
524 cmd->band = WLCORE_BAND_5GHZ; in wl12xx_cmd_role_start_sta()
525 cmd->channel = wlvif->channel; in wl12xx_cmd_role_start_sta()
526 cmd->sta.basic_rate_set = cpu_to_le32(wlvif->basic_rate_set); in wl12xx_cmd_role_start_sta()
527 cmd->sta.beacon_interval = cpu_to_le16(wlvif->beacon_int); in wl12xx_cmd_role_start_sta()
528 cmd->sta.ssid_type = WL12XX_SSID_TYPE_ANY; in wl12xx_cmd_role_start_sta()
529 cmd->sta.ssid_len = wlvif->ssid_len; in wl12xx_cmd_role_start_sta()
530 memcpy(cmd->sta.ssid, wlvif->ssid, wlvif->ssid_len); in wl12xx_cmd_role_start_sta()
531 memcpy(cmd->sta.bssid, vif->bss_conf.bssid, ETH_ALEN); in wl12xx_cmd_role_start_sta()
538 cmd->sta.local_rates = cpu_to_le32(supported_rates); in wl12xx_cmd_role_start_sta()
540 cmd->channel_type = wlcore_get_native_channel_type(wlvif->channel_type); in wl12xx_cmd_role_start_sta()
547 cmd->sta.hlid = wlvif->sta.hlid; in wl12xx_cmd_role_start_sta()
548 cmd->sta.session = wl->session_ids[wlvif->sta.hlid]; in wl12xx_cmd_role_start_sta()
555 cmd->sta.remote_rates = cpu_to_le32(supported_rates); in wl12xx_cmd_role_start_sta()
559 wlvif->role_id, cmd->sta.hlid, cmd->sta.session, in wl12xx_cmd_role_start_sta()
562 ret = wl1271_cmd_send(wl, CMD_ROLE_START, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_start_sta()
576 kfree(cmd); in wl12xx_cmd_role_start_sta()
585 struct wl12xx_cmd_role_stop *cmd; in wl12xx_cmd_role_stop_sta() local
591 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_stop_sta()
592 if (!cmd) { in wl12xx_cmd_role_stop_sta()
599 cmd->role_id = wlvif->role_id; in wl12xx_cmd_role_stop_sta()
600 cmd->disc_type = DISCONNECT_IMMEDIATE; in wl12xx_cmd_role_stop_sta()
601 cmd->reason = cpu_to_le16(WLAN_REASON_UNSPECIFIED); in wl12xx_cmd_role_stop_sta()
603 ret = wl1271_cmd_send(wl, CMD_ROLE_STOP, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_stop_sta()
612 kfree(cmd); in wl12xx_cmd_role_stop_sta()
620 struct wl12xx_cmd_role_start *cmd; in wl12xx_cmd_role_start_ap() local
638 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_start_ap()
639 if (!cmd) { in wl12xx_cmd_role_start_ap()
656 cmd->role_id = wlvif->role_id; in wl12xx_cmd_role_start_ap()
657 cmd->ap.aging_period = cpu_to_le16(wl->conf.tx.ap_aging_period); in wl12xx_cmd_role_start_ap()
658 cmd->ap.bss_index = WL1271_AP_BSS_INDEX; in wl12xx_cmd_role_start_ap()
659 cmd->ap.global_hlid = wlvif->ap.global_hlid; in wl12xx_cmd_role_start_ap()
660 cmd->ap.broadcast_hlid = wlvif->ap.bcast_hlid; in wl12xx_cmd_role_start_ap()
661 cmd->ap.global_session_id = wl->session_ids[wlvif->ap.global_hlid]; in wl12xx_cmd_role_start_ap()
662 cmd->ap.bcast_session_id = wl->session_ids[wlvif->ap.bcast_hlid]; in wl12xx_cmd_role_start_ap()
663 cmd->ap.basic_rate_set = cpu_to_le32(wlvif->basic_rate_set); in wl12xx_cmd_role_start_ap()
664 cmd->ap.beacon_interval = cpu_to_le16(wlvif->beacon_int); in wl12xx_cmd_role_start_ap()
665 cmd->ap.dtim_interval = bss_conf->dtim_period; in wl12xx_cmd_role_start_ap()
666 cmd->ap.beacon_expiry = WL1271_AP_DEF_BEACON_EXP; in wl12xx_cmd_role_start_ap()
668 cmd->ap.reset_tsf = 1; /* By default reset AP TSF */ in wl12xx_cmd_role_start_ap()
669 cmd->ap.wmm = wlvif->wmm_enabled; in wl12xx_cmd_role_start_ap()
670 cmd->channel = wlvif->channel; in wl12xx_cmd_role_start_ap()
671 cmd->channel_type = wlcore_get_native_channel_type(wlvif->channel_type); in wl12xx_cmd_role_start_ap()
675 cmd->ap.ssid_type = WL12XX_SSID_TYPE_PUBLIC; in wl12xx_cmd_role_start_ap()
676 cmd->ap.ssid_len = wlvif->ssid_len; in wl12xx_cmd_role_start_ap()
677 memcpy(cmd->ap.ssid, wlvif->ssid, wlvif->ssid_len); in wl12xx_cmd_role_start_ap()
679 cmd->ap.ssid_type = WL12XX_SSID_TYPE_HIDDEN; in wl12xx_cmd_role_start_ap()
680 cmd->ap.ssid_len = bss_conf->ssid_len; in wl12xx_cmd_role_start_ap()
681 memcpy(cmd->ap.ssid, bss_conf->ssid, bss_conf->ssid_len); in wl12xx_cmd_role_start_ap()
692 cmd->ap.local_rates = cpu_to_le32(supported_rates); in wl12xx_cmd_role_start_ap()
696 cmd->band = WLCORE_BAND_2_4GHZ; in wl12xx_cmd_role_start_ap()
699 cmd->band = WLCORE_BAND_5GHZ; in wl12xx_cmd_role_start_ap()
703 cmd->band = WLCORE_BAND_2_4GHZ; in wl12xx_cmd_role_start_ap()
707 ret = wl1271_cmd_send(wl, CMD_ROLE_START, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_start_ap()
722 kfree(cmd); in wl12xx_cmd_role_start_ap()
730 struct wl12xx_cmd_role_stop *cmd; in wl12xx_cmd_role_stop_ap() local
733 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_stop_ap()
734 if (!cmd) { in wl12xx_cmd_role_stop_ap()
741 cmd->role_id = wlvif->role_id; in wl12xx_cmd_role_stop_ap()
743 ret = wl1271_cmd_send(wl, CMD_ROLE_STOP, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_stop_ap()
753 kfree(cmd); in wl12xx_cmd_role_stop_ap()
762 struct wl12xx_cmd_role_start *cmd; in wl12xx_cmd_role_start_ibss() local
766 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_start_ibss()
767 if (!cmd) { in wl12xx_cmd_role_start_ibss()
774 cmd->role_id = wlvif->role_id; in wl12xx_cmd_role_start_ibss()
776 cmd->band = WLCORE_BAND_5GHZ; in wl12xx_cmd_role_start_ibss()
777 cmd->channel = wlvif->channel; in wl12xx_cmd_role_start_ibss()
778 cmd->ibss.basic_rate_set = cpu_to_le32(wlvif->basic_rate_set); in wl12xx_cmd_role_start_ibss()
779 cmd->ibss.beacon_interval = cpu_to_le16(wlvif->beacon_int); in wl12xx_cmd_role_start_ibss()
780 cmd->ibss.dtim_interval = bss_conf->dtim_period; in wl12xx_cmd_role_start_ibss()
781 cmd->ibss.ssid_type = WL12XX_SSID_TYPE_ANY; in wl12xx_cmd_role_start_ibss()
782 cmd->ibss.ssid_len = wlvif->ssid_len; in wl12xx_cmd_role_start_ibss()
783 memcpy(cmd->ibss.ssid, wlvif->ssid, wlvif->ssid_len); in wl12xx_cmd_role_start_ibss()
784 memcpy(cmd->ibss.bssid, vif->bss_conf.bssid, ETH_ALEN); in wl12xx_cmd_role_start_ibss()
785 cmd->sta.local_rates = cpu_to_le32(wlvif->rate_set); in wl12xx_cmd_role_start_ibss()
792 cmd->ibss.hlid = wlvif->sta.hlid; in wl12xx_cmd_role_start_ibss()
793 cmd->ibss.remote_rates = cpu_to_le32(wlvif->rate_set); in wl12xx_cmd_role_start_ibss()
797 wlvif->role_id, cmd->sta.hlid, cmd->sta.session, in wl12xx_cmd_role_start_ibss()
803 ret = wl1271_cmd_send(wl, CMD_ROLE_START, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_start_ibss()
816 kfree(cmd); in wl12xx_cmd_role_start_ibss()
933 struct cmd_enabledisable_path *cmd; in wl1271_cmd_data_path() local
939 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl1271_cmd_data_path()
940 if (!cmd) { in wl1271_cmd_data_path()
946 cmd->channel = 1; in wl1271_cmd_data_path()
956 ret = wl1271_cmd_send(wl, cmd_rx, cmd, sizeof(*cmd), 0); in wl1271_cmd_data_path()
959 enable ? "start" : "stop", cmd->channel); in wl1271_cmd_data_path()
964 enable ? "start" : "stop", cmd->channel); in wl1271_cmd_data_path()
966 ret = wl1271_cmd_send(wl, cmd_tx, cmd, sizeof(*cmd), 0); in wl1271_cmd_data_path()
969 enable ? "start" : "stop", cmd->channel); in wl1271_cmd_data_path()
974 enable ? "start" : "stop", cmd->channel); in wl1271_cmd_data_path()
977 kfree(cmd); in wl1271_cmd_data_path()
1016 struct wl1271_cmd_template_set *cmd; in wl1271_cmd_template_set() local
1025 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl1271_cmd_template_set()
1026 if (!cmd) { in wl1271_cmd_template_set()
1032 cmd->role_id = role_id; in wl1271_cmd_template_set()
1033 cmd->len = cpu_to_le16(buf_len); in wl1271_cmd_template_set()
1034 cmd->template_type = template_id; in wl1271_cmd_template_set()
1035 cmd->enabled_rates = cpu_to_le32(rates); in wl1271_cmd_template_set()
1036 cmd->short_retry_limit = wl->conf.tx.tmpl_short_retry_limit; in wl1271_cmd_template_set()
1037 cmd->long_retry_limit = wl->conf.tx.tmpl_long_retry_limit; in wl1271_cmd_template_set()
1038 cmd->index = index; in wl1271_cmd_template_set()
1041 memcpy(cmd->template_data, buf, buf_len); in wl1271_cmd_template_set()
1043 ret = wl1271_cmd_send(wl, CMD_SET_TEMPLATE, cmd, sizeof(*cmd), 0); in wl1271_cmd_template_set()
1050 kfree(cmd); in wl1271_cmd_template_set()
1332 struct wl1271_cmd_set_keys *cmd; in wl12xx_cmd_set_default_wep_key() local
1337 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_set_default_wep_key()
1338 if (!cmd) { in wl12xx_cmd_set_default_wep_key()
1343 cmd->hlid = hlid; in wl12xx_cmd_set_default_wep_key()
1344 cmd->key_id = id; in wl12xx_cmd_set_default_wep_key()
1345 cmd->lid_key_type = WEP_DEFAULT_LID_TYPE; in wl12xx_cmd_set_default_wep_key()
1346 cmd->key_action = cpu_to_le16(KEY_SET_ID); in wl12xx_cmd_set_default_wep_key()
1347 cmd->key_type = KEY_WEP; in wl12xx_cmd_set_default_wep_key()
1349 ret = wl1271_cmd_send(wl, CMD_SET_KEYS, cmd, sizeof(*cmd), 0); in wl12xx_cmd_set_default_wep_key()
1356 kfree(cmd); in wl12xx_cmd_set_default_wep_key()
1366 struct wl1271_cmd_set_keys *cmd; in wl1271_cmd_set_sta_key() local
1373 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl1271_cmd_set_sta_key()
1374 if (!cmd) { in wl1271_cmd_set_sta_key()
1379 cmd->hlid = wlvif->sta.hlid; in wl1271_cmd_set_sta_key()
1382 cmd->lid_key_type = WEP_DEFAULT_LID_TYPE; in wl1271_cmd_set_sta_key()
1384 cmd->lid_key_type = BROADCAST_LID_TYPE; in wl1271_cmd_set_sta_key()
1386 cmd->lid_key_type = UNICAST_LID_TYPE; in wl1271_cmd_set_sta_key()
1388 cmd->key_action = cpu_to_le16(action); in wl1271_cmd_set_sta_key()
1389 cmd->key_size = key_size; in wl1271_cmd_set_sta_key()
1390 cmd->key_type = key_type; in wl1271_cmd_set_sta_key()
1392 cmd->ac_seq_num16[0] = cpu_to_le16(tx_seq_16); in wl1271_cmd_set_sta_key()
1393 cmd->ac_seq_num32[0] = cpu_to_le32(tx_seq_32); in wl1271_cmd_set_sta_key()
1395 cmd->key_id = id; in wl1271_cmd_set_sta_key()
1404 memcpy(cmd->key, key, 16); in wl1271_cmd_set_sta_key()
1405 memcpy(cmd->key + 16, key + 24, 8); in wl1271_cmd_set_sta_key()
1406 memcpy(cmd->key + 24, key + 16, 8); in wl1271_cmd_set_sta_key()
1409 memcpy(cmd->key, key, key_size); in wl1271_cmd_set_sta_key()
1412 wl1271_dump(DEBUG_CRYPT, "TARGET KEY: ", cmd, sizeof(*cmd)); in wl1271_cmd_set_sta_key()
1414 ret = wl1271_cmd_send(wl, CMD_SET_KEYS, cmd, sizeof(*cmd), 0); in wl1271_cmd_set_sta_key()
1421 kfree(cmd); in wl1271_cmd_set_sta_key()
1435 struct wl1271_cmd_set_keys *cmd; in wl1271_cmd_set_ap_key() local
1439 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl1271_cmd_set_ap_key()
1440 if (!cmd) in wl1271_cmd_set_ap_key()
1458 cmd->lid_key_type = lid_type; in wl1271_cmd_set_ap_key()
1459 cmd->hlid = hlid; in wl1271_cmd_set_ap_key()
1460 cmd->key_action = cpu_to_le16(action); in wl1271_cmd_set_ap_key()
1461 cmd->key_size = key_size; in wl1271_cmd_set_ap_key()
1462 cmd->key_type = key_type; in wl1271_cmd_set_ap_key()
1463 cmd->key_id = id; in wl1271_cmd_set_ap_key()
1464 cmd->ac_seq_num16[0] = cpu_to_le16(tx_seq_16); in wl1271_cmd_set_ap_key()
1465 cmd->ac_seq_num32[0] = cpu_to_le32(tx_seq_32); in wl1271_cmd_set_ap_key()
1474 memcpy(cmd->key, key, 16); in wl1271_cmd_set_ap_key()
1475 memcpy(cmd->key + 16, key + 24, 8); in wl1271_cmd_set_ap_key()
1476 memcpy(cmd->key + 24, key + 16, 8); in wl1271_cmd_set_ap_key()
1478 memcpy(cmd->key, key, key_size); in wl1271_cmd_set_ap_key()
1481 wl1271_dump(DEBUG_CRYPT, "TARGET AP KEY: ", cmd, sizeof(*cmd)); in wl1271_cmd_set_ap_key()
1483 ret = wl1271_cmd_send(wl, CMD_SET_KEYS, cmd, sizeof(*cmd), 0); in wl1271_cmd_set_ap_key()
1490 kfree(cmd); in wl1271_cmd_set_ap_key()
1497 struct wl12xx_cmd_set_peer_state *cmd; in wl12xx_cmd_set_peer_state() local
1502 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_set_peer_state()
1503 if (!cmd) { in wl12xx_cmd_set_peer_state()
1508 cmd->hlid = hlid; in wl12xx_cmd_set_peer_state()
1509 cmd->state = WL1271_CMD_STA_STATE_CONNECTED; in wl12xx_cmd_set_peer_state()
1513 cmd->wmm = wlvif->wmm_enabled; in wl12xx_cmd_set_peer_state()
1515 ret = wl1271_cmd_send(wl, CMD_SET_PEER_STATE, cmd, sizeof(*cmd), 0); in wl12xx_cmd_set_peer_state()
1522 kfree(cmd); in wl12xx_cmd_set_peer_state()
1531 struct wl12xx_cmd_add_peer *cmd; in wl12xx_cmd_add_peer() local
1537 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_add_peer()
1538 if (!cmd) { in wl12xx_cmd_add_peer()
1543 memcpy(cmd->addr, sta->addr, ETH_ALEN); in wl12xx_cmd_add_peer()
1544 cmd->bss_index = WL1271_AP_BSS_INDEX; in wl12xx_cmd_add_peer()
1545 cmd->aid = sta->aid; in wl12xx_cmd_add_peer()
1546 cmd->hlid = hlid; in wl12xx_cmd_add_peer()
1547 cmd->sp_len = sta->max_sp; in wl12xx_cmd_add_peer()
1548 cmd->wmm = sta->wme ? 1 : 0; in wl12xx_cmd_add_peer()
1549 cmd->session_id = wl->session_ids[hlid]; in wl12xx_cmd_add_peer()
1550 cmd->role_id = wlvif->role_id; in wl12xx_cmd_add_peer()
1554 cmd->psd_type[NUM_ACCESS_CATEGORIES_COPY-1-i] = in wl12xx_cmd_add_peer()
1557 cmd->psd_type[NUM_ACCESS_CATEGORIES_COPY-1-i] = in wl12xx_cmd_add_peer()
1567 cmd->supported_rates = in wl12xx_cmd_add_peer()
1571 if (!cmd->supported_rates) { in wl12xx_cmd_add_peer()
1575 cmd->supported_rates = cpu_to_le32(wlvif->basic_rate_set); in wl12xx_cmd_add_peer()
1579 cmd->supported_rates, sta->uapsd_queues); in wl12xx_cmd_add_peer()
1581 ret = wl1271_cmd_send(wl, CMD_ADD_PEER, cmd, sizeof(*cmd), 0); in wl12xx_cmd_add_peer()
1588 kfree(cmd); in wl12xx_cmd_add_peer()
1597 struct wl12xx_cmd_remove_peer *cmd; in wl12xx_cmd_remove_peer() local
1603 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_remove_peer()
1604 if (!cmd) { in wl12xx_cmd_remove_peer()
1609 cmd->hlid = hlid; in wl12xx_cmd_remove_peer()
1611 cmd->reason_opcode = 0; in wl12xx_cmd_remove_peer()
1612 cmd->send_deauth_flag = 0; in wl12xx_cmd_remove_peer()
1613 cmd->role_id = wlvif->role_id; in wl12xx_cmd_remove_peer()
1615 ret = wl1271_cmd_send(wl, CMD_REMOVE_PEER, cmd, sizeof(*cmd), 0); in wl12xx_cmd_remove_peer()
1634 kfree(cmd); in wl12xx_cmd_remove_peer()
1697 struct wl12xx_cmd_regdomain_dfs_config *cmd = NULL; in wlcore_cmd_regdomain_config_locked() local
1737 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wlcore_cmd_regdomain_config_locked()
1738 if (!cmd) { in wlcore_cmd_regdomain_config_locked()
1743 cmd->ch_bit_map1 = tmp_ch_bitmap[0]; in wlcore_cmd_regdomain_config_locked()
1744 cmd->ch_bit_map2 = tmp_ch_bitmap[1]; in wlcore_cmd_regdomain_config_locked()
1745 cmd->dfs_region = wl->dfs_region; in wlcore_cmd_regdomain_config_locked()
1749 cmd->ch_bit_map1, cmd->ch_bit_map2); in wlcore_cmd_regdomain_config_locked()
1751 ret = wl1271_cmd_send(wl, CMD_DFS_CHANNEL_CONFIG, cmd, sizeof(*cmd), 0); in wlcore_cmd_regdomain_config_locked()
1771 kfree(cmd); in wlcore_cmd_regdomain_config_locked()
1777 struct wl12xx_cmd_config_fwlog *cmd; in wl12xx_cmd_config_fwlog() local
1782 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_config_fwlog()
1783 if (!cmd) { in wl12xx_cmd_config_fwlog()
1788 cmd->logger_mode = wl->conf.fwlog.mode; in wl12xx_cmd_config_fwlog()
1789 cmd->log_severity = wl->conf.fwlog.severity; in wl12xx_cmd_config_fwlog()
1790 cmd->timestamp = wl->conf.fwlog.timestamp; in wl12xx_cmd_config_fwlog()
1791 cmd->output = wl->conf.fwlog.output; in wl12xx_cmd_config_fwlog()
1792 cmd->threshold = wl->conf.fwlog.threshold; in wl12xx_cmd_config_fwlog()
1794 ret = wl1271_cmd_send(wl, CMD_CONFIG_FWLOGGER, cmd, sizeof(*cmd), 0); in wl12xx_cmd_config_fwlog()
1801 kfree(cmd); in wl12xx_cmd_config_fwlog()
1809 struct wl12xx_cmd_start_fwlog *cmd; in wl12xx_cmd_start_fwlog() local
1814 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_start_fwlog()
1815 if (!cmd) { in wl12xx_cmd_start_fwlog()
1820 ret = wl1271_cmd_send(wl, CMD_START_FWLOGGER, cmd, sizeof(*cmd), 0); in wl12xx_cmd_start_fwlog()
1827 kfree(cmd); in wl12xx_cmd_start_fwlog()
1835 struct wl12xx_cmd_stop_fwlog *cmd; in wl12xx_cmd_stop_fwlog() local
1840 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_stop_fwlog()
1841 if (!cmd) { in wl12xx_cmd_stop_fwlog()
1846 ret = wl1271_cmd_send(wl, CMD_STOP_FWLOGGER, cmd, sizeof(*cmd), 0); in wl12xx_cmd_stop_fwlog()
1853 kfree(cmd); in wl12xx_cmd_stop_fwlog()
1862 struct wl12xx_cmd_roc *cmd; in wl12xx_cmd_roc() local
1870 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_roc()
1871 if (!cmd) { in wl12xx_cmd_roc()
1876 cmd->role_id = role_id; in wl12xx_cmd_roc()
1877 cmd->channel = channel; in wl12xx_cmd_roc()
1880 cmd->band = WLCORE_BAND_2_4GHZ; in wl12xx_cmd_roc()
1883 cmd->band = WLCORE_BAND_5GHZ; in wl12xx_cmd_roc()
1892 ret = wl1271_cmd_send(wl, CMD_REMAIN_ON_CHANNEL, cmd, sizeof(*cmd), 0); in wl12xx_cmd_roc()
1899 kfree(cmd); in wl12xx_cmd_roc()
1907 struct wl12xx_cmd_croc *cmd; in wl12xx_cmd_croc() local
1912 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_croc()
1913 if (!cmd) { in wl12xx_cmd_croc()
1917 cmd->role_id = role_id; in wl12xx_cmd_croc()
1919 ret = wl1271_cmd_send(wl, CMD_CANCEL_REMAIN_ON_CHANNEL, cmd, in wl12xx_cmd_croc()
1920 sizeof(*cmd), 0); in wl12xx_cmd_croc()
1927 kfree(cmd); in wl12xx_cmd_croc()
1976 struct wl12xx_cmd_stop_channel_switch *cmd; in wl12xx_cmd_stop_channel_switch() local
1981 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_stop_channel_switch()
1982 if (!cmd) { in wl12xx_cmd_stop_channel_switch()
1987 cmd->role_id = wlvif->role_id; in wl12xx_cmd_stop_channel_switch()
1989 ret = wl1271_cmd_send(wl, CMD_STOP_CHANNEL_SWICTH, cmd, sizeof(*cmd), 0); in wl12xx_cmd_stop_channel_switch()
1996 kfree(cmd); in wl12xx_cmd_stop_channel_switch()
2078 struct wlcore_cmd_generic_cfg *cmd; in wlcore_cmd_generic_cfg() local
2085 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wlcore_cmd_generic_cfg()
2086 if (!cmd) in wlcore_cmd_generic_cfg()
2089 cmd->role_id = wlvif->role_id; in wlcore_cmd_generic_cfg()
2090 cmd->feature = feature; in wlcore_cmd_generic_cfg()
2091 cmd->enable = enable; in wlcore_cmd_generic_cfg()
2092 cmd->value = value; in wlcore_cmd_generic_cfg()
2094 ret = wl1271_cmd_send(wl, CMD_GENERIC_CFG, cmd, sizeof(*cmd), 0); in wlcore_cmd_generic_cfg()
2100 kfree(cmd); in wlcore_cmd_generic_cfg()