static void cypress_touchkey_disable_led_notification(void){ /* * reconfigure gpio for sleep mode, this has to be done * independently from the power status */ blndevdata->pdata->touchkey_sleep_onoff(TOUCHKEY_OFF); /* if touchkeys lights are not used for touchmode */ if (blndevdata->is_powering_on){ disable_touchkey_backlights(); #if 0 /* * power off the touchkey controller * This is actually not needed, the early_suspend function * should take care of powering off the touchkey controller */ blndevdata->pdata->touchkey_onoff(TOUCHKEY_OFF); #endif } #ifdef CONFIG_TOUCH_WAKE else { disable_touchkey_backlights(); } #endif }
static ssize_t blink_control_write(struct device *dev, struct device_attribute *attr, const char *buf, size_t size) { unsigned int data; if (sscanf(buf, "%u\n", &data) == 1) { if(data == 0 || data == 1) { if (bln_notification_ongoing) { pr_devel("%s: %u \n", __FUNCTION__, data); if (data == 1) { bln_blink_enabled = true; _pr_info("%s: disabling bln\n", __FUNCTION__); // remove me disable_touchkey_backlights(); } if(data == 0){ bln_blink_enabled = false; _pr_info("%s: enabling bln\n", __FUNCTION__); // remove me enable_touchkey_backlights(); } } } else _pr_info3("%s: wrong input %u\n", __FUNCTION__, data); } else _pr_info("%s: input error\n", __FUNCTION__); return size; }
static void disable_led_notification(void){ printk("%s: notification led disabled\n", __FUNCTION__); /* disable the blink state */ bln_blink_enabled = false; disable_touchkey_backlights(); /* signal led notification is disabled */ bln_notification_ongoing = false; }
static void disable_led_notification(void){ pr_info("%s: notification led disabled\n", __FUNCTION__); /* disable the blink state */ bln_blink_enabled = false; /* if touchkeys lights are not used for touchmode */ if (bln_devdata->is_powering_on){ disable_touchkey_backlights(); } /* signal led notification is disabled */ bln_notification_ongoing = false; }
static void disable_led_notification(void){ bln_blink_enabled = false; BLN_ongoing = false; printk(KERN_DEBUG "[TouchKey] BLN_ongoing set to false\n"); if( touchkey_enable == 1 ){ disable_touchkey_backlights(); if( bln_suspended ){ touchkey_deactivate(); } } }
static ssize_t blink_control_write( struct device *dev, struct device_attribute *attr, const char *buf, size_t size ){ unsigned int data; if( sscanf(buf, "%u\n", &data ) == 1 ){ if( data == 0 || data == 1 ){ if (data == 1){ bln_blink_enabled = true; disable_touchkey_backlights(); } if(data == 0){ bln_blink_enabled = false; enable_touchkey_backlights(); } } } return size; }
static void disable_led_notification(void) { _pr_info("%s: disabling notification led...\n", __FUNCTION__); if (unlikely(bln_devdata->is_dead)) return; down(&enable_sem); /* disable the blink state */ bln_blink_enabled = false; /* if touchkeys lights are not used for touchmode */ if ( bln_devdata->is_powering_on ) { disable_touchkey_backlights(); } /* signal led notification is disabled */ bln_notification_ongoing = false; up(&enable_sem); _pr_info("%s: disabled notification led\n", __FUNCTION__); }