Re: [PATCH v7] iio: adc: add exynos adc driver under iio framwork

2013-03-03 Thread Jonathan Cameron
On 02/15/2013 01:35 PM, Naveen Krishna Ch wrote:
> On 15 February 2013 18:56, Lars-Peter Clausen  wrote:
>> On 02/15/2013 02:17 PM, Naveen Krishna Ch wrote:
>>> On 15 February 2013 18:43, Lars-Peter Clausen  wrote:
 On 02/15/2013 07:56 AM, Naveen Krishna Chatradhi wrote:
> This patch adds New driver to support:
> 1. Supports ADC IF found on EXYNOS4412/EXYNOS5250
>and future SoCs from Samsung
> 2. Add ADC driver under iio/adc framework
> 3. Also adds the Documentation for device tree bindings
>
> Signed-off-by: Naveen Krishna Chatradhi 

 Looks good.

 Reviewed-by: Lars-Peter Clausen 
Applied to togreg branch of iio.git

Thanks,


 One minor thing though, there are a couple of places where you break a line
 into multiple lines, even though the line fits easily inside the 80 chars
 per line limit. In my opinion this doesn't help the legibility of the code.
 E.g.:

 +   info->value = readl(ADC_V1_DATX(info->regs)) &
 +   ADC_DATX_MASK;

 There is no need to respin the patch just for this, but if you happen to
 make another version of the patch, that's something to consider.

> ---
> Changes since v1:
>
> 1. Fixed comments from Lars
> 2. Added support for ADC on EXYNOS5410
>
> Changes since v2:
>
> 1. Changed the instance name for (struct iio_dev *) to indio_dev
> 2. Changed devm_request_irq to request_irq
>
> Few doubts regarding the mappings and child device handling.
> Kindly, suggest me better methods.
>
> Changes since v3:
>
> 1. Added clk_prepare_disable and regulator_disable calls in _remove()
> 2. Moved init_completion before irq_request
> 3. Added NULL pointer check for devm_request_and_ioremap() return value.
> 4. Use number of channels as per the ADC version
> 5. Change the define ADC_V1_CHANNEL to ADC_CHANNEL
> 6. Update the Documentation to include EXYNOS5410 compatible
>
> Changes since v4:
>
> 1. if devm_request_and_ioremap() failes, free iio_device before returning
>
> Changes since v5:
>
> 1. Fixed comments from Olof (ADC hardware version handling)
> 2. Rebased on top of comming OF framework for IIO by "Guenter Roeck".
>
> Changes since v6:
>
> 1. Addressed comments from Lars-Peter Clausen


 btw. these kind of change logs are not really helpful, it would be better 
 to
 list the actual changes made.
>>> Hello Lars,
>>>
>>> No other changes from my side. But, I can send another version.
>>> Do you want me to list the latest change alone instead of the whole
>>> change list ?
>>
>> Hi,
>>
>> No need to resend the patch, this is just something to consider for the
>> future. A changelog entry which reads like "Addressed Jon Does comments" is
>> not really useful since most people will probably not know or not longer
>> remember all the details of those comments, instead a nice list of all the
>> changes which have been made is much better. E.g.:
>>
>> Changes since v6:
>> * Fixed debugfs_read_reg
>> * Introduced timeout when waiting for the data ready IRQ
>> * Slightly reformatted exynos_read_raw for better legibility
>>
>> - Lars
> 
> Thanks for your comments and valuable time.
> Sure Lars, Will do it.
>>
>>
> 
> 
> 
> --
> Shine bright,
> (: Nav :)
> --
> To unsubscribe from this list: send the line "unsubscribe linux-iio" in
> the body of a message to majord...@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v7] iio: adc: add exynos adc driver under iio framwork

2013-02-15 Thread Naveen Krishna Ch
On 15 February 2013 18:56, Lars-Peter Clausen  wrote:
> On 02/15/2013 02:17 PM, Naveen Krishna Ch wrote:
>> On 15 February 2013 18:43, Lars-Peter Clausen  wrote:
>>> On 02/15/2013 07:56 AM, Naveen Krishna Chatradhi wrote:
 This patch adds New driver to support:
 1. Supports ADC IF found on EXYNOS4412/EXYNOS5250
and future SoCs from Samsung
 2. Add ADC driver under iio/adc framework
 3. Also adds the Documentation for device tree bindings

 Signed-off-by: Naveen Krishna Chatradhi 
