Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 195219
b: refs/heads/master
c: a6a0345
h: refs/heads/master
i:
  195217: ca85d8f
  195215: 344abc5
v: v3
  • Loading branch information
Johannes Berg authored and Reinette Chatre committed May 10, 2010
1 parent bb3f76b commit d7e382c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 156b70d17ce85778341cfb2a90c5bcb14b28ab3f
refs/heads/master: a6a0345c837346d1b74f4907d4747e6c1053a99f
16 changes: 8 additions & 8 deletions trunk/drivers/net/wireless/iwlwifi/iwl-sta.c
Original file line number Diff line number Diff line change
Expand Up @@ -407,13 +407,12 @@ int iwl_add_station_common(struct iwl_priv *priv, const u8 *addr,
}
EXPORT_SYMBOL(iwl_add_station_common);

static struct iwl_link_quality_cmd *iwl_sta_init_lq(struct iwl_priv *priv,
u8 sta_id)
static struct iwl_link_quality_cmd *iwl_sta_alloc_lq(struct iwl_priv *priv,
u8 sta_id)
{
int i, r;
struct iwl_link_quality_cmd *link_cmd;
u32 rate_flags;
int ret = 0;

link_cmd = kzalloc(sizeof(struct iwl_link_quality_cmd), GFP_KERNEL);
if (!link_cmd) {
Expand Down Expand Up @@ -459,10 +458,6 @@ static struct iwl_link_quality_cmd *iwl_sta_init_lq(struct iwl_priv *priv,

link_cmd->sta_id = sta_id;

ret = iwl_send_lq_cmd(priv, link_cmd, CMD_SYNC, true);
if (ret)
IWL_ERR(priv, "Link quality command failed (%d)\n", ret);

return link_cmd;
}

Expand Down Expand Up @@ -493,12 +488,17 @@ int iwl_add_local_station(struct iwl_priv *priv, const u8 *addr, bool init_rs)

if (init_rs) {
/* Set up default rate scaling table in device's station table */
link_cmd = iwl_sta_init_lq(priv, sta_id);
link_cmd = iwl_sta_alloc_lq(priv, sta_id);
if (!link_cmd) {
IWL_ERR(priv, "Unable to initialize rate scaling for station %pM.\n",
addr);
return -ENOMEM;
}

ret = iwl_send_lq_cmd(priv, link_cmd, CMD_SYNC, true);
if (ret)
IWL_ERR(priv, "Link quality command failed (%d)\n", ret);

spin_lock_irqsave(&priv->sta_lock, flags);
priv->stations[sta_id].lq = link_cmd;
spin_unlock_irqrestore(&priv->sta_lock, flags);
Expand Down

0 comments on commit d7e382c

Please sign in to comment.