forked from rubenslte/android_kernel_samsung_msm8226
drivers: input: Fix DVFS Errors
Signed-off-by: zeroblade1984 <zeroblade1984@gmail.com> Signed-off-by: Jackeagle <jackeagle102@gmail.com> Change-Id: I0fa8531917d09cfb08d19d27ac912a9723a92d44
This commit is contained in:
committed by
Francescodario Cuzzocrea
parent
e8357f64b9
commit
761db8f8c5
@@ -354,6 +354,7 @@ endif
|
||||
# warnings and causes the build to stop upon encountering them.
|
||||
CC = $(srctree)/scripts/gcc-wrapper.py $(REAL_CC)
|
||||
|
||||
|
||||
CHECKFLAGS := -D__linux__ -Dlinux -D__STDC__ -Dunix -D__unix__ \
|
||||
-Wbitwise -Wno-return-void $(CF)
|
||||
CFLAGS_MODULE =
|
||||
|
||||
@@ -421,6 +421,7 @@ static struct attribute_group gpio_keys_attr_group = {
|
||||
.attrs = gpio_keys_attrs,
|
||||
};
|
||||
|
||||
#ifdef CONFIG_SEC_DVFS
|
||||
#ifdef KEY_BOOSTER
|
||||
static void gpio_key_change_dvfs_lock(struct work_struct *work)
|
||||
{
|
||||
@@ -494,6 +495,7 @@ static int gpio_key_init_dvfs(struct gpio_button_data *bdata)
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
|
||||
static void gpio_keys_gpio_report_event(struct gpio_button_data *bdata)
|
||||
{
|
||||
@@ -526,12 +528,14 @@ static void gpio_keys_gpio_work_func(struct work_struct *work)
|
||||
int state = (gpio_get_value_cansleep(button->gpio) ? 1 : 0) ^ button->active_low;
|
||||
#endif
|
||||
gpio_keys_gpio_report_event(bdata);
|
||||
#ifdef CONFIG_SEC_DVFS
|
||||
#ifdef KEY_BOOSTER
|
||||
if (button->code == KEY_HOMEPAGE)
|
||||
{
|
||||
gpio_key_set_dvfs_lock(bdata, !!state);
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
|
||||
static void gpio_keys_gpio_timer(unsigned long _data)
|
||||
@@ -1495,12 +1499,14 @@ static int __devinit gpio_keys_probe(struct platform_device *pdev)
|
||||
error = gpio_keys_setup_key(pdev, input, bdata, button);
|
||||
if (error)
|
||||
goto fail2;
|
||||
#ifdef CONFIG_SEC_DVFS
|
||||
#ifdef KEY_BOOSTER
|
||||
error = gpio_key_init_dvfs(bdata);
|
||||
if (error < 0) {
|
||||
dev_err(dev, "Fail get dvfs level for touch booster\n");
|
||||
goto fail2;
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
if (button->wakeup)
|
||||
wakeup = 1;
|
||||
|
||||
Reference in New Issue
Block a user