Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 235605
b: refs/heads/master
c: e685676
h: refs/heads/master
i:
  235603: 368de30
v: v3
  • Loading branch information
Justin P. Mattock authored and Greg Kroah-Hartman committed Jan 20, 2011
1 parent b897d85 commit b8ed426
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 52 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: 2ae44d64b770832451b112c6e3d4d5ab0aef66c2
refs/heads/master: e6856764dc677aed6c1edb317f60b35194913b0d
23 changes: 0 additions & 23 deletions trunk/drivers/staging/ath6kl/os/linux/ar6000_android.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@
#include <linux/vmalloc.h>
#include <linux/fs.h>

#ifdef CONFIG_HAS_WAKELOCK
#include <linux/wakelock.h>
#endif
#ifdef CONFIG_HAS_EARLYSUSPEND
#include <linux/earlysuspend.h>
#endif
Expand All @@ -44,11 +41,6 @@ extern int bmienable;
extern struct net_device *ar6000_devices[];
extern char ifname[];

#ifdef CONFIG_HAS_WAKELOCK
extern struct wake_lock ar6k_wow_wake_lock;
struct wake_lock ar6k_init_wake_lock;
#endif

const char def_ifname[] = "wlan0";
module_param_string(fwpath, fwpath, sizeof(fwpath), 0644);
module_param(enablelogcat, uint, 0644);
Expand Down Expand Up @@ -280,14 +272,8 @@ void android_release_firmware(const struct firmware *firmware)
static A_STATUS ar6000_android_avail_ev(void *context, void *hif_handle)
{
A_STATUS ret;
#ifdef CONFIG_HAS_WAKELOCK
wake_lock(&ar6k_init_wake_lock);
#endif
ar6000_enable_mmchost_detect_change(0);
ret = ar6000_avail_ev_p(context, hif_handle);
#ifdef CONFIG_HAS_WAKELOCK
wake_unlock(&ar6k_init_wake_lock);
#endif
return ret;
}

Expand Down Expand Up @@ -328,9 +314,6 @@ void android_module_init(OSDRV_CALLBACKS *osdrvCallbacks)
bmienable = 1;
if (ifname[0] == '\0')
strcpy(ifname, def_ifname);
#ifdef CONFIG_HAS_WAKELOCK
wake_lock_init(&ar6k_init_wake_lock, WAKE_LOCK_SUSPEND, "ar6k_init");
#endif
#ifdef CONFIG_HAS_EARLYSUSPEND
ar6k_early_suspend.suspend = android_early_suspend;
ar6k_early_suspend.resume = android_late_resume;
Expand All @@ -348,9 +331,6 @@ void android_module_exit(void)
{
#ifdef CONFIG_HAS_EARLYSUSPEND
unregister_early_suspend(&ar6k_early_suspend);
#endif
#ifdef CONFIG_HAS_WAKELOCK
wake_lock_destroy(&ar6k_init_wake_lock);
#endif
ar6000_enable_mmchost_detect_change(1);
}
Expand Down Expand Up @@ -395,9 +375,6 @@ void android_ar6k_check_wow_status(AR_SOFTC_T *ar, struct sk_buff *skb, A_BOOL i
}
if (needWake) {
/* keep host wake up if there is any event and packate comming in*/
#ifdef CONFIG_HAS_WAKELOCK
wake_lock_timeout(&ar6k_wow_wake_lock, 3*HZ);
#endif
if (wowledon) {
char buf[32];
int len = sprintf(buf, "on");
Expand Down
28 changes: 0 additions & 28 deletions trunk/drivers/staging/ath6kl/os/linux/ar6000_pm.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,23 +30,12 @@
#include <linux/platform_device.h>
#include "wlan_config.h"

#ifdef CONFIG_HAS_WAKELOCK
#include <linux/wakelock.h>
#endif

#define WOW_ENABLE_MAX_INTERVAL 0
#define WOW_SET_SCAN_PARAMS 0

extern unsigned int wmitimeout;
extern wait_queue_head_t arEvent;

#ifdef CONFIG_PM
#ifdef CONFIG_HAS_WAKELOCK
struct wake_lock ar6k_suspend_wake_lock;
struct wake_lock ar6k_wow_wake_lock;
#endif
#endif /* CONFIG_PM */

#ifdef ANDROID_ENV
extern void android_ar6k_check_wow_status(AR_SOFTC_T *ar, struct sk_buff *skb, A_BOOL isEvent);
#endif
Expand Down Expand Up @@ -89,9 +78,6 @@ static void ar6000_wow_resume(AR_SOFTC_T *ar)
A_UINT16 bg_period = (ar->scParams.bg_period==0) ? 60 : ar->scParams.bg_period;
WMI_SET_HOST_SLEEP_MODE_CMD hostSleepMode = {TRUE, FALSE};
ar->arWowState = WLAN_WOW_STATE_NONE;
#ifdef CONFIG_HAS_WAKELOCK
wake_lock_timeout(&ar6k_wow_wake_lock, 3*HZ);
#endif
if (wmi_set_host_sleep_mode_cmd(ar->arWmi, &hostSleepMode)!=A_OK) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR,("Fail to setup restore host awake\n"));
}
Expand Down Expand Up @@ -267,9 +253,6 @@ A_STATUS ar6000_resume_ev(void *context)
AR_SOFTC_T *ar = (AR_SOFTC_T *)context;
A_UINT16 powerState = ar->arWlanPowerState;

#ifdef CONFIG_HAS_WAKELOCK
wake_lock(&ar6k_suspend_wake_lock);
#endif
AR_DEBUG_PRINTF(ATH_DEBUG_PM, ("%s: enter previous state %d wowState %d\n", __func__, powerState, ar->arWowState));
switch (powerState) {
case WLAN_POWER_STATE_WOW:
Expand All @@ -287,9 +270,6 @@ A_STATUS ar6000_resume_ev(void *context)
AR_DEBUG_PRINTF(ATH_DEBUG_ERR, ("Strange SDIO bus power mode!!\n"));
break;
}
#ifdef CONFIG_HAS_WAKELOCK
wake_unlock(&ar6k_suspend_wake_lock);
#endif
return A_OK;
}

Expand Down Expand Up @@ -704,10 +684,6 @@ void ar6000_pm_init()
{
A_REGISTER_MODULE_DEBUG_INFO(pm);
#ifdef CONFIG_PM
#ifdef CONFIG_HAS_WAKELOCK
wake_lock_init(&ar6k_suspend_wake_lock, WAKE_LOCK_SUSPEND, "ar6k_suspend");
wake_lock_init(&ar6k_wow_wake_lock, WAKE_LOCK_SUSPEND, "ar6k_wow");
#endif
/*
* Register ar6000_pm_device into system.
* We should also add platform_device into the first item of array
Expand All @@ -723,9 +699,5 @@ void ar6000_pm_exit()
{
#ifdef CONFIG_PM
platform_driver_unregister(&ar6000_pm_device);
#ifdef CONFIG_HAS_WAKELOCK
wake_lock_destroy(&ar6k_suspend_wake_lock);
wake_lock_destroy(&ar6k_wow_wake_lock);
#endif
#endif /* CONFIG_PM */
}

0 comments on commit b8ed426

Please sign in to comment.