Re: [PATCH v2] stagging:iio:ad9834: add devicetree property support

2016-09-19 Thread Lars-Peter Clausen
On 09/18/2016 10:52 AM, Gwenhael Goavec-Merou wrote: [...] > +#if defined(CONFIG_OF) > +static struct ad9834_platform_data *ad9834_parse_dt(struct spi_device *spi) > +{ > + struct ad9834_platform_data *pdata; > + struct device_node *np = spi->dev.of_node; > + > + pdata =

[PATCH v2] stagging:iio:ad9834: add devicetree property support

2016-09-18 Thread Gwenhael Goavec-Merou
ad9834 driver needs some default properties. Currently these parameters are provided through platform_data. This patch adds a function to create this pdata based on device-tree node. Signed-off-by: Gwenhael Goavec-Merou --- Changes v1 -> v2: - use