Lines Matching refs:cmd

64 	pCmd->cmdhdr.cmd = htole16(_cmd);				\
134 device_printf(dev, "unable to allocate memory for cmd tag, "
144 device_printf(dev, "unable to allocate memory for cmd buffer, "
154 device_printf(dev, "unable to load cmd buffer, error %u\n",
173 * Low level firmware cmd block handshake support.
192 malo_hal_waitforcmd(struct malo_hal *mh, uint16_t cmd)
198 if (mh->mh_cmdbuf[0] == le16toh(cmd))
209 malo_hal_execute_cmd(struct malo_hal *mh, unsigned short cmd)
215 device_printf(mh->mh_dev, "firmware hung, skipping cmd 0x%x\n",
216 cmd);
227 if (!malo_hal_waitforcmd(mh, cmd | 0x8000)) {
229 "timeout waiting for f/w cmd 0x%x\n", cmd);
243 struct malo_cmd_caltable *cmd;
248 _CMD_SETUP(cmd, struct malo_cmd_caltable, MALO_HOSTCMD_GET_CALTABLE);
249 cmd->annex = annex;
250 cmd->index = index;
253 if (ret == 0 && cmd->caltbl[0] != annex && annex != 0 && annex != 255)
541 * Return "hw specs". Note this must be the first cmd MUST be done after
547 struct malo_cmd_get_hwspec *cmd;
552 _CMD_SETUP(cmd, struct malo_cmd_get_hwspec, MALO_HOSTCMD_GET_HW_SPEC);
553 memset(&cmd->permaddr[0], 0xff, IEEE80211_ADDR_LEN);
554 cmd->ul_fw_awakecookie = htole32((unsigned int)mh->mh_cmdaddr + 2048);
558 IEEE80211_ADDR_COPY(hw->macaddr, cmd->permaddr);
559 hw->wcbbase[0] = le32toh(cmd->wcbbase0) & 0x0000ffff;
560 hw->wcbbase[1] = le32toh(cmd->wcbbase1) & 0x0000ffff;
561 hw->wcbbase[2] = le32toh(cmd->wcbbase2) & 0x0000ffff;
562 hw->wcbbase[3] = le32toh(cmd->wcbbase3) & 0x0000ffff;
563 hw->rxdesc_read = le32toh(cmd->rxpdrd_ptr)& 0x0000ffff;
564 hw->rxdesc_write = le32toh(cmd->rxpdwr_ptr)& 0x0000ffff;
565 hw->regioncode = le16toh(cmd->regioncode) & 0x00ff;
566 hw->fw_releasenum = le32toh(cmd->fw_releasenum);
567 hw->maxnum_wcb = le16toh(cmd->num_wcb);
568 hw->maxnum_mcaddr = le16toh(cmd->num_mcastaddr);
569 hw->num_antenna = le16toh(cmd->num_antenna);
570 hw->hwversion = cmd->version;
571 hw->hostinterface = cmd->hostif;
598 struct malo_cmd_rf_antenna *cmd;
606 _CMD_SETUP(cmd, struct malo_cmd_rf_antenna,
608 cmd->action = htole16(dirset);
613 cmd->mode = htole16(ant);
625 * XXX preamble installed after set fixed rate cmd
631 struct malo_cmd_radio_control *cmd;
636 _CMD_SETUP(cmd, struct malo_cmd_radio_control,
638 cmd->action = htole16(MALO_HOSTCMD_ACT_GEN_SET);
640 cmd->control = 0;
642 cmd->control = htole16(preamble);
643 cmd->radio_on = htole16(onoff);
670 struct malo_cmd_fw_set_rf_channel *cmd;
675 _CMD_SETUP(cmd, struct malo_cmd_fw_set_rf_channel,
677 cmd->action = htole16(MALO_HOSTCMD_ACT_GEN_SET);
678 cmd->cur_channel = chan->channel;
690 struct malo_cmd_rf_tx_power *cmd;
698 _CMD_SETUP(cmd, struct malo_cmd_rf_tx_power,
700 cmd->action = htole16(MALO_HOSTCMD_ACT_GEN_SET_LIST);
704 cmd->power_levellist[i] = htole16(pow);
716 /* XXX need host cmd */
724 struct malo_cmd_fw_set_aid *cmd;
729 _CMD_SETUP(cmd, struct malo_cmd_fw_set_aid,
731 cmd->cmdhdr.seqnum = 1;
732 cmd->associd = htole16(associd);
733 IEEE80211_ADDR_COPY(&cmd->macaddr[0], bssid);
778 * Callback from the driver on a cmd done interrupt. Nothing to do right
779 * now as we spin waiting for cmd completion.
790 struct malo_cmd_prescan *cmd;
795 _CMD_SETUP(cmd, struct malo_cmd_prescan, MALO_HOSTCMD_SET_PRE_SCAN);
796 cmd->cmdhdr.seqnum = 1;
808 struct malo_cmd_postscan *cmd;
813 _CMD_SETUP(cmd, struct malo_cmd_postscan, MALO_HOSTCMD_SET_POST_SCAN);
814 cmd->cmdhdr.seqnum = 1;
815 cmd->isibss = htole32(ibsson);
816 IEEE80211_ADDR_COPY(&cmd->bssid[0], macaddr);
829 struct malo_cmd_fw_setslot *cmd;
833 _CMD_SETUP(cmd, struct malo_cmd_fw_setslot, MALO_HOSTCMD_SET_SLOT);
834 cmd->action = htole16(MALO_HOSTCMD_ACT_GEN_SET);
835 cmd->slot = (is_short == 1 ? 1 : 0);
848 struct malo_cmd_set_rate *cmd;
852 _CMD_SETUP(cmd, struct malo_cmd_set_rate, MALO_HOSTCMD_SET_RATE);
853 cmd->aprates[0] = 2;
854 cmd->aprates[1] = 4;
855 cmd->aprates[2] = 11;
856 cmd->aprates[3] = 22;
858 cmd->aprates[4] = 0; /* XXX reserved? */
859 cmd->aprates[5] = 12;
860 cmd->aprates[6] = 18;
861 cmd->aprates[7] = 24;
862 cmd->aprates[8] = 36;
863 cmd->aprates[9] = 48;
864 cmd->aprates[10] = 72;
865 cmd->aprates[11] = 96;
866 cmd->aprates[12] = 108;
872 if (cmd->aprates[i] == rate) {
873 cmd->rateindex = i;
874 cmd->dataratetype = 1;
890 struct malo_cmd_mcast *cmd;
898 _CMD_SETUP(cmd, struct malo_cmd_mcast, MALO_HOSTCMD_MAC_MULTICAST_ADR);
899 memcpy(cmd->maclist, macs, nmc * IEEE80211_ADDR_LEN);
900 cmd->numaddr = htole16(nmc);
901 cmd->action = htole16(0xffff);