Logo Search packages:      
Sourcecode: linux-fsl-imx51 version File versions  Download package

pmic_adc.c File Reference

Detailed Description

This is the main file of PMIC(mc13783) ADC driver.

Definition in file pmic_adc.c.

#include <linux/platform_device.h>
#include <linux/poll.h>
#include <linux/sched.h>
#include <linux/time.h>
#include <linux/delay.h>
#include <linux/wait.h>
#include <linux/pmic_adc.h>
#include <linux/pmic_status.h>
#include "../core/pmic.h"
#include "pmic_adc_defs.h"

Go to the source code of this file.


#define NB_ADC_REG   5


static void callback_adc_comp_high (void *)
static void callback_adcbisdone (void *)
static void callback_adcdone (void *)
static void callback_tsi (void *)
static DECLARE_COMPLETION (adc_tsi)
static DECLARE_COMPLETION (adcbisdone_it)
static DECLARE_COMPLETION (adcdone_it)
static DECLARE_MUTEX (convert_mutex)
static DECLARE_WAIT_QUEUE_HEAD (queue_adc_busy)
 EXPORT_SYMBOL (is_pmic_adc_ready)
 EXPORT_SYMBOL (pmic_adc_deactive_comparator)
 EXPORT_SYMBOL (pmic_adc_active_comparator)
 EXPORT_SYMBOL (pmic_adc_get_battery_current)
 EXPORT_SYMBOL (pmic_adc_get_touch_sample)
 EXPORT_SYMBOL (pmic_adc_get_touch_mode)
 EXPORT_SYMBOL (pmic_adc_set_touch_mode)
 EXPORT_SYMBOL (pmic_adc_convert_multichnnel)
 EXPORT_SYMBOL (pmic_adc_convert_8x)
 EXPORT_SYMBOL (pmic_adc_convert)
 EXPORT_SYMBOL (pmic_adc_deinit)
 EXPORT_SYMBOL (pmic_adc_init)
int is_pmic_adc_ready ()
PMIC_STATUS mc13783_adc_convert (t_adc_param *adc_param)
int mc13783_adc_init_monitor_param (t_monitoring_param *monitor)
int mc13783_adc_init_param (t_adc_param *adc_param)
PMIC_STATUS mc13783_adc_read_ts (t_touch_screen *ts_value, int wait_tsi)
int mc13783_adc_release (int adc_index)
int mc13783_adc_request (bool read_ts)
t_reading_mode mc13783_set_read_mode (t_channel channel)
 MODULE_AUTHOR ("Freescale Semiconductor, Inc.")
 module_exit (pmic_adc_module_exit)
 module_init (pmic_adc_module_init)
PMIC_STATUS pmic_adc_active_comparator (unsigned char low, unsigned char high, t_channel channel, t_comparator_cb callback)
PMIC_STATUS pmic_adc_convert (t_channel channel, unsigned short *result)
PMIC_STATUS pmic_adc_convert_8x (t_channel channel, unsigned short *result)
PMIC_STATUS pmic_adc_convert_multichnnel (t_channel channels, unsigned short *result)
PMIC_STATUS pmic_adc_deactive_comparator (void)
PMIC_STATUS pmic_adc_deinit (void)
static int pmic_adc_filter (t_touch_screen *ts_curr)
static int pmic_adc_free (struct inode *inode, struct file *file)
PMIC_STATUS pmic_adc_get_battery_current (t_conversion_mode mode, unsigned short *result)
PMIC_STATUS pmic_adc_get_touch_mode (t_touch_mode *touch_mode)
PMIC_STATUS pmic_adc_get_touch_sample (t_touch_screen *touch_sample, int wait)
int pmic_adc_init (void)
static int pmic_adc_ioctl (struct inode *inode, struct file *file, unsigned int cmd, unsigned long arg)
static void __exit pmic_adc_module_exit (void)
static int __init pmic_adc_module_init (void)
static int pmic_adc_module_probe (struct platform_device *pdev)
static int pmic_adc_module_remove (struct platform_device *pdev)
static int pmic_adc_open (struct inode *inode, struct file *file)
static int pmic_adc_resume (struct platform_device *pdev)
PMIC_STATUS pmic_adc_set_touch_mode (t_touch_mode touch_mode)
static int pmic_adc_suspend (struct platform_device *pdev, pm_message_t state)


static pmic_event_callback_t adc_comp_h
static t_adc_state adc_dev [2]
static bool adc_ts
static unsigned channel_num []
static bool data_ready_adc_1
static bool data_ready_adc_2
static pmic_event_callback_t event_adc
static pmic_event_callback_t event_adc_bis
static struct file_operations mc13783_adc_fops
static bool monitor_adc
static bool monitor_en
void(* monitoring_cb )(void)
static struct class * pmic_adc_class
static struct platform_driver pmic_adc_driver_ldm
static int pmic_adc_major
static bool pmic_adc_ready
static int suspend_flag = 0
static wait_queue_head_t suspendq
static int swait = 0
static pmic_event_callback_t tsi_event
static bool wait_ts
static t_check_mode wcomp_mode

Generated by  Doxygen 1.6.0   Back to index