Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 277821
b: refs/heads/master
c: 63af633
h: refs/heads/master
i:
  277819: af3c8ce
v: v3
  • Loading branch information
Yogesh Ashok Powar authored and John W. Linville committed Nov 11, 2011
1 parent 5c83987 commit 647ef0e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 11 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: ab581472c01d8533a801c96c00575694739cb94c
refs/heads/master: 63af63330f4c8b4fdcc13dec082dea3b81d53b0a
2 changes: 1 addition & 1 deletion trunk/drivers/net/wireless/mwifiex/fw.h
Original file line number Diff line number Diff line change
Expand Up @@ -673,7 +673,7 @@ struct host_cmd_ds_802_11_ad_hoc_start {
union ieee_types_phy_param_set phy_param_set;
u16 reserved1;
__le16 cap_info_bitmap;
u8 DataRate[HOSTCMD_SUPPORTED_RATES];
u8 data_rate[HOSTCMD_SUPPORTED_RATES];
} __packed;

struct host_cmd_ds_802_11_ad_hoc_result {
Expand Down
17 changes: 8 additions & 9 deletions trunk/drivers/net/wireless/mwifiex/join.c
Original file line number Diff line number Diff line change
Expand Up @@ -837,8 +837,8 @@ mwifiex_cmd_802_11_ad_hoc_start(struct mwifiex_private *priv,
bss_desc->privacy = MWIFIEX_802_11_PRIV_FILTER_ACCEPT_ALL;
}

memset(adhoc_start->DataRate, 0, sizeof(adhoc_start->DataRate));
mwifiex_get_active_data_rates(priv, adhoc_start->DataRate);
memset(adhoc_start->data_rate, 0, sizeof(adhoc_start->data_rate));
mwifiex_get_active_data_rates(priv, adhoc_start->data_rate);
if ((adapter->adhoc_start_band & BAND_G) &&
(priv->curr_pkt_filter & HostCmd_ACT_MAC_ADHOC_G_PROTECTION_ON)) {
if (mwifiex_send_cmd_async(priv, HostCmd_CMD_MAC_CONTROL,
Expand All @@ -850,20 +850,19 @@ mwifiex_cmd_802_11_ad_hoc_start(struct mwifiex_private *priv,
}
}
/* Find the last non zero */
for (i = 0; i < sizeof(adhoc_start->DataRate) &&
adhoc_start->DataRate[i];
i++)
;
for (i = 0; i < sizeof(adhoc_start->data_rate); i++)
if (!adhoc_start->data_rate[i])
break;

priv->curr_bss_params.num_of_rates = i;

/* Copy the ad-hoc creating rates into Current BSS rate structure */
memcpy(&priv->curr_bss_params.data_rates,
&adhoc_start->DataRate, priv->curr_bss_params.num_of_rates);
&adhoc_start->data_rate, priv->curr_bss_params.num_of_rates);

dev_dbg(adapter->dev, "info: ADHOC_S_CMD: rates=%02x %02x %02x %02x\n",
adhoc_start->DataRate[0], adhoc_start->DataRate[1],
adhoc_start->DataRate[2], adhoc_start->DataRate[3]);
adhoc_start->data_rate[0], adhoc_start->data_rate[1],
adhoc_start->data_rate[2], adhoc_start->data_rate[3]);

dev_dbg(adapter->dev, "info: ADHOC_S_CMD: AD-HOC Start command is ready\n");

Expand Down

0 comments on commit 647ef0e

Please sign in to comment.