mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-08 21:22:09 -04:00
add panel_notifier.h to mmi kernel modules area
This include file is required by panel on/off notification mechanism used in MMI products. It makes more sense to keep it locally to avoid adding it to various kernels Change-Id: Ib0bc5a7dfe08c3dbae5f7960d3298b0f65811396 Signed-off-by: Konstantin Makariev <hcv867@motorola.com> Reviewed-on: https://gerrit.mot.com/1549392 SME-Granted: SME Approvals Granted SLTApproved: Slta Waiver Tested-by: Jira Key Reviewed-by: Konstantin Makariev <kmakariev@motorola.com> Submit-Approved: Jira Key
This commit is contained in:
parent
658222e621
commit
0a6dbeff9f
1 changed files with 49 additions and 0 deletions
49
include/linux/panel_notifier.h
Normal file
49
include/linux/panel_notifier.h
Normal file
|
|
@ -0,0 +1,49 @@
|
|||
/* Copyright (c) 2016, Motorola Mobility, LLC.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License version 2 and
|
||||
* only version 2 as published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef __PANEL_NOTIFIER_H__
|
||||
#define __PANEL_NOTIFIER_H__
|
||||
|
||||
#include <linux/notifier.h>
|
||||
|
||||
enum panel_event {
|
||||
PANEL_EVENT_PRE_DISPLAY_OFF,
|
||||
PANEL_EVENT_PRE_DISPLAY_ON,
|
||||
PANEL_EVENT_DISPLAY_OFF,
|
||||
PANEL_EVENT_DISPLAY_ON,
|
||||
};
|
||||
|
||||
#ifdef CONFIG_PANEL_NOTIFICATIONS
|
||||
|
||||
int panel_register_notifier(struct notifier_block *nb);
|
||||
int panel_unregister_notifier(struct notifier_block *nb);
|
||||
int panel_notify(unsigned int event, void *data);
|
||||
|
||||
#else
|
||||
|
||||
#include <linux/errno.h>
|
||||
static inline int panel_register_notifier(struct notifier_block *nb)
|
||||
{
|
||||
return -ENOSYS;
|
||||
}
|
||||
static inline int panel_unregister_notifier(struct notifier_block *nb)
|
||||
{
|
||||
return -ENOSYS;
|
||||
}
|
||||
static inline int panel_notify(unsigned int event, void *data)
|
||||
{
|
||||
return -ENOSYS;
|
||||
}
|
||||
|
||||
#endif
|
||||
#endif
|
||||
Loading…
Reference in a new issue