Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 266563
b: refs/heads/master
c: 9809d8e
h: refs/heads/master
i:
  266561: 08618ae
  266559: 1c64107
v: v3
  • Loading branch information
Jouni Malinen authored and Kalle Valo committed Aug 31, 2011
1 parent bea9fdd commit d51cd79
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 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: a0df5db15b432cd49319254132fda80cb3081ad6
refs/heads/master: 9809d8ef274bb53f47998bbc401efcbb10226893
15 changes: 12 additions & 3 deletions trunk/drivers/net/wireless/ath/ath6kl/wmi.c
Original file line number Diff line number Diff line change
Expand Up @@ -552,17 +552,26 @@ static int ath6kl_wmi_p2p_capabilities_event_rx(u8 *datap, int len)
return 0;
}

static int ath6kl_wmi_rx_action_event_rx(u8 *datap, int len)
static int ath6kl_wmi_rx_action_event_rx(struct wmi *wmi, u8 *datap, int len)
{
struct wmi_rx_action_event *ev;
u32 freq;
u16 dlen;
struct ath6kl *ar = wmi->parent_dev;

if (len < sizeof(*ev))
return -EINVAL;

ev = (struct wmi_rx_action_event *) datap;
freq = le32_to_cpu(ev->freq);
dlen = le16_to_cpu(ev->len);
ath6kl_dbg(ATH6KL_DBG_WMI, "rx_action: len=%u\n", dlen);
if (datap + len < ev->data + dlen) {
ath6kl_err("invalid wmi_rx_action_event: "
"len=%d dlen=%u\n", len, dlen);
return -EINVAL;
}
ath6kl_dbg(ATH6KL_DBG_WMI, "rx_action: len=%u freq=%u\n", dlen, freq);
cfg80211_rx_mgmt(ar->net_dev, freq, ev->data, dlen, GFP_ATOMIC);

return 0;
}
Expand Down Expand Up @@ -3086,7 +3095,7 @@ int ath6kl_wmi_control_rx(struct wmi *wmi, struct sk_buff *skb)
break;
case WMI_RX_ACTION_EVENTID:
ath6kl_dbg(ATH6KL_DBG_WMI, "WMI_RX_ACTION_EVENTID\n");
ret = ath6kl_wmi_rx_action_event_rx(datap, len);
ret = ath6kl_wmi_rx_action_event_rx(wmi, datap, len);
break;
case WMI_P2P_INFO_EVENTID:
ath6kl_dbg(ATH6KL_DBG_WMI, "WMI_P2P_INFO_EVENTID\n");
Expand Down

0 comments on commit d51cd79

Please sign in to comment.