On 02/13/2013 02:53 PM, Naveen Krishna Ch wrote:
[...]
>>> ADC driver will use of_platform_populate() to populate the child nodes
>>> (ntc thermistors in my case)
>>>
>>> I've modified the NTC driver to support DT. in probe
>>> chan = iio_channel_get(&pdev->dev, "adcX");
>>> and using "id" field to use respective ADC channel to do the raw_read()
>>
>> The beauty of the interface is that the consumer doesn't need to know the
>> number of the channel it is using. This is already fully described in the
>> io-channels property. Since you only have one channel per consumer just use
>>
>>         iio_chanel_get(&pdev->dev, NULL)
> Right this helped me get the channels properly.
> 
> I've a doubt in the driver posted at https://lkml.org/lkml/2013/1/24/2
> i don't need to use this anymore right use iio_map_array_register() Right.
> 
> Thats so simple then.. Thanks

Yes, if you are using devicetree you don't need to use
iio_map_array_register() anymore :)

- Lars

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to