tizen 2.3 release
[framework/system/deviced.git] / src / core / device-notifier.h
1 /*
2  * deviced
3  *
4  * Copyright (c) 2012 - 2013 Samsung Electronics Co., Ltd. All rights reserved.
5  *
6  * Licensed under the Apache License, Version 2.0 (the "License");
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  */
18
19
20 #ifndef __DEVICE_NOTIFIER_H__
21 #define __DEVICE_NOTIFIER_H__
22
23 enum device_notifier_type {
24         DEVICE_NOTIFIER_BOOTING_DONE,
25         DEVICE_NOTIFIER_HALLIC_OPEN,
26         DEVICE_NOTIFIER_HDMI,
27         DEVICE_NOTIFIER_LCD,
28         DEVICE_NOTIFIER_LCD_ESD,
29         DEVICE_NOTIFIER_MMC,
30         DEVICE_NOTIFIER_MMC_MOUNTED,
31         DEVICE_NOTIFIER_LOWBAT,
32         DEVICE_NOTIFIER_FULLBAT,
33         DEVICE_NOTIFIER_INPUT_ADD,
34         DEVICE_NOTIFIER_INPUT_REMOVE,
35         DEVICE_NOTIFIER_PROCESS_TERMINATED,
36         DEVICE_NOTIFIER_TOUCH_HARDKEY,
37         DEVICE_NOTIFIER_PMQOS_POWERSAVING,
38         DEVICE_NOTIFIER_PMQOS_LOWBAT,
39         DEVICE_NOTIFIER_PMQOS_EMERGENCY,
40         DEVICE_NOTIFIER_PMQOS_POWEROFF,
41         DEVICE_NOTIFIER_POWER_SUPPLY,
42         DEVICE_NOTIFIER_BATTERY_HEALTH,
43         DEVICE_NOTIFIER_BATTERY_OVP,
44         DEVICE_NOTIFIER_BATTERY_CHARGING,
45         DEVICE_NOTIFIER_POWEROFF,
46         DEVICE_NOTIFIER_POWEROFF_HAPTIC,
47         DEVICE_NOTIFIER_PMQOS,
48         DEVICE_NOTIFIER_PMQOS_ULTRAPOWERSAVING,
49         DEVICE_NOTIFIER_PMQOS_HALL,
50         DEVICE_NOTIFIER_COOL_DOWN,
51         DEVICE_NOTIFIER_MAX,
52 };
53
54 /*
55  * This is for internal callback method.
56  */
57 int register_notifier(enum device_notifier_type status, int (*func)(void *data));
58 int unregister_notifier_del(enum device_notifier_type status, int (*func)(void *data));
59 void device_notify(enum device_notifier_type status, void *value);
60
61 #endif /* __DEVICE_NOTIFIER_H__ */