Re: [PATCH v2 2/3] regulator: da9063: implement basic XVP setter

From: Mark Brown
Date: Wed Apr 05 2023 - 06:52:32 EST


On Wed, Apr 05, 2023 at 07:29:08AM +0200, Benjamin Bara wrote:
> From: Benjamin Bara <benjamin.bara@xxxxxxxxxxx>
>
> Allow to en- and disable voltage monitoring from the device tree.
> Consider that the da9063 only monitors UV *and* OV together, so both
> must be en- or disabled.

I have no idea what a "basic XVP setter" is and this isn't super
enlightening. Is VP supposed to mean voltage protection or something?

> + /* make sure that both UV/OV protections are either enabled or disabled */
> + if (uv_l->prot != ov_l->prot || uv_l->err != ov_l->err || uv_l->warn != ov_l->warn) {
> + dev_err(config->dev, "%s: regulator-uv-X-microvolt != regulator-ov-X-microvolt\n",
> + regl->desc.name);
> + return -EINVAL;

I'm not sure that a user is going to figure out that this refers to the
protection levels, there's no hint as to what the X might be and the
error suggests that both the under and over voltage protection limits
must be have the same value, not just both be provided.

Attachment: signature.asc
Description: PGP signature