iio: adc: ti_am335x_adc: Get rid of useless gotos

Gotos jumping to a return statement are not really useful, drop them.

Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Acked-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Link: https://lore.kernel.org/r/20211015081506.933180-42-miquel.raynal@bootlin.com
This commit is contained in:
Miquel Raynal 2021-10-15 10:14:59 +02:00 committed by Lee Jones
parent 9cac0a0226
commit 16e8f8fed4
1 changed files with 3 additions and 4 deletions

View File

@ -636,11 +636,11 @@ static int tiadc_probe(struct platform_device *pdev)
IRQF_SHARED, IRQF_SHARED,
&tiadc_buffer_setup_ops); &tiadc_buffer_setup_ops);
if (err) if (err)
goto err_free_channels; return err;
err = iio_device_register(indio_dev); err = iio_device_register(indio_dev);
if (err) if (err)
goto err_buffer_unregister; return err;
platform_set_drvdata(pdev, indio_dev); platform_set_drvdata(pdev, indio_dev);
@ -652,8 +652,7 @@ static int tiadc_probe(struct platform_device *pdev)
err_dma: err_dma:
iio_device_unregister(indio_dev); iio_device_unregister(indio_dev);
err_buffer_unregister:
err_free_channels:
return err; return err;
} }