mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-09 13:49:24 -04:00
Capri:Add compability of chipone driver
WHY: Chipone fps driver should be working on different Android version WHAT:Add compability support in chipone driver Change-Id: Ic3d3cf0fafd11b5dbd600170ca0044bc4c70b3a9 Reviewed-on: https://gerrit.mot.com/1758615 SLTApproved: Slta Waiver SME-Granted: SME Approvals Granted Tested-by: Jira Key Reviewed-by: liujian <liujian24@lenovo.com> Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com> Submit-Approved: Jira Key
This commit is contained in:
parent
50ec4655fb
commit
6fbd18d1d5
2 changed files with 6 additions and 6 deletions
|
|
@ -631,7 +631,7 @@ static int fpsensor_probe(struct platform_device *pdev)
|
|||
}
|
||||
init_waitqueue_head(&fpsensor_dev->wq_irq_return);
|
||||
#if FPSENSOR_WAKEUP_TYPE == FPSENSOR_WAKEUP_SOURCE
|
||||
wakeup_source_init(&g_ttw_wl, "fpsensor_ttw_wl");
|
||||
wakeup_source_init_internal(&g_ttw_wl, "fpsensor_ttw_wl");
|
||||
#else
|
||||
wake_lock_init(&g_ttw_wl, WAKE_LOCK_SUSPEND, "fpsensor_ttw_wl");
|
||||
#endif
|
||||
|
|
@ -667,7 +667,7 @@ static int fpsensor_remove(struct platform_device *pdev)
|
|||
fpsensor_gpio_free(fpsensor_dev);
|
||||
fpsensor_dev_cleanup(fpsensor_dev);
|
||||
#if FPSENSOR_WAKEUP_TYPE == FPSENSOR_WAKEUP_SOURCE
|
||||
wakeup_source_trash(&g_ttw_wl);
|
||||
wakeup_source_trash_internal(&g_ttw_wl);
|
||||
#else
|
||||
wake_lock_destroy(&g_ttw_wl);
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ struct wake_lock {
|
|||
struct wakeup_source ws;
|
||||
};
|
||||
|
||||
static inline void wakeup_source_init(struct wakeup_source *ws,
|
||||
static inline void wakeup_source_init_internal(struct wakeup_source *ws,
|
||||
const char *name)
|
||||
{
|
||||
if(ws){
|
||||
|
|
@ -47,10 +47,10 @@ static inline void wakeup_source_init(struct wakeup_source *ws,
|
|||
static inline void wake_lock_init(struct wake_lock *lock, int type,
|
||||
const char *name)
|
||||
{
|
||||
wakeup_source_init(&lock->ws, name);
|
||||
wakeup_source_init_internal(&lock->ws, name);
|
||||
}
|
||||
|
||||
static inline void wakeup_source_trash(struct wakeup_source *ws)
|
||||
static inline void wakeup_source_trash_internal(struct wakeup_source *ws)
|
||||
{
|
||||
wakeup_source_remove(ws);
|
||||
if(!ws)
|
||||
|
|
@ -60,7 +60,7 @@ static inline void wakeup_source_trash(struct wakeup_source *ws)
|
|||
|
||||
static inline void wake_lock_destroy(struct wake_lock *lock)
|
||||
{
|
||||
wakeup_source_trash(&lock->ws);
|
||||
wakeup_source_trash_internal(&lock->ws);
|
||||
}
|
||||
|
||||
static inline void wake_lock(struct wake_lock *lock)
|
||||
|
|
|
|||
Loading…
Reference in a new issue