Message ID | 1369256897-25984-4-git-send-email-bigeasy@linutronix.de (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On 05/22/2013 10:08 PM, Sebastian Andrzej Siewior wrote: > The DT support added in ("iio: adc: am335x: Add DT support") > added an else case which shifts the code to the righ for no reaseon. > This patch simply removes the pointless else case and shifts the code > back to the left. > > Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Either I am going completely mad or I never took the original patch. I'm not entirely sure I can remember why though. I think there were issues with another patch in the series and so I was waiting for a reposting that never happened. Looking back I think the debate was curriously enough whether it made sense ot have the platform_data support in there or not. Did anyone every take any of that series? Which tree did you base these on? > --- > drivers/iio/adc/ti_am335x_adc.c | 13 +++++-------- > 1 file changed, 5 insertions(+), 8 deletions(-) > > diff --git a/drivers/iio/adc/ti_am335x_adc.c b/drivers/iio/adc/ti_am335x_adc.c > index f258eb0..ac78672 100644 > --- a/drivers/iio/adc/ti_am335x_adc.c > +++ b/drivers/iio/adc/ti_am335x_adc.c > @@ -214,14 +214,11 @@ static int tiadc_probe(struct platform_device *pdev) > node = of_get_child_by_name(node, "adc"); > if (!node) > return -EINVAL; > - else { > - err = of_property_read_u32(node, > - "ti,adc-channels", &val32); > - if (err < 0) > - goto err_free_device; > - else > - adc_dev->channels = val32; > - } > + err = of_property_read_u32(node, > + "ti,adc-channels", &val32); > + if (err < 0) > + goto err_free_device; > + adc_dev->channels = val32; > } > > indio_dev->dev.parent = &pdev->dev; > -- To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On 05/22/2013 11:55 PM, Jonathan Cameron wrote:
> Did anyone every take any of that series? Which tree did you base these on?
I am very sorry for not replying earlier, I somehow overlooked your
email until now. Saying that I assumed that the series I relied on was
merged. Later I've been told that this is not the case and I rebased
everything on top of v3.10-rc3. So please ignore this series, there are
two new :)
Sebastian
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/iio/adc/ti_am335x_adc.c b/drivers/iio/adc/ti_am335x_adc.c index f258eb0..ac78672 100644 --- a/drivers/iio/adc/ti_am335x_adc.c +++ b/drivers/iio/adc/ti_am335x_adc.c @@ -214,14 +214,11 @@ static int tiadc_probe(struct platform_device *pdev) node = of_get_child_by_name(node, "adc"); if (!node) return -EINVAL; - else { - err = of_property_read_u32(node, - "ti,adc-channels", &val32); - if (err < 0) - goto err_free_device; - else - adc_dev->channels = val32; - } + err = of_property_read_u32(node, + "ti,adc-channels", &val32); + if (err < 0) + goto err_free_device; + adc_dev->channels = val32; } indio_dev->dev.parent = &pdev->dev;
The DT support added in ("iio: adc: am335x: Add DT support") added an else case which shifts the code to the righ for no reaseon. This patch simply removes the pointless else case and shifts the code back to the left. Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> --- drivers/iio/adc/ti_am335x_adc.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-)