>>>
>>> Looks good.
>>>
>>> Reviewed-by: Lars-Peter Clausen 
>>>
>>> One minor thing though, there are a couple of places where you break a line
>>> into multiple lines, even though the line fits easily inside the 80 chars
>>> per line limit. In my opinion this doesn't help the legibility of the code.
>>> E.g.:
>>>
>>> +   info->value = readl(ADC_V1_DATX(info->regs)) &
>>> +   ADC_DATX_MASK;
>>>
>>> There is no need to respin the patch just for this, but if you happen to
>>> make another version of the patch, that's something to consider.
>>>
 ---
 Changes since v1:

 1. Fixed comments from Lars
 2. Added support for ADC on EXYNOS5410

 Changes since v2:

 1. Changed the instance name for (struct iio_dev *) to indio_dev
 2. Changed devm_request_irq to request_irq

 Few doubts regarding the mappings and child device handling.
 Kindly, suggest me better methods.

 Changes since v3:

 1. Added clk_prepare_disable and regulator_disable calls in _remove()
 2. Moved init_completion before irq_request
 3. Added NULL pointer check for devm_request_and_ioremap() return value.
 4. Use number of channels as per the ADC version
 5. Change the define ADC_V1_CHANNEL to ADC_CHANNEL
 6. Update the Documentation to include EXYNOS5410 compatible

 Changes since v4:

 1. if devm_request_and_ioremap() failes, free iio_device before returning

 Changes since v5:

 1. Fixed comments from Olof (ADC hardware version handling)
 2. Rebased on top of comming OF framework for IIO by "Guenter Roeck".

 Changes since v6:

 1. Addressed comments from Lars-Peter Clausen
>>>
>>>
>>> btw. these kind of change logs are not really helpful, it would be better to
>>> list the actual changes made.
>> Hello Lars,
>>
>> No other changes from my side. But, I can send another version.
>> Do you want me to list the latest change alone instead of the whole
>> change list ?
>
> Hi,
>
> No need to resend the patch, this is just something to consider for the
> future. A changelog entry which reads like "Addressed Jon Does comments" is
> not really useful since most people will probably not know or not longer
> remember all the details of those comments, instead a nice list of all the
> changes which have been made is much better. E.g.:
>
> Changes since v6:
> * Fixed debugfs_read_reg
> * Introduced timeout when waiting for the data ready IRQ
> * Slightly reformatted exynos_read_raw for better legibility
>
> - Lars

Thanks for your comments and valuable time.
Sure Lars, Will do it.
>
>



--
Shine bright,
(: Nav :)
--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v7] iio: adc: add exynos adc driver under iio framwork

2013-02-15 Thread Lars-Peter Clausen
On 02/15/2013 02:17 PM, Naveen Krishna Ch wrote:
> On 15 February 2013 18:43, Lars-Peter Clausen  wrote:
>> On 02/15/2013 07:56 AM, Naveen Krishna Chatradhi wrote:
>>> This patch adds New driver to support:
>>> 1. Supports ADC IF found on EXYNOS4412/EXYNOS5250
>>>and future SoCs from Samsung
>>> 2. Add ADC driver under iio/adc framework
>>> 3. Also adds the Documentation for device tree bindings
>>>
>>> Signed-off-by: Naveen Krishna Chatradhi 
>>
>> Looks good.
>>
>> Reviewed-by: Lars-Peter Clausen 
>>
>> One minor thing though, there are a couple of places where you break a line
>> into multiple lines, even though the line fits easily inside the 80 chars
>> per line limit. In my opinion this doesn't help the legibility of the code.
>> E.g.:
>>
>> +   info->value = readl(ADC_V1_DATX(info->regs)) &
>> +   ADC_DATX_MASK;
>>
>> There is no need to respin the patch just for this, but if you happen to
>> make another version of the patch, that's something to consider.
>>
>>> ---
>>> Changes since v1:
>>>
>>> 1. Fixed comments from Lars
>>> 2. Added support for ADC on EXYNOS5410
>>>
>>> Changes since v2:
>>>
>>> 1. Changed the instance name for (struct iio_dev *) to indio_dev
>>> 2. Changed devm_request_irq to request_irq
>>>
>>> Few doubts regarding the mappings and child device handling.
>>> Kindly, suggest me better methods.
>>>
>>> Changes since v3:
>>>
>>> 1. Added clk_prepare_disable and regulator_disable calls in _remove()
>>> 2. Moved init_completion before irq_request
>>> 3. Added NULL pointer check for devm_request_and_ioremap() return value.
>>> 4. Use number of channels as per the ADC version
>>> 5. Change the define ADC_V1_CHANNEL to ADC_CHANNEL
>>> 6. Update the Documentation to include EXYNOS5410 compatible
>>>
>>> Changes since v4:
>>>
>>> 1. if devm_request_and_ioremap() failes, free iio_device before returning
>>>
>>> Changes since v5:
>>>
>>> 1. Fixed comments from Olof (ADC hardware version handling)
>>> 2. Rebased on top of comming OF framework for IIO by "Guenter Roeck".
>>>
>>> Changes since v6:
>>>
>>> 1. Addressed comments from Lars-Peter Clausen
>>
>>
>> btw. these kind of change logs are not really helpful, it would be better to
>> list the actual changes made.
> Hello Lars,
> 
> No other changes from my side. But, I can send another version.
> Do you want me to list the latest change alone instead of the whole
> change list ?

