return 0;
}
-static int wlan_cmd_802_11_rf_antenna(wlan_private * priv,
- struct cmd_ds_command *cmd,
- u16 cmd_action, void *pdata_buf)
-{
- struct cmd_ds_802_11_rf_antenna *rant = &cmd->params.rant;
-
- lbs_deb_enter(LBS_DEB_CMD);
- cmd->command = cpu_to_le16(CMD_802_11_RF_ANTENNA);
- cmd->size = cpu_to_le16(sizeof(struct cmd_ds_802_11_rf_antenna) +
- S_DS_GEN);
-
- rant->action = cpu_to_le16(cmd_action);
- if ((cmd_action == CMD_ACT_SET_RX) || (cmd_action == CMD_ACT_SET_TX)) {
- rant->antennamode = cpu_to_le16((u16) (*(u32 *) pdata_buf));
- }
-
- lbs_deb_leave(LBS_DEB_CMD);
- return 0;
-}
-
static int wlan_cmd_802_11_rate_adapt_rateset(wlan_private * priv,
struct cmd_ds_command *cmd,
u16 cmd_action)
ret = wlan_cmd_802_11_radio_control(priv, cmdptr, cmd_action);
break;
- case CMD_802_11_RF_ANTENNA:
- ret = wlan_cmd_802_11_rf_antenna(priv, cmdptr,
- cmd_action, pdata_buf);
- break;
-
case CMD_802_11_DATA_RATE:
ret = wlan_cmd_802_11_data_rate(priv, cmdptr, cmd_action);
break;
return 0;
}
-static int wlan_ret_802_11_rf_antenna(wlan_private * priv,
- struct cmd_ds_command *resp)
-{
- struct cmd_ds_802_11_rf_antenna *pAntenna = &resp->params.rant;
- wlan_adapter *adapter = priv->adapter;
- u16 action = le16_to_cpu(pAntenna->action);
-
- lbs_deb_enter(LBS_DEB_CMD);
- if (action == CMD_ACT_GET_RX)
- adapter->rxantennamode = le16_to_cpu(pAntenna->antennamode);
-
- if (action == CMD_ACT_GET_TX)
- adapter->txantennamode = le16_to_cpu(pAntenna->antennamode);
-
- lbs_deb_cmd("RF_ANT_RESP: action 0x%x, mode 0x%04x\n",
- action, le16_to_cpu(pAntenna->antennamode));
-
- lbs_deb_leave(LBS_DEB_CMD);
- return 0;
-}
-
static int wlan_ret_802_11_rate_adapt_rateset(wlan_private * priv,
struct cmd_ds_command *resp)
{
spin_unlock_irqrestore(&adapter->driver_lock, flags);
break;
- case CMD_RET(CMD_802_11_RF_ANTENNA):
- ret = wlan_ret_802_11_rf_antenna(priv, resp);
- break;
case CMD_RET(CMD_MAC_MULTICAST_ADR):
case CMD_RET(CMD_MAC_CONTROL):
/** control G rates */
u8 adhoc_grate_enabled;
- u32 txantenna;
- u32 rxantenna;
-
u32 fragthsd;
u32 rtsthsd;
u8 wpa_ie[MAX_WPA_IE_LEN];
u8 wpa_ie_len;
- u16 rxantennamode;
- u16 txantennamode;
-
/** Requested Signal Strength*/
u16 bcn_avg_factor;
u16 data_avg_factor;
CMD_ACT_MAC_RX_ON | CMD_ACT_MAC_TX_ON;
adapter->radioon = RADIO_ON;
- adapter->txantenna = RF_ANTENNA_2;
- adapter->rxantenna = RF_ANTENNA_AUTO;
adapter->auto_rate = 1;
adapter->cur_rate = 0;