cfg_cmd
volatile struct configure_cmd_struct *cfg_cmd;
cfg_cmd = (struct configure_cmd_struct *)ptr; /* configure-command */
cfg_cmd->cmd_status = 0;
cfg_cmd->cmd_cmd = swab16(CMD_CONFIGURE | CMD_LAST);
cfg_cmd->cmd_link = 0xffff;
cfg_cmd->byte_cnt = 0x0a; /* number of cfg bytes */
cfg_cmd->fifo = fifo; /* fifo-limit (8=tx:32/rx:64) */
cfg_cmd->sav_bf = 0x40; /* hold or discard bad recv frames (bit 7) */
cfg_cmd->adr_len = 0x2e; /* addr_len |!src_insert |pre-len |loopback */
cfg_cmd->priority = 0x00;
cfg_cmd->ifs = 0x60;
cfg_cmd->time_low = 0x00;
cfg_cmd->time_high = 0xf2;
cfg_cmd->promisc = 0;
cfg_cmd->promisc = 1;
cfg_cmd->promisc = 1;
cfg_cmd->carr_coll = 0x00;
p->scb->cbl_offset = make16(cfg_cmd);
WAIT_4_STAT_COMPL(cfg_cmd);
if((swab16(cfg_cmd->cmd_status) & (STAT_OK|STAT_COMPL)) != (STAT_COMPL|STAT_OK))
printk("%s: configure command failed: %x\n",dev->name,swab16(cfg_cmd->cmd_status));
struct iwl_tlc_config_cmd_v4 cfg_cmd = {
cfg_cmd.flags |=
cfg_cmd.sta_id = mvm_link_sta->sta_id;
&cfg_cmd);
cfg_cmd.max_tx_op = cpu_to_le16(mvmvif->max_tx_op);
cfg_cmd.sta_id, cfg_cmd.max_ch_width, cfg_cmd.mode);
cfg_cmd.chains, cfg_cmd.sgi_ch_width_supp, cfg_cmd.flags);
cfg_cmd.max_mpdu_len, cfg_cmd.non_ht_rates, cfg_cmd.max_tx_op);
cfg_cmd.ht_rates[0][0], cfg_cmd.ht_rates[1][0]);
cfg_cmd.ht_rates[0][1], cfg_cmd.ht_rates[1][1]);
cfg_cmd.ht_rates[0][2], cfg_cmd.ht_rates[1][2]);
sizeof(cfg_cmd), &cfg_cmd);
.sta_id = cfg_cmd.sta_id,
.max_ch_width = cfg_cmd.max_ch_width,
.mode = cfg_cmd.mode,
.chains = cfg_cmd.chains,
.amsdu = !!cfg_cmd.max_mpdu_len,
.flags = cfg_cmd.flags,
.non_ht_rates = cfg_cmd.non_ht_rates,
.ht_rates[0][0] = cfg_cmd.ht_rates[0][0],
.ht_rates[0][1] = cfg_cmd.ht_rates[0][1],
.ht_rates[1][0] = cfg_cmd.ht_rates[1][0],
.ht_rates[1][1] = cfg_cmd.ht_rates[1][1],
.sgi_ch_width_supp = cfg_cmd.sgi_ch_width_supp,
.max_mpdu_len = cfg_cmd.max_mpdu_len,
struct wlan_pwr_cfg cfg_cmd;
cfg_cmd = pwrcfgcmd[ary_idx];
GET_PWR_CFG_OFFSET(cfg_cmd),
GET_PWR_CFG_CUT_MASK(cfg_cmd),
GET_PWR_CFG_FAB_MASK(cfg_cmd),
GET_PWR_CFG_INTF_MASK(cfg_cmd),
GET_PWR_CFG_BASE(cfg_cmd), GET_PWR_CFG_CMD(cfg_cmd),
GET_PWR_CFG_MASK(cfg_cmd), GET_PWR_CFG_VALUE(cfg_cmd));
if ((GET_PWR_CFG_FAB_MASK(cfg_cmd)&faversion) &&
(GET_PWR_CFG_CUT_MASK(cfg_cmd)&cut_version) &&
(GET_PWR_CFG_INTF_MASK(cfg_cmd)&interface_type)) {
switch (GET_PWR_CFG_CMD(cfg_cmd)) {
offset = GET_PWR_CFG_OFFSET(cfg_cmd);
value &= (~(GET_PWR_CFG_MASK(cfg_cmd)));
value |= (GET_PWR_CFG_VALUE(cfg_cmd) &
GET_PWR_CFG_MASK(cfg_cmd));
offset = GET_PWR_CFG_OFFSET(cfg_cmd);
value &= GET_PWR_CFG_MASK(cfg_cmd);
(GET_PWR_CFG_VALUE(cfg_cmd) &
GET_PWR_CFG_MASK(cfg_cmd)))
if (GET_PWR_CFG_VALUE(cfg_cmd) ==
udelay(GET_PWR_CFG_OFFSET(cfg_cmd));
mdelay(GET_PWR_CFG_OFFSET(cfg_cmd));
struct xhci_command *stop_cmd, *cfg_cmd;
cfg_cmd = xhci_alloc_command_with_ctx(xhci, true, GFP_NOWAIT);
if (!cfg_cmd)
xhci_free_command(xhci, cfg_cmd);
xhci_free_command(xhci, cfg_cmd);
ctrl_ctx = xhci_get_input_control_ctx(cfg_cmd->in_ctx);
xhci_free_command(xhci, cfg_cmd);
xhci_setup_input_ctx_for_config_ep(xhci, cfg_cmd->in_ctx, vdev->out_ctx,
xhci_endpoint_copy(xhci, cfg_cmd->in_ctx, vdev->out_ctx, ep_index);
err = xhci_queue_configure_endpoint(xhci, cfg_cmd, cfg_cmd->in_ctx->dma,
xhci_free_command(xhci, cfg_cmd);
wait_for_completion(cfg_cmd->completion);
xhci_free_command(xhci, cfg_cmd);