Re: [PATCH] iio: magnetometer: si7210: use devm_regulator_get_enable_read_voltage()

From: Andy Shevchenko

Date: Tue Feb 10 2026 - 14:38:49 EST


On Tue, Feb 10, 2026 at 07:51:28PM +0200, Antoniu Miclaus wrote:
> Simplify probe by using devm_regulator_get_enable_read_voltage() to
> get, enable and read the regulator voltage in a single call, caching
> the value at probe time.

...

> + unsigned int vdd_uv;

vdd_uV // now wondering if we can even use unicode variable name µV :-)

...

> + temp -= 222 * div_s64(data->vdd_uv, MILLI);

Not sure why this is 64-bit division now.

--
With Best Regards,
Andy Shevchenko