From mboxrd@z Thu Jan 1 00:00:00 1970 From: maxime.ripard@free-electrons.com (Maxime Ripard) Date: Fri, 2 Dec 2011 14:17:55 +0100 Subject: [PATCH 1/3] ARM: AT91: Add platform data for the ADCs In-Reply-To: <1322831877-14473-1-git-send-email-maxime.ripard@free-electrons.com> References: <1322831877-14473-1-git-send-email-maxime.ripard@free-electrons.com> Message-ID: <1322831877-14473-2-git-send-email-maxime.ripard@free-electrons.com> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org Signed-off-by: Maxime Ripard Acked-by: Jonathan Cameron Signed-off-by: Nicolas Ferre Acked-by: Jean-Christophe PLAGNIOL-VILLARD Cc: Patrice Vilchez Cc: Thomas Petazzoni --- include/linux/platform_data/at91_adc.h | 29 +++++++++++++++++++++++++++++ 1 files changed, 29 insertions(+), 0 deletions(-) create mode 100644 include/linux/platform_data/at91_adc.h diff --git a/include/linux/platform_data/at91_adc.h b/include/linux/platform_data/at91_adc.h new file mode 100644 index 0000000..1212c78 --- /dev/null +++ b/include/linux/platform_data/at91_adc.h @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2011 Free Electrons + * + * Licensed under the GPLv2 or later. + * + */ + +#ifndef _AT91_ADC_H_ +#define _AT91_ADC_H_ + +struct at91_adc_data { + /* ADC Clock as specified by the datasheet, in Hz. */ + unsigned int adc_clock; + /* + * Global number of channels available (to specify which channels are + * indeed used on the board, see the channels_used bitmask). + */ + u8 num_channels; + /* Channels in use on the board as a bitmask */ + unsigned long channels_used; + /* Startup time of the ADC, in microseconds. */ + u8 startup_time; + /* Reference voltage for the ADC in millivolts */ + unsigned short vref; +}; + +extern void __init at91_add_device_adc(struct at91_adc_data *data); + +#endif -- 1.7.4.1