summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinux Build Service Account <lnxbuild@qualcomm.com>2010-09-01 13:22:05 -0700
committerQuIC Gerrit Code Review <code-review@quicinc.com>2010-09-01 13:22:05 -0700
commit85fc2d0ccabb87be20b90d1d3a735f482d28dae1 (patch)
treeb1ee04636211adb865f0fc5125c21604dbf3d526
parent1c17b6f1eece6435a6a39450d2b21d35c5bdfdbe (diff)
parentf5823d9512234def21078c2684d22211f54e4894 (diff)
downloadbionic-85fc2d0ccabb87be20b90d1d3a735f482d28dae1.zip
bionic-85fc2d0ccabb87be20b90d1d3a735f482d28dae1.tar.gz
bionic-85fc2d0ccabb87be20b90d1d3a735f482d28dae1.tar.bz2
Merge "bionic: Add msm_adc.h from kernel dir for usermode access." into froyoM8660AAABQNLYA10450001
-rw-r--r--libc/kernel/common/linux/msm_adc.h59
1 files changed, 59 insertions, 0 deletions
diff --git a/libc/kernel/common/linux/msm_adc.h b/libc/kernel/common/linux/msm_adc.h
new file mode 100644
index 0000000..311bbb7
--- /dev/null
+++ b/libc/kernel/common/linux/msm_adc.h
@@ -0,0 +1,59 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __MSM_ADC_H
+#define __MSM_ADC_H
+
+#define MSM_ADC_MAX_CHAN_STR 64
+
+#define MSM_ADC_DEV_MAX_INFLIGHT 9
+
+#define MSM_ADC_IOCTL_CODE 0x90
+
+struct msm_adc_conversion {
+
+ uint32_t chan;
+
+ int result;
+};
+
+#define MSM_ADC_REQUEST _IOWR(MSM_ADC_IOCTL_CODE, 1, struct msm_adc_conversion)
+
+#define MSM_ADC_AIO_REQUEST _IOWR(MSM_ADC_IOCTL_CODE, 2, struct msm_adc_conversion)
+
+#define MSM_ADC_AIO_REQUEST_BLOCK_RES _IOWR(MSM_ADC_IOCTL_CODE, 3, struct msm_adc_conversion)
+
+#define MSM_ADC_AIO_POLL _IOR(MSM_ADC_IOCTL_CODE, 4, uint32_t)
+
+struct msm_adc_aio_result {
+ uint32_t chan;
+ int result;
+};
+
+#define MSM_ADC_AIO_READ _IOR(MSM_ADC_IOCTL_CODE, 5, struct msm_adc_aio_result)
+
+struct msm_adc_lookup {
+
+ char name[MSM_ADC_MAX_CHAN_STR];
+
+ uint32_t chan_idx;
+};
+
+#define MSM_ADC_LOOKUP _IOWR(MSM_ADC_IOCTL_CODE, 6, struct msm_adc_lookup)
+
+struct msm_adc_platform_data {
+ uint32_t num_adc;
+ uint32_t chan_per_adc;
+ char **dev_names;
+};
+
+#endif
+