net: wireless: bcmdhd: Fix sending ctrl packet

- Schedule dpc thread to send ctrl frame if we cannot
  send ctrl packet immediately.

Change-Id: I5ae8b705a6ccddcc1f5c86b4c094342b57d26c7f
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
This commit is contained in:
Dmitry Shmidt
2012-08-28 16:17:37 -07:00
parent d7cdb87a5e
commit ddb45c7e85

View File

@@ -1375,7 +1375,13 @@ dhd_bus_txctl(struct dhd_bus *bus, uchar *msg, uint msglen)
/* Send from dpc */
bus->ctrl_frame_buf = frame;
bus->ctrl_frame_len = len;
dhd_wait_for_event(bus->dhd, &bus->ctrl_frame_stat);
if (!bus->dpc_sched) {
bus->dpc_sched = TRUE;
dhd_sched_dpc(bus->dhd);
}
if (bus->ctrl_frame_stat) {
dhd_wait_for_event(bus->dhd, &bus->ctrl_frame_stat);
}
if (bus->ctrl_frame_stat == FALSE) {
DHD_INFO(("%s: ctrl_frame_stat == FALSE\n", __FUNCTION__));
ret = 0;