Commit cad9d9b1 authored by Holger Schurig's avatar Holger Schurig Committed by David S. Miller

[PATCH] libertas: remove adapter->txrate

The value of txrate was only set by a CMD_802_11_TX_RATE_QUERY command,
but there was no code in the driver that ever issued this command.
Signed-off-by: default avatarHolger Schurig <hs4233@mail.mn-solutions.de>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent b20c5207
...@@ -1368,13 +1368,6 @@ int libertas_prepare_and_send_command(wlan_private * priv, ...@@ -1368,13 +1368,6 @@ int libertas_prepare_and_send_command(wlan_private * priv,
S_DS_GEN); S_DS_GEN);
ret = 0; ret = 0;
break; break;
case CMD_802_11_TX_RATE_QUERY:
cmdptr->command = cpu_to_le16(CMD_802_11_TX_RATE_QUERY);
cmdptr->size = cpu_to_le16(sizeof(struct cmd_tx_rate_query) +
S_DS_GEN);
adapter->txrate = 0;
ret = 0;
break;
default: default:
lbs_deb_host("PREP_CMD: unknown command 0x%04x\n", cmd_no); lbs_deb_host("PREP_CMD: unknown command 0x%04x\n", cmd_no);
ret = -1; ret = -1;
......
...@@ -702,9 +702,6 @@ static inline int handle_cmd_response(u16 respcmd, ...@@ -702,9 +702,6 @@ static inline int handle_cmd_response(u16 respcmd,
memcpy(adapter->cur_cmd->pdata_buf, &resp->params.mesh, memcpy(adapter->cur_cmd->pdata_buf, &resp->params.mesh,
sizeof(resp->params.mesh)); sizeof(resp->params.mesh));
break; break;
case CMD_RET(CMD_802_11_TX_RATE_QUERY):
priv->adapter->txrate = resp->params.txrate.txrate;
break;
default: default:
lbs_deb_host("CMD_RESP: unknown cmd response 0x%04x\n", lbs_deb_host("CMD_RESP: unknown cmd response 0x%04x\n",
resp->command); resp->command);
......
...@@ -376,7 +376,6 @@ struct _wlan_adapter { ...@@ -376,7 +376,6 @@ struct _wlan_adapter {
struct cmd_ds_802_11_get_log logmsg; struct cmd_ds_802_11_get_log logmsg;
u16 txrate;
u32 linkmode; u32 linkmode;
u32 radiomode; u32 radiomode;
u8 fw_ready; u8 fw_ready;
......
...@@ -949,7 +949,7 @@ static struct iw_statistics *wlan_get_wireless_stats(struct net_device *dev) ...@@ -949,7 +949,7 @@ static struct iw_statistics *wlan_get_wireless_stats(struct net_device *dev)
priv->wstats.discard.misc = le16_to_cpu(adapter->logmsg.ackfailure); priv->wstats.discard.misc = le16_to_cpu(adapter->logmsg.ackfailure);
/* Calculate quality */ /* Calculate quality */
priv->wstats.qual.qual = min_t(u32, quality, 100); priv->wstats.qual.qual = min_t(u8, quality, 100);
priv->wstats.qual.updated = IW_QUAL_ALL_UPDATED | IW_QUAL_DBM; priv->wstats.qual.updated = IW_QUAL_ALL_UPDATED | IW_QUAL_DBM;
stats_valid = 1; stats_valid = 1;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment