Lines Matching refs:cmd
54 struct wl1271_cmd_header *cmd; in wl1271_cmd_send() local
61 cmd = buf; in wl1271_cmd_send()
62 cmd->id = cpu_to_le16(id); in wl1271_cmd_send()
63 cmd->status = 0; in wl1271_cmd_send()
94 wl1271_read(wl, wl->cmd_box_addr, cmd, res_len, false); in wl1271_cmd_send()
96 status = le16_to_cpu(cmd->status); in wl1271_cmd_send()
387 struct wl12xx_cmd_role_enable *cmd; in wl12xx_cmd_role_enable() local
395 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_enable()
396 if (!cmd) { in wl12xx_cmd_role_enable()
402 cmd->role_id = find_first_zero_bit(wl->roles_map, WL12XX_MAX_ROLES); in wl12xx_cmd_role_enable()
403 if (cmd->role_id >= WL12XX_MAX_ROLES) { in wl12xx_cmd_role_enable()
408 memcpy(cmd->mac_address, addr, ETH_ALEN); in wl12xx_cmd_role_enable()
409 cmd->role_type = role_type; in wl12xx_cmd_role_enable()
411 ret = wl1271_cmd_send(wl, CMD_ROLE_ENABLE, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_enable()
417 __set_bit(cmd->role_id, wl->roles_map); in wl12xx_cmd_role_enable()
418 *role_id = cmd->role_id; in wl12xx_cmd_role_enable()
421 kfree(cmd); in wl12xx_cmd_role_enable()
429 struct wl12xx_cmd_role_disable *cmd; in wl12xx_cmd_role_disable() local
437 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_disable()
438 if (!cmd) { in wl12xx_cmd_role_disable()
442 cmd->role_id = *role_id; in wl12xx_cmd_role_disable()
444 ret = wl1271_cmd_send(wl, CMD_ROLE_DISABLE, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_disable()
454 kfree(cmd); in wl12xx_cmd_role_disable()
512 struct wl12xx_cmd_role_start *cmd; in wl12xx_cmd_role_start_dev() local
515 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_start_dev()
516 if (!cmd) { in wl12xx_cmd_role_start_dev()
523 cmd->role_id = wlvif->dev_role_id; in wl12xx_cmd_role_start_dev()
525 cmd->band = WL12XX_BAND_5GHZ; in wl12xx_cmd_role_start_dev()
526 cmd->channel = wlvif->channel; in wl12xx_cmd_role_start_dev()
533 cmd->device.hlid = wlvif->dev_hlid; in wl12xx_cmd_role_start_dev()
534 cmd->device.session = wl12xx_get_new_session_id(wl, wlvif); in wl12xx_cmd_role_start_dev()
537 cmd->role_id, cmd->device.hlid, cmd->device.session); in wl12xx_cmd_role_start_dev()
539 ret = wl1271_cmd_send(wl, CMD_ROLE_START, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_start_dev()
552 kfree(cmd); in wl12xx_cmd_role_start_dev()
561 struct wl12xx_cmd_role_stop *cmd; in wl12xx_cmd_role_stop_dev() local
567 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_stop_dev()
568 if (!cmd) { in wl12xx_cmd_role_stop_dev()
575 cmd->role_id = wlvif->dev_role_id; in wl12xx_cmd_role_stop_dev()
576 cmd->disc_type = DISCONNECT_IMMEDIATE; in wl12xx_cmd_role_stop_dev()
577 cmd->reason = cpu_to_le16(WLAN_REASON_UNSPECIFIED); in wl12xx_cmd_role_stop_dev()
579 ret = wl1271_cmd_send(wl, CMD_ROLE_STOP, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_stop_dev()
594 kfree(cmd); in wl12xx_cmd_role_stop_dev()
603 struct wl12xx_cmd_role_start *cmd; in wl12xx_cmd_role_start_sta() local
606 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_start_sta()
607 if (!cmd) { in wl12xx_cmd_role_start_sta()
614 cmd->role_id = wlvif->role_id; in wl12xx_cmd_role_start_sta()
616 cmd->band = WL12XX_BAND_5GHZ; in wl12xx_cmd_role_start_sta()
617 cmd->channel = wlvif->channel; in wl12xx_cmd_role_start_sta()
618 cmd->sta.basic_rate_set = cpu_to_le32(wlvif->basic_rate_set); in wl12xx_cmd_role_start_sta()
619 cmd->sta.beacon_interval = cpu_to_le16(wlvif->beacon_int); in wl12xx_cmd_role_start_sta()
620 cmd->sta.ssid_type = WL12XX_SSID_TYPE_ANY; in wl12xx_cmd_role_start_sta()
621 cmd->sta.ssid_len = wlvif->ssid_len; in wl12xx_cmd_role_start_sta()
622 memcpy(cmd->sta.ssid, wlvif->ssid, wlvif->ssid_len); in wl12xx_cmd_role_start_sta()
623 memcpy(cmd->sta.bssid, vif->bss_conf.bssid, ETH_ALEN); in wl12xx_cmd_role_start_sta()
624 cmd->sta.local_rates = cpu_to_le32(wlvif->rate_set); in wl12xx_cmd_role_start_sta()
631 cmd->sta.hlid = wlvif->sta.hlid; in wl12xx_cmd_role_start_sta()
632 cmd->sta.session = wl12xx_get_new_session_id(wl, wlvif); in wl12xx_cmd_role_start_sta()
633 cmd->sta.remote_rates = cpu_to_le32(wlvif->rate_set); in wl12xx_cmd_role_start_sta()
637 wlvif->role_id, cmd->sta.hlid, cmd->sta.session, in wl12xx_cmd_role_start_sta()
640 ret = wl1271_cmd_send(wl, CMD_ROLE_START, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_start_sta()
653 kfree(cmd); in wl12xx_cmd_role_start_sta()
662 struct wl12xx_cmd_role_stop *cmd; in wl12xx_cmd_role_stop_sta() local
668 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_stop_sta()
669 if (!cmd) { in wl12xx_cmd_role_stop_sta()
676 cmd->role_id = wlvif->role_id; in wl12xx_cmd_role_stop_sta()
677 cmd->disc_type = DISCONNECT_IMMEDIATE; in wl12xx_cmd_role_stop_sta()
678 cmd->reason = cpu_to_le16(WLAN_REASON_UNSPECIFIED); in wl12xx_cmd_role_stop_sta()
680 ret = wl1271_cmd_send(wl, CMD_ROLE_STOP, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_stop_sta()
689 kfree(cmd); in wl12xx_cmd_role_stop_sta()
697 struct wl12xx_cmd_role_start *cmd; in wl12xx_cmd_role_start_ap() local
711 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_start_ap()
712 if (!cmd) { in wl12xx_cmd_role_start_ap()
725 cmd->role_id = wlvif->role_id; in wl12xx_cmd_role_start_ap()
726 cmd->ap.aging_period = cpu_to_le16(wl->conf.tx.ap_aging_period); in wl12xx_cmd_role_start_ap()
727 cmd->ap.bss_index = WL1271_AP_BSS_INDEX; in wl12xx_cmd_role_start_ap()
728 cmd->ap.global_hlid = wlvif->ap.global_hlid; in wl12xx_cmd_role_start_ap()
729 cmd->ap.broadcast_hlid = wlvif->ap.bcast_hlid; in wl12xx_cmd_role_start_ap()
730 cmd->ap.basic_rate_set = cpu_to_le32(wlvif->basic_rate_set); in wl12xx_cmd_role_start_ap()
731 cmd->ap.beacon_interval = cpu_to_le16(wlvif->beacon_int); in wl12xx_cmd_role_start_ap()
732 cmd->ap.dtim_interval = bss_conf->dtim_period; in wl12xx_cmd_role_start_ap()
733 cmd->ap.beacon_expiry = WL1271_AP_DEF_BEACON_EXP; in wl12xx_cmd_role_start_ap()
735 cmd->ap.reset_tsf = 1; /* By default reset AP TSF */ in wl12xx_cmd_role_start_ap()
736 cmd->channel = wlvif->channel; in wl12xx_cmd_role_start_ap()
740 cmd->ap.ssid_type = WL12XX_SSID_TYPE_PUBLIC; in wl12xx_cmd_role_start_ap()
741 cmd->ap.ssid_len = wlvif->ssid_len; in wl12xx_cmd_role_start_ap()
742 memcpy(cmd->ap.ssid, wlvif->ssid, wlvif->ssid_len); in wl12xx_cmd_role_start_ap()
744 cmd->ap.ssid_type = WL12XX_SSID_TYPE_HIDDEN; in wl12xx_cmd_role_start_ap()
745 cmd->ap.ssid_len = bss_conf->ssid_len; in wl12xx_cmd_role_start_ap()
746 memcpy(cmd->ap.ssid, bss_conf->ssid, bss_conf->ssid_len); in wl12xx_cmd_role_start_ap()
749 cmd->ap.local_rates = cpu_to_le32(0xffffffff); in wl12xx_cmd_role_start_ap()
753 cmd->band = RADIO_BAND_2_4GHZ; in wl12xx_cmd_role_start_ap()
756 cmd->band = RADIO_BAND_5GHZ; in wl12xx_cmd_role_start_ap()
760 cmd->band = RADIO_BAND_2_4GHZ; in wl12xx_cmd_role_start_ap()
764 ret = wl1271_cmd_send(wl, CMD_ROLE_START, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_start_ap()
779 kfree(cmd); in wl12xx_cmd_role_start_ap()
787 struct wl12xx_cmd_role_stop *cmd; in wl12xx_cmd_role_stop_ap() local
790 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_stop_ap()
791 if (!cmd) { in wl12xx_cmd_role_stop_ap()
798 cmd->role_id = wlvif->role_id; in wl12xx_cmd_role_stop_ap()
800 ret = wl1271_cmd_send(wl, CMD_ROLE_STOP, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_stop_ap()
810 kfree(cmd); in wl12xx_cmd_role_stop_ap()
819 struct wl12xx_cmd_role_start *cmd; in wl12xx_cmd_role_start_ibss() local
823 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_role_start_ibss()
824 if (!cmd) { in wl12xx_cmd_role_start_ibss()
831 cmd->role_id = wlvif->role_id; in wl12xx_cmd_role_start_ibss()
833 cmd->band = WL12XX_BAND_5GHZ; in wl12xx_cmd_role_start_ibss()
834 cmd->channel = wlvif->channel; in wl12xx_cmd_role_start_ibss()
835 cmd->ibss.basic_rate_set = cpu_to_le32(wlvif->basic_rate_set); in wl12xx_cmd_role_start_ibss()
836 cmd->ibss.beacon_interval = cpu_to_le16(wlvif->beacon_int); in wl12xx_cmd_role_start_ibss()
837 cmd->ibss.dtim_interval = bss_conf->dtim_period; in wl12xx_cmd_role_start_ibss()
838 cmd->ibss.ssid_type = WL12XX_SSID_TYPE_ANY; in wl12xx_cmd_role_start_ibss()
839 cmd->ibss.ssid_len = wlvif->ssid_len; in wl12xx_cmd_role_start_ibss()
840 memcpy(cmd->ibss.ssid, wlvif->ssid, wlvif->ssid_len); in wl12xx_cmd_role_start_ibss()
841 memcpy(cmd->ibss.bssid, vif->bss_conf.bssid, ETH_ALEN); in wl12xx_cmd_role_start_ibss()
842 cmd->sta.local_rates = cpu_to_le32(wlvif->rate_set); in wl12xx_cmd_role_start_ibss()
849 cmd->ibss.hlid = wlvif->sta.hlid; in wl12xx_cmd_role_start_ibss()
850 cmd->ibss.remote_rates = cpu_to_le32(wlvif->rate_set); in wl12xx_cmd_role_start_ibss()
854 wlvif->role_id, cmd->sta.hlid, cmd->sta.session, in wl12xx_cmd_role_start_ibss()
860 ret = wl1271_cmd_send(wl, CMD_ROLE_START, cmd, sizeof(*cmd), 0); in wl12xx_cmd_role_start_ibss()
873 kfree(cmd); in wl12xx_cmd_role_start_ibss()
966 struct cmd_enabledisable_path *cmd; in wl1271_cmd_data_path() local
972 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl1271_cmd_data_path()
973 if (!cmd) { in wl1271_cmd_data_path()
979 cmd->channel = 1; in wl1271_cmd_data_path()
989 ret = wl1271_cmd_send(wl, cmd_rx, cmd, sizeof(*cmd), 0); in wl1271_cmd_data_path()
992 enable ? "start" : "stop", cmd->channel); in wl1271_cmd_data_path()
997 enable ? "start" : "stop", cmd->channel); in wl1271_cmd_data_path()
999 ret = wl1271_cmd_send(wl, cmd_tx, cmd, sizeof(*cmd), 0); in wl1271_cmd_data_path()
1002 enable ? "start" : "stop", cmd->channel); in wl1271_cmd_data_path()
1007 enable ? "start" : "stop", cmd->channel); in wl1271_cmd_data_path()
1010 kfree(cmd); in wl1271_cmd_data_path()
1048 struct wl1271_cmd_template_set *cmd; in wl1271_cmd_template_set() local
1057 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl1271_cmd_template_set()
1058 if (!cmd) { in wl1271_cmd_template_set()
1064 cmd->role_id = role_id; in wl1271_cmd_template_set()
1065 cmd->len = cpu_to_le16(buf_len); in wl1271_cmd_template_set()
1066 cmd->template_type = template_id; in wl1271_cmd_template_set()
1067 cmd->enabled_rates = cpu_to_le32(rates); in wl1271_cmd_template_set()
1068 cmd->short_retry_limit = wl->conf.tx.tmpl_short_retry_limit; in wl1271_cmd_template_set()
1069 cmd->long_retry_limit = wl->conf.tx.tmpl_long_retry_limit; in wl1271_cmd_template_set()
1070 cmd->index = index; in wl1271_cmd_template_set()
1073 memcpy(cmd->template_data, buf, buf_len); in wl1271_cmd_template_set()
1075 ret = wl1271_cmd_send(wl, CMD_SET_TEMPLATE, cmd, sizeof(*cmd), 0); in wl1271_cmd_template_set()
1082 kfree(cmd); in wl1271_cmd_template_set()
1349 struct wl1271_cmd_set_keys *cmd; in wl12xx_cmd_set_default_wep_key() local
1354 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_set_default_wep_key()
1355 if (!cmd) { in wl12xx_cmd_set_default_wep_key()
1360 cmd->hlid = hlid; in wl12xx_cmd_set_default_wep_key()
1361 cmd->key_id = id; in wl12xx_cmd_set_default_wep_key()
1362 cmd->lid_key_type = WEP_DEFAULT_LID_TYPE; in wl12xx_cmd_set_default_wep_key()
1363 cmd->key_action = cpu_to_le16(KEY_SET_ID); in wl12xx_cmd_set_default_wep_key()
1364 cmd->key_type = KEY_WEP; in wl12xx_cmd_set_default_wep_key()
1366 ret = wl1271_cmd_send(wl, CMD_SET_KEYS, cmd, sizeof(*cmd), 0); in wl12xx_cmd_set_default_wep_key()
1373 kfree(cmd); in wl12xx_cmd_set_default_wep_key()
1383 struct wl1271_cmd_set_keys *cmd; in wl1271_cmd_set_sta_key() local
1390 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl1271_cmd_set_sta_key()
1391 if (!cmd) { in wl1271_cmd_set_sta_key()
1396 cmd->hlid = wlvif->sta.hlid; in wl1271_cmd_set_sta_key()
1399 cmd->lid_key_type = WEP_DEFAULT_LID_TYPE; in wl1271_cmd_set_sta_key()
1401 cmd->lid_key_type = BROADCAST_LID_TYPE; in wl1271_cmd_set_sta_key()
1403 cmd->lid_key_type = UNICAST_LID_TYPE; in wl1271_cmd_set_sta_key()
1405 cmd->key_action = cpu_to_le16(action); in wl1271_cmd_set_sta_key()
1406 cmd->key_size = key_size; in wl1271_cmd_set_sta_key()
1407 cmd->key_type = key_type; in wl1271_cmd_set_sta_key()
1409 cmd->ac_seq_num16[0] = cpu_to_le16(tx_seq_16); in wl1271_cmd_set_sta_key()
1410 cmd->ac_seq_num32[0] = cpu_to_le32(tx_seq_32); in wl1271_cmd_set_sta_key()
1412 cmd->key_id = id; in wl1271_cmd_set_sta_key()
1421 memcpy(cmd->key, key, 16); in wl1271_cmd_set_sta_key()
1422 memcpy(cmd->key + 16, key + 24, 8); in wl1271_cmd_set_sta_key()
1423 memcpy(cmd->key + 24, key + 16, 8); in wl1271_cmd_set_sta_key()
1426 memcpy(cmd->key, key, key_size); in wl1271_cmd_set_sta_key()
1429 wl1271_dump(DEBUG_CRYPT, "TARGET KEY: ", cmd, sizeof(*cmd)); in wl1271_cmd_set_sta_key()
1431 ret = wl1271_cmd_send(wl, CMD_SET_KEYS, cmd, sizeof(*cmd), 0); in wl1271_cmd_set_sta_key()
1438 kfree(cmd); in wl1271_cmd_set_sta_key()
1452 struct wl1271_cmd_set_keys *cmd; in wl1271_cmd_set_ap_key() local
1456 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl1271_cmd_set_ap_key()
1457 if (!cmd) in wl1271_cmd_set_ap_key()
1473 cmd->lid_key_type = lid_type; in wl1271_cmd_set_ap_key()
1474 cmd->hlid = hlid; in wl1271_cmd_set_ap_key()
1475 cmd->key_action = cpu_to_le16(action); in wl1271_cmd_set_ap_key()
1476 cmd->key_size = key_size; in wl1271_cmd_set_ap_key()
1477 cmd->key_type = key_type; in wl1271_cmd_set_ap_key()
1478 cmd->key_id = id; in wl1271_cmd_set_ap_key()
1479 cmd->ac_seq_num16[0] = cpu_to_le16(tx_seq_16); in wl1271_cmd_set_ap_key()
1480 cmd->ac_seq_num32[0] = cpu_to_le32(tx_seq_32); in wl1271_cmd_set_ap_key()
1489 memcpy(cmd->key, key, 16); in wl1271_cmd_set_ap_key()
1490 memcpy(cmd->key + 16, key + 24, 8); in wl1271_cmd_set_ap_key()
1491 memcpy(cmd->key + 24, key + 16, 8); in wl1271_cmd_set_ap_key()
1493 memcpy(cmd->key, key, key_size); in wl1271_cmd_set_ap_key()
1496 wl1271_dump(DEBUG_CRYPT, "TARGET AP KEY: ", cmd, sizeof(*cmd)); in wl1271_cmd_set_ap_key()
1498 ret = wl1271_cmd_send(wl, CMD_SET_KEYS, cmd, sizeof(*cmd), 0); in wl1271_cmd_set_ap_key()
1505 kfree(cmd); in wl1271_cmd_set_ap_key()
1511 struct wl12xx_cmd_set_peer_state *cmd; in wl12xx_cmd_set_peer_state() local
1516 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_set_peer_state()
1517 if (!cmd) { in wl12xx_cmd_set_peer_state()
1522 cmd->hlid = hlid; in wl12xx_cmd_set_peer_state()
1523 cmd->state = WL1271_CMD_STA_STATE_CONNECTED; in wl12xx_cmd_set_peer_state()
1525 ret = wl1271_cmd_send(wl, CMD_SET_PEER_STATE, cmd, sizeof(*cmd), 0); in wl12xx_cmd_set_peer_state()
1532 kfree(cmd); in wl12xx_cmd_set_peer_state()
1541 struct wl12xx_cmd_add_peer *cmd; in wl12xx_cmd_add_peer() local
1547 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_add_peer()
1548 if (!cmd) { in wl12xx_cmd_add_peer()
1553 memcpy(cmd->addr, sta->addr, ETH_ALEN); in wl12xx_cmd_add_peer()
1554 cmd->bss_index = WL1271_AP_BSS_INDEX; in wl12xx_cmd_add_peer()
1555 cmd->aid = sta->aid; in wl12xx_cmd_add_peer()
1556 cmd->hlid = hlid; in wl12xx_cmd_add_peer()
1557 cmd->sp_len = sta->max_sp; in wl12xx_cmd_add_peer()
1558 cmd->wmm = sta->wme ? 1 : 0; in wl12xx_cmd_add_peer()
1562 cmd->psd_type[i] = WL1271_PSD_UPSD_TRIGGER; in wl12xx_cmd_add_peer()
1564 cmd->psd_type[i] = WL1271_PSD_LEGACY; in wl12xx_cmd_add_peer()
1570 cmd->supported_rates = in wl12xx_cmd_add_peer()
1575 cmd->supported_rates, sta->uapsd_queues); in wl12xx_cmd_add_peer()
1577 ret = wl1271_cmd_send(wl, CMD_ADD_PEER, cmd, sizeof(*cmd), 0); in wl12xx_cmd_add_peer()
1584 kfree(cmd); in wl12xx_cmd_add_peer()
1592 struct wl12xx_cmd_remove_peer *cmd; in wl12xx_cmd_remove_peer() local
1597 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_remove_peer()
1598 if (!cmd) { in wl12xx_cmd_remove_peer()
1603 cmd->hlid = hlid; in wl12xx_cmd_remove_peer()
1605 cmd->reason_opcode = 0; in wl12xx_cmd_remove_peer()
1606 cmd->send_deauth_flag = 0; in wl12xx_cmd_remove_peer()
1608 ret = wl1271_cmd_send(wl, CMD_REMOVE_PEER, cmd, sizeof(*cmd), 0); in wl12xx_cmd_remove_peer()
1622 kfree(cmd); in wl12xx_cmd_remove_peer()
1630 struct wl12xx_cmd_config_fwlog *cmd; in wl12xx_cmd_config_fwlog() local
1635 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_config_fwlog()
1636 if (!cmd) { in wl12xx_cmd_config_fwlog()
1641 cmd->logger_mode = wl->conf.fwlog.mode; in wl12xx_cmd_config_fwlog()
1642 cmd->log_severity = wl->conf.fwlog.severity; in wl12xx_cmd_config_fwlog()
1643 cmd->timestamp = wl->conf.fwlog.timestamp; in wl12xx_cmd_config_fwlog()
1644 cmd->output = wl->conf.fwlog.output; in wl12xx_cmd_config_fwlog()
1645 cmd->threshold = wl->conf.fwlog.threshold; in wl12xx_cmd_config_fwlog()
1647 ret = wl1271_cmd_send(wl, CMD_CONFIG_FWLOGGER, cmd, sizeof(*cmd), 0); in wl12xx_cmd_config_fwlog()
1654 kfree(cmd); in wl12xx_cmd_config_fwlog()
1662 struct wl12xx_cmd_start_fwlog *cmd; in wl12xx_cmd_start_fwlog() local
1667 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_start_fwlog()
1668 if (!cmd) { in wl12xx_cmd_start_fwlog()
1673 ret = wl1271_cmd_send(wl, CMD_START_FWLOGGER, cmd, sizeof(*cmd), 0); in wl12xx_cmd_start_fwlog()
1680 kfree(cmd); in wl12xx_cmd_start_fwlog()
1688 struct wl12xx_cmd_stop_fwlog *cmd; in wl12xx_cmd_stop_fwlog() local
1693 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_stop_fwlog()
1694 if (!cmd) { in wl12xx_cmd_stop_fwlog()
1699 ret = wl1271_cmd_send(wl, CMD_STOP_FWLOGGER, cmd, sizeof(*cmd), 0); in wl12xx_cmd_stop_fwlog()
1706 kfree(cmd); in wl12xx_cmd_stop_fwlog()
1715 struct wl12xx_cmd_roc *cmd; in wl12xx_cmd_roc() local
1723 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_roc()
1724 if (!cmd) { in wl12xx_cmd_roc()
1729 cmd->role_id = role_id; in wl12xx_cmd_roc()
1730 cmd->channel = wlvif->channel; in wl12xx_cmd_roc()
1733 cmd->band = RADIO_BAND_2_4GHZ; in wl12xx_cmd_roc()
1736 cmd->band = RADIO_BAND_5GHZ; in wl12xx_cmd_roc()
1745 ret = wl1271_cmd_send(wl, CMD_REMAIN_ON_CHANNEL, cmd, sizeof(*cmd), 0); in wl12xx_cmd_roc()
1752 kfree(cmd); in wl12xx_cmd_roc()
1760 struct wl12xx_cmd_croc *cmd; in wl12xx_cmd_croc() local
1765 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_croc()
1766 if (!cmd) { in wl12xx_cmd_croc()
1770 cmd->role_id = role_id; in wl12xx_cmd_croc()
1772 ret = wl1271_cmd_send(wl, CMD_CANCEL_REMAIN_ON_CHANNEL, cmd, in wl12xx_cmd_croc()
1773 sizeof(*cmd), 0); in wl12xx_cmd_croc()
1780 kfree(cmd); in wl12xx_cmd_croc()
1837 struct wl12xx_cmd_channel_switch *cmd; in wl12xx_cmd_channel_switch() local
1842 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_channel_switch()
1843 if (!cmd) { in wl12xx_cmd_channel_switch()
1848 cmd->role_id = wlvif->role_id; in wl12xx_cmd_channel_switch()
1849 cmd->channel = ch_switch->channel->hw_value; in wl12xx_cmd_channel_switch()
1850 cmd->switch_time = ch_switch->count; in wl12xx_cmd_channel_switch()
1851 cmd->stop_tx = ch_switch->block_tx; in wl12xx_cmd_channel_switch()
1854 cmd->post_switch_tx_disable = 0; /* Enable TX on the target channel */ in wl12xx_cmd_channel_switch()
1856 ret = wl1271_cmd_send(wl, CMD_CHANNEL_SWITCH, cmd, sizeof(*cmd), 0); in wl12xx_cmd_channel_switch()
1863 kfree(cmd); in wl12xx_cmd_channel_switch()
1871 struct wl12xx_cmd_stop_channel_switch *cmd; in wl12xx_cmd_stop_channel_switch() local
1876 cmd = kzalloc(sizeof(*cmd), GFP_KERNEL); in wl12xx_cmd_stop_channel_switch()
1877 if (!cmd) { in wl12xx_cmd_stop_channel_switch()
1882 ret = wl1271_cmd_send(wl, CMD_STOP_CHANNEL_SWICTH, cmd, sizeof(*cmd), 0); in wl12xx_cmd_stop_channel_switch()
1889 kfree(cmd); in wl12xx_cmd_stop_channel_switch()