Hi,

No need to resend the patch, this is just something to consider for the
future. A changelog entry which reads like "Addressed Jon Does comments" is
not really useful since most people will probably not know or not longer
remember all the details of those comments, instead a nice list of all the
changes which have been made is much better. E.g.:

Changes since v6:
* Fixed debugfs_read_reg
* Introduced timeout when waiting for the data ready IRQ
* Slightly reformatted exynos_read_raw for better legibility

- Lars


--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v7] iio: adc: add exynos adc driver under iio framwork

2013-02-15 Thread Naveen Krishna Ch
On 15 February 2013 18:43, Lars-Peter Clausen  wrote:
> On 02/15/2013 07:56 AM, Naveen Krishna Chatradhi wrote:
>> This patch adds New driver to support:
>> 1. Supports ADC IF found on EXYNOS4412/EXYNOS5250
>>and future SoCs from Samsung
>> 2. Add ADC driver under iio/adc framework
>> 3. Also adds the Documentation for device tree bindings
>>
>> Signed-off-by: Naveen Krishna Chatradhi 
>
> Looks good.
>
> Reviewed-by: Lars-Peter Clausen 
>
> One minor thing though, there are a couple of places where you break a line
> into multiple lines, even though the line fits easily inside the 80 chars
> per line limit. In my opinion this doesn't help the legibility of the code.
> E.g.:
>
> +   info->value = readl(ADC_V1_DATX(info->regs)) &
> +   ADC_DATX_MASK;
>
> There is no need to respin the patch just for this, but if you happen to
> make another version of the patch, that's something to consider.
>
>> ---
>> Changes since v1:
>>
>> 1. Fixed comments from Lars
>> 2. Added support for ADC on EXYNOS5410
>>
>> Changes since v2:
>>
>> 1. Changed the instance name for (struct iio_dev *) to indio_dev
>> 2. Changed devm_request_irq to request_irq
>>
>> Few doubts regarding the mappings and child device handling.
>> Kindly, suggest me better methods.
>>
>> Changes since v3:
>>
>> 1. Added clk_prepare_disable and regulator_disable calls in _remove()
>> 2. Moved init_completion before irq_request
>> 3. Added NULL pointer check for devm_request_and_ioremap() return value.
>> 4. Use number of channels as per the ADC version
>> 5. Change the define ADC_V1_CHANNEL to ADC_CHANNEL
>> 6. Update the Documentation to include EXYNOS5410 compatible
>>
>> Changes since v4:
>>
>> 1. if devm_request_and_ioremap() failes, free iio_device before returning
>>
>> Changes since v5:
>>
>> 1. Fixed comments from Olof (ADC hardware version handling)
>> 2. Rebased on top of comming OF framework for IIO by "Guenter Roeck".
>>
>> Changes since v6:
>>
>> 1. Addressed comments from Lars-Peter Clausen
>
>
> btw. these kind of change logs are not really helpful, it would be better to
> list the actual changes made.
Hello Lars,

No other changes from my side. But, I can send another version.
Do you want me to list the latest change alone instead of the whole
change list ?

