summaryrefslogtreecommitdiffstats
path: root/bcm4329
diff options
context:
space:
mode:
authorDmitry Shmidt <dimitrysh@google.com>2010-10-05 17:32:04 -0700
committerDmitry Shmidt <dimitrysh@google.com>2010-10-05 17:32:04 -0700
commit900f1defbe1f39ca6af8356521961c249174f304 (patch)
tree51c9503a583b8128656cf6708a9f939c55973975 /bcm4329
parentfa410a88bd8b3abf6db97b6476dda0bc7f1b5e0a (diff)
downloadhardware_broadcom_wlan-900f1defbe1f39ca6af8356521961c249174f304.zip
hardware_broadcom_wlan-900f1defbe1f39ca6af8356521961c249174f304.tar.gz
hardware_broadcom_wlan-900f1defbe1f39ca6af8356521961c249174f304.tar.bz2
bcm4329: Sync with current kernel version
Change-Id: I9b8deeeedc5e125e6d1f171d9350c06b14b8aa75 Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Diffstat (limited to 'bcm4329')
-rw-r--r--bcm4329/src/dhd/sys/dhd_linux.c12
-rw-r--r--bcm4329/src/dhd/sys/dhd_sdio.c7
-rw-r--r--bcm4329/src/shared/linux_osl.c4
3 files changed, 14 insertions, 9 deletions
diff --git a/bcm4329/src/dhd/sys/dhd_linux.c b/bcm4329/src/dhd/sys/dhd_linux.c
index 2eff469..f687b31 100644
--- a/bcm4329/src/dhd/sys/dhd_linux.c
+++ b/bcm4329/src/dhd/sys/dhd_linux.c
@@ -1379,7 +1379,6 @@ dhd_watchdog_thread(void *data)
/* Run until signal received */
while (1) {
if (down_interruptible (&dhd->watchdog_sem) == 0) {
- dhd_os_wake_lock(&dhd->pub);
if (dhd->pub.dongle_reset == FALSE) {
/* Call the bus module watchdog */
@@ -1387,6 +1386,11 @@ dhd_watchdog_thread(void *data)
}
/* Count the tick for reference */
dhd->pub.tickcnt++;
+
+ /* Reschedule the watchdog */
+ if (dhd->wd_timer_valid)
+ mod_timer(&dhd->timer, jiffies + dhd_watchdog_ms * HZ / 1000);
+
dhd_os_wake_unlock(&dhd->pub);
}
else
@@ -1404,12 +1408,6 @@ dhd_watchdog(ulong data)
dhd_os_wake_lock(&dhd->pub);
if (dhd->watchdog_pid >= 0) {
up(&dhd->watchdog_sem);
-
- /* Reschedule the watchdog */
- if (dhd->wd_timer_valid) {
- mod_timer(&dhd->timer, jiffies + dhd_watchdog_ms * HZ / 1000);
- }
- dhd_os_wake_unlock(&dhd->pub);
return;
}
diff --git a/bcm4329/src/dhd/sys/dhd_sdio.c b/bcm4329/src/dhd/sys/dhd_sdio.c
index bd73556..ff1bded 100644
--- a/bcm4329/src/dhd/sys/dhd_sdio.c
+++ b/bcm4329/src/dhd/sys/dhd_sdio.c
@@ -5808,6 +5808,8 @@ dhd_bus_devreset(dhd_pub_t *dhdp, uint8 flag)
dhd_os_proto_unblock(dhdp);
/* Expect app to have torn down any connection before calling */
/* Stop the bus, disable F2 */
+ dhd_os_sdlock(dhdp);
+
dhd_bus_stop(bus, FALSE);
/* Clean tx/rx buffer pointers, detach from the dongle */
@@ -5816,6 +5818,8 @@ dhd_bus_devreset(dhd_pub_t *dhdp, uint8 flag)
bus->dhd->dongle_reset = TRUE;
bus->dhd->up = FALSE;
+ dhd_os_sdunlock(dhdp);
+
DHD_TRACE(("%s: WLAN OFF DONE\n", __FUNCTION__));
/* App can now remove power from device */
} else
@@ -5827,6 +5831,8 @@ dhd_bus_devreset(dhd_pub_t *dhdp, uint8 flag)
if (bus->dhd->dongle_reset) {
/* Turn on WLAN */
+ dhd_os_sdlock(dhdp);
+
/* Reset SD client */
bcmsdh_reset(bus->sdh);
@@ -5858,6 +5864,7 @@ dhd_bus_devreset(dhd_pub_t *dhdp, uint8 flag)
bcmerror = BCME_SDIO_ERROR;
} else
bcmerror = BCME_SDIO_ERROR;
+ dhd_os_sdunlock(dhdp);
} else {
bcmerror = BCME_NOTDOWN;
DHD_ERROR(("%s: Set DEVRESET=FALSE invoked when device is on\n",
diff --git a/bcm4329/src/shared/linux_osl.c b/bcm4329/src/shared/linux_osl.c
index 6383e00..d00bd1c 100644
--- a/bcm4329/src/shared/linux_osl.c
+++ b/bcm4329/src/shared/linux_osl.c
@@ -21,7 +21,7 @@
* software in any way with any other Broadcom software provided under a license
* other than the GPL, without Broadcom's express prior written consent.
*
- * $Id: linux_osl.c,v 1.125.12.3.8.6 2009/12/09 01:29:03 Exp $
+ * $Id: linux_osl.c,v 1.125.12.3.8.7 2010/05/04 21:10:04 Exp $
*/
@@ -511,7 +511,7 @@ osl_mfree(osl_t *osh, void *addr, uint size)
#ifdef DHD_USE_STATIC_BUF
if (bcm_static_buf)
{
- if ((addr > (void *)bcm_static_buf) && ((unsigned char *)addr \
+ if ((addr > (void *)bcm_static_buf) && ((unsigned char *)addr
<= ((unsigned char *)bcm_static_buf + STATIC_BUF_TOTAL_LEN)))
{
int buf_idx = 0;