Commit c60e5760 authored by Jimmy Li's avatar Jimmy Li Committed by Jonathan Cameron

staging:iio:ad2s1200 fix missing parenthesis in a for statment.

Signed-off-by: default avatarJimmy Li <coder.liss@gmail.com>
Signed-off-by: default avatarJonathan Cameron <jic23@kernel.org>
parent 8b425aa1
...@@ -107,7 +107,7 @@ static int ad2s1200_probe(struct spi_device *spi) ...@@ -107,7 +107,7 @@ static int ad2s1200_probe(struct spi_device *spi)
int pn, ret = 0; int pn, ret = 0;
unsigned short *pins = spi->dev.platform_data; unsigned short *pins = spi->dev.platform_data;
for (pn = 0; pn < AD2S1200_PN; pn++) for (pn = 0; pn < AD2S1200_PN; pn++) {
ret = devm_gpio_request_one(&spi->dev, pins[pn], GPIOF_DIR_OUT, ret = devm_gpio_request_one(&spi->dev, pins[pn], GPIOF_DIR_OUT,
DRV_NAME); DRV_NAME);
if (ret) { if (ret) {
...@@ -115,6 +115,7 @@ static int ad2s1200_probe(struct spi_device *spi) ...@@ -115,6 +115,7 @@ static int ad2s1200_probe(struct spi_device *spi)
pins[pn]); pins[pn]);
return ret; return ret;
} }
}
indio_dev = devm_iio_device_alloc(&spi->dev, sizeof(*st)); indio_dev = devm_iio_device_alloc(&spi->dev, sizeof(*st));
if (!indio_dev) if (!indio_dev)
return -ENOMEM; return -ENOMEM;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment