87 lines
1.5 KiB
C
87 lines
1.5 KiB
C
/*
|
|
* adc.h - driver for gsc adc core.h
|
|
*
|
|
*
|
|
* Copyright (C) 2013 Loongson Corporation
|
|
*
|
|
* 2013-09-09
|
|
*/
|
|
#ifndef _GSC_ADC_H_
|
|
#define _GSC_ADC_H_
|
|
|
|
|
|
#ifdef CONFIG_ADC_INTF_DEV
|
|
|
|
extern void __init adc_dev_init(void);
|
|
extern void __exit adc_dev_exit(void);
|
|
extern void adc_dev_prepare(struct adc_core_dev *adc);
|
|
extern void adc_dev_add_device(struct adc_core_dev *adc);
|
|
extern void adc_dev_del_device(struct adc_core_dev *adc);
|
|
|
|
#else
|
|
|
|
static inline void adc_dev_init(void)
|
|
{
|
|
}
|
|
|
|
static inline void adc_dev_exit(void)
|
|
{
|
|
}
|
|
|
|
static inline void adc_dev_prepare(struct adc_core_dev *adc)
|
|
{
|
|
}
|
|
|
|
static inline void adc_dev_add_device(struct adc_core_dev *adc)
|
|
{
|
|
}
|
|
|
|
static inline void adc_dev_del_device(struct adc_core_dev *adc)
|
|
{
|
|
}
|
|
|
|
#endif
|
|
|
|
#ifdef CONFIG_ADC_INTF_PROC
|
|
|
|
extern void adc_proc_add_device(struct adc_core_dev *rtc);
|
|
extern void adc_proc_del_device(struct adc_core_dev *rtc);
|
|
|
|
#else
|
|
|
|
static inline void adc_proc_add_device(struct adc_core_dev *rtc)
|
|
{
|
|
}
|
|
|
|
static inline void adc_proc_del_device(struct adc_core_dev *rtc)
|
|
{
|
|
}
|
|
|
|
#endif
|
|
|
|
#ifdef CONFIG_ADC_INTF_SYSFS
|
|
|
|
extern void __init adc_sysfs_init(struct class *);
|
|
extern void adc_sysfs_add_device(struct adc_core_dev *adc);
|
|
extern void adc_sysfs_del_device(struct adc_core_dev *adc);
|
|
|
|
#else
|
|
|
|
static inline void adc_sysfs_init(struct class *adc)
|
|
{
|
|
}
|
|
|
|
static inline void adc_sysfs_add_device(struct adc_core_dev *adc)
|
|
{
|
|
}
|
|
|
|
static inline void adc_sysfs_del_device(struct adc_core_dev *adc)
|
|
{
|
|
}
|
|
|
|
#endif
|
|
|
|
|
|
#endif
|
|
|