1 ////////////////////////////////////////////////////////////////////////////////////
3 // FILE: device_driver.h
7 // SEE ALSO: device_driver.c
8 // AUTHOR: L.Komkov, S.Dianov, S.Grekhov, A.Gerenkov
9 // COMPANY NAME: Samsung Research Center in Moscow
10 // DEPT NAME: Advanced Software Group
11 // CREATED: 2008.02.15
13 // REVISION DATE: 2008.12.03
15 ////////////////////////////////////////////////////////////////////////////////////
17 #if !defined(device_driver_h)
18 #define device_driver_h
20 #include "ec_info.h" // ec_info_t
21 #include "ec_probe.h" // probe_id_t
22 #include "stdswap_defs.h"
24 #define DEFAULT_DEVICE_NAME "swap_drv"
25 #define DEFAULT_DEVICE_MAJOR 250
26 #define EVENTS_AGGREGATION_USEC (5 * 1000000UL)
27 #define MAX_PRIORITY 255
29 extern int device_init (void);
30 extern void device_down (void);
31 extern void notify_user (event_id_t event_id);
34 extern struct dbi_modules_handlers *get_dbi_modules_handlers(void);
36 #endif /* !defined(device_driver_h) */
37 #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 17)
38 void swap_register_notify (struct notifier_block *nb);
39 void swap_unregister_notify (struct notifier_block *nb);