Re: [PATCH v5 3/6] iio: adc: mcp3911: simplify usage of spi->dev

From: Andy Shevchenko
Date: Tue Aug 15 2023 - 10:54:32 EST


On Mon, Aug 14, 2023 at 02:10:07PM +0200, Marcus Folkesson wrote:
> Replace the usage of `adc->spi->dev` with `dev` to make the code prettier.

...

> u32 ref = MCP3911_INT_VREF_MV;
> + struct device *dev = &adc->spi->dev;

Keep it upper.

> u32 div;
> int ret;
> u64 tmp;

...

> + ret = devm_iio_triggered_buffer_setup(dev, indio_dev,
> + NULL,

This can be moved to the upper line.

> + mcp3911_trigger_handler, NULL);
> if (ret)
> return ret;

...

With above addressed,
Reviewed-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx>

--
With Best Regards,
Andy Shevchenko