>
>>
>>  .../bindings/arm/samsung/exynos5-adc.txt   |   42 ++
>>  drivers/iio/adc/Kconfig|7 +
>>  drivers/iio/adc/Makefile   |1 +
>>  drivers/iio/adc/exynos_adc.c   |  438 
>> 
>>  4 files changed, 488 insertions(+)
>>  .../devicetree/bindings/arm/samsung/exynos-adc.txt |   52 +++
>>  drivers/iio/adc/Kconfig|7 +
>>  drivers/iio/adc/Makefile   |1 +
>>  drivers/iio/adc/exynos_adc.c   |  440 
>> 
>>  4 files changed, 500 insertions(+)
>>  create mode 100644 
>> Documentation/devicetree/bindings/arm/samsung/exynos-adc.txt
>>  create mode 100644 drivers/iio/adc/exynos_adc.c
>>
>> diff --git a/Documentation/devicetree/bindings/arm/samsung/exynos-adc.txt 
>> b/Documentation/devicetree/bindings/arm/samsung/exynos-adc.txt
>> new file mode 100644
>> index 000..f686378
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/arm/samsung/exynos-adc.txt
>> @@ -0,0 +1,52 @@
>> +Samsung Exynos Analog to Digital Converter bindings
>> +
>> +This devicetree binding are for the new adc driver written fori
>> +Exynos4 and upward SoCs from Samsung.
>> +
>> +New driver handles the following
>> +1. Supports ADC IF found on EXYNOS4412/EXYNOS5250
>> +   and future SoCs from Samsung
>> +2. Add ADC driver under iio/adc framework
>> +3. Also adds the Documentation for device tree bindings
>> +
>> +Required properties:
>> +- compatible:Must be "samsung,exynos-adc-v1"
>> + for exynos4412/5250 controllers.
>> + Must be "samsung,exynos-adc-v2" for
>> + future controllers.
>> +- reg:   Contains ADC register address range (base 
>> address and
>> + length).
>> +- interrupts:Contains the interrupt information for the 
>> timer. The
>> + format is being dependent on which interrupt controller
>> + the Samsung device uses.
>> +- #io-channel-cells = <1>; As ADC has multiple outputs
>> +
>> +Note: child nodes can be added for auto probing from device tree.
>> +
>> +Example: adding device info in dtsi file
>> +
>> +adc: adc@12D1 {
>> + compatible = "samsung,exynos-adc-v1";
>> + reg = <0x12D1 0x100>;
>> + interrupts = <0 106 0>;
>> + #io-channel-cells = <1>;
>> + io-channel-ranges;
>> +};
>> +
>> +
>> +Example: Adding child nodes in dts file
>> +
>> +adc@12D1 {
>> +
>> + /* NTC thermistor is a hwmon device */
>> + ncp15wb473@0 {
>> + 

Re: [PATCH v7] iio: adc: add exynos adc driver under iio framwork

2013-02-15 Thread Lars-Peter Clausen
On 02/15/2013 07:56 AM, Naveen Krishna Chatradhi wrote:
> This patch adds New driver to support:
> 1. Supports ADC IF found on EXYNOS4412/EXYNOS5250
>and future SoCs from Samsung
> 2. Add ADC driver under iio/adc framework
> 3. Also adds the Documentation for device tree bindings
> 
> Signed-off-by: Naveen Krishna Chatradhi 

Looks good.

Reviewed-by: Lars-Peter Clausen 

One minor thing though, there are a couple of places where you break a line
into multiple lines, even though the line fits easily inside the 80 chars
per line limit. In my opinion this doesn't help the legibility of the code.
E.g.:

+   info->value = readl(ADC_V1_DATX(info->regs)) &
+   ADC_DATX_MASK;

There is no need to respin the patch just for this, but if you happen to
make another version of the patch, that's something to consider.

> ---
> Changes since v1:
> 
> 1. Fixed comments from Lars
> 2. Added support for ADC on EXYNOS5410
> 
> Changes since v2:
> 
> 1. Changed the instance name for (struct iio_dev *) to indio_dev
> 2. Changed devm_request_irq to request_irq
> 
> Few doubts regarding the mappings and child device handling.
> Kindly, suggest me better methods.
> 
> Changes since v3:
> 
> 1. Added clk_prepare_disable and regulator_disable calls in _remove()
> 2. Moved init_completion before irq_request
> 3. Added NULL pointer check for devm_request_and_ioremap() return value.
> 4. Use number of channels as per the ADC version
> 5. Change the define ADC_V1_CHANNEL to ADC_CHANNEL
> 6. Update the Documentation to include EXYNOS5410 compatible
> 
> Changes since v4:
> 
> 1. if devm_request_and_ioremap() failes, free iio_device before returning
> 
> Changes since v5:
> 
> 1. Fixed comments from Olof (ADC hardware version handling)
> 2. Rebased on top of comming OF framework for IIO by "Guenter Roeck".
> 
> Changes since v6:
> 
> 1. Addressed comments from Lars-Peter Clausen


btw. these kind of change logs are not really helpful, it would be better to
list the actual changes made.

> 
>  .../bindings/arm/samsung/exynos5-adc.txt   |   42 ++
>  drivers/iio/adc/Kconfig|7 +
>  drivers/iio/adc/Makefile   |1 +
>  drivers/iio/adc/exynos_adc.c   |  438 
> 
>  4 files changed, 488 insertions(+)
>  .../devicetree/bindings/arm/samsung/exynos-adc.txt |   52 +++
>  drivers/iio/adc/Kconfig|7 +
>  drivers/iio/adc/Makefile   |1 +
>  drivers/iio/adc/exynos_adc.c   |  440 
> 
>  4 files changed, 500 insertions(+)
>  create mode 100644 
> Documentation/devicetree/bindings/arm/samsung/exynos-adc.txt
>  create mode 100644 drivers/iio/adc/exynos_adc.c
> 
> diff --git a/Documentation/devicetree/bindings/arm/samsung/exynos-adc.txt 
> b/Documentation/devicetree/bindings/arm/samsung/exynos-adc.txt
> new file mode 100644
> index 000..f686378
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/arm/samsung/exynos-adc.txt
> @@ -0,0 +1,52 @@
> +Samsung Exynos Analog to Digital Converter bindings
> +
> +This devicetree binding are for the new adc driver written fori
> +Exynos4 and upward SoCs from Samsung.
> +
> +New driver handles the following
> +1. Supports ADC IF found on EXYNOS4412/EXYNOS5250
> +   and future SoCs from Samsung
> +2. Add ADC driver under iio/adc framework
> +3. Also adds the Documentation for device tree bindings
> +
> +Required properties:
> +- compatible:Must be "samsung,exynos-adc-v1"
> + for exynos4412/5250 controllers.
> + Must be "samsung,exynos-adc-v2" for
> + future controllers.
> +- reg:   Contains ADC register address range (base 
> address and
> + length).
> +- interrupts:Contains the interrupt information for the 
> timer. The
> + format is being dependent on which interrupt controller
> + the Samsung device uses.
> +- #io-channel-cells = <1>; As ADC has multiple outputs
> +
> +Note: child nodes can be added for auto probing from device tree.
> +
> +Example: adding device info in dtsi file
> +
> +adc: adc@12D1 {
> + compatible = "samsung,exynos-adc-v1";
> + reg = <0x12D1 0x100>;
> + interrupts = <0 106 0>;
> + #io-channel-cells = <1>;
> + io-channel-ranges;
> +};
> +
> +
> +Example: Adding child nodes in dts file
> +
> +adc@12D1 {
> +
> + /* NTC thermistor is a hwmon device */
> + ncp15wb473@0 {
> + compatible = "ntc,ncp15wb473";
> + pullup-uV = <180>;
> + pullup-ohm = <47000>;
> + pulldown-ohm = <0>;
> + io-channels = <&adc 4>;
> + };
> +};
> +
> +Note: Does not apply to ADC driver under arch/arm/plat-samsung/
> +Note: The child node can be added under the adc node or sepera

[PATCH v7] iio: adc: add exynos adc driver under iio framwork

2013-02-14 Thread Naveen Krishna Chatradhi
This patch adds New driver to support:
1. Supports ADC IF found on EXYNOS4412/EXYNOS5250
   and future SoCs from Samsung
2. Add ADC driver under iio/adc framework
3. Also adds the Documentation for device tree bindings

Signed-off-by: Naveen Krishna Chatradhi 
---
Changes since v1:

1. Fixed comments from Lars
2. Added support for ADC on EXYNOS5410

Changes since v2:

1. Changed the instance name for (struct iio_dev *) to indio_dev
2. Changed devm_request_irq to request_irq

Few doubts regarding the mappings and child device handling.
Kindly, suggest me better methods.

Changes since v3:

1. Added clk_prepare_disable and regulator_disable calls in _remove()
2. Moved init_completion before irq_request
3. Added NULL pointer check for devm_request_and_ioremap() return value.
4. Use number of channels as per the ADC version
5. Change the define ADC_V1_CHANNEL to ADC_CHANNEL
6. Update the Documentation to include EXYNOS5410 compatible

Changes since v4:

1. if devm_request_and_ioremap() failes, free iio_device before returning

Changes since v5:

1. Fixed comments from Olof (ADC hardware version handling)
2. Rebased on top of comming OF framework for IIO by "Guenter Roeck".

Changes since v6:

1. Addressed comments from Lars-Peter Clausen

 .../bindings/arm/samsung/exynos5-adc.txt   |   42 ++
 drivers/iio/adc/Kconfig|7 +
 drivers/iio/adc/Makefile   |1 +
 drivers/iio/adc/exynos_adc.c   |  438 
 4 files changed, 488 insertions(+)
 .../devicetree/bindings/arm/samsung/exynos-adc.txt |   52 +++
 drivers/iio/adc/Kconfig|7 +
 drivers/iio/adc/Makefile   |1 +
 drivers/iio/adc/exynos_adc.c   |  440 
 4 files changed, 500 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/arm/samsung/exynos-adc.txt
 create mode 100644 drivers/iio/adc/exynos_adc.c

diff --git a/Documentation/devicetree/bindings/arm/samsung/exynos-adc.txt 
b/Documentation/devicetree/bindings/arm/samsung/exynos-adc.txt
new file mode 100644
index 000..f686378
--- /dev/null
+++ b/Documentation/devicetree/bindings/arm/samsung/exynos-adc.txt
@@ -0,0 +1,52 @@
+Samsung Exynos Analog to Digital Converter bindings
+
+This devicetree binding are for the new adc driver written fori
+Exynos4 and upward SoCs from Samsung.
+
+New driver handles the following
+1. Supports ADC IF found on EXYNOS4412/EXYNOS5250
+   and future SoCs from Samsung
+2. Add ADC driver under iio/adc framework
+3. Also adds the Documentation for device tree bindings
+
+Required properties:
+- compatible:  Must be "samsung,exynos-adc-v1"
+   for exynos4412/5250 controllers.
+   Must be "samsung,exynos-adc-v2" for
+   future controllers.
+- reg: Contains ADC register address range (base address and
+   length).
+- interrupts:  Contains the interrupt information for the timer. The
+   format is being dependent on which interrupt controller
+   the Samsung device uses.
+- #io-channel-cells = <1>; As ADC has multiple outputs
+
+Note: child nodes can be added for auto probing from device tree.
+
+Example: adding device info in dtsi file
+
+adc: adc@12D1 {
+   compatible = "samsung,exynos-adc-v1";
+   reg = <0x12D1 0x100>;
+   interrupts = <0 106 0>;
+   #io-channel-cells = <1>;
+   io-channel-ranges;
+};
+
+
+Example: Adding child nodes in dts file
+
+adc@12D1 {
+
+   /* NTC thermistor is a hwmon device */
+   ncp15wb473@0 {
+   compatible = "ntc,ncp15wb473";
+   pullup-uV = <180>;
+   pullup-ohm = <47000>;
+   pulldown-ohm = <0>;
+   io-channels = <&adc 4>;
+   };
+};
+
+Note: Does not apply to ADC driver under arch/arm/plat-samsung/
+Note: The child node can be added under the adc node or seperately.
diff --git a/drivers/iio/adc/Kconfig b/drivers/iio/adc/Kconfig
index e372257..04311f8 100644
--- a/drivers/iio/adc/Kconfig
+++ b/drivers/iio/adc/Kconfig
@@ -91,6 +91,13 @@ config AT91_ADC
help
  Say yes here to build support for Atmel AT91 ADC.
 
+config EXYNOS_ADC
+   bool "Exynos ADC driver support"
+   help
+ Core support for the ADC block found in the Samsung EXYNOS series
+ of SoCs for drivers such as the touchscreen and hwmon to use to share
+ this resource.
+
 config LP8788_ADC
bool "LP8788 ADC driver"
depends on MFD_LP8788
diff --git a/drivers/iio/adc/Makefile b/drivers/iio/adc/Makefile
index 2d5f100..fabac2c 100644
--- a/drivers/iio/adc/Makefile
+++ b/drivers/iio/adc/Makefile
@@ -10,6 +10,7 @@ obj-$(CONFIG_AD7791) += ad7791.o
 obj-$(CONFIG_AD7793) += ad7793.o
 obj-$(CONFIG_AD7887) += ad7887.o
 obj-$(CONFIG_AT91_ADC) += at91_adc.o
+obj-$(CO