mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Victor Krawiec <victor.krawiec@arturia.com>
To: Krzysztof Kozlowski <krzk@kernel.org>
Cc: lgirdwood@gmail.com, broonie@kernel.org, robh@kernel.org,
	krzk+dt@kernel.org, conor+dt@kernel.org,
	linux-kernel@vger.kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCH v3 1/4] regulator: dt-bindings: Add fan53555 allowed modes
Date: Tue, 28 Jul 2026 10:56:25 +0200	[thread overview]
Message-ID: <463f14e0-ed5c-4662-8bab-d1f393b456a4@arturia.com> (raw)
In-Reply-To: <20260728-portable-tactful-newt-eafcc3@quoll>

On 7/28/26 09:28, Krzysztof Kozlowski wrote:
> 
> Feedback of Sashiko looks unanswered, so dropping this from Patchwork.
> 
> Best regards,
> Krzysztof
> 

Sorry I didn't know I had to answer to the AI bot. Should I send again the
patch series since it is dropped from Patchwork ?

Anyway here are the answers to the Sashiko review

On 7/23/26 11:53, sashiko-bot@kernel.org wrote:
> New issues:
> - [Medium] The device tree binding introduces the `regulator-initial-mode` property, but the corresponding driver lacks the `.of_map_mode` callback required to use it.

This patch serie includes a commit that adds the `.of_map_mode` callback to
the driver. The callback is added at runtime dynamically depending on the
vendor. Maybe that's why the bot did not notice it. Indeed the driver is
used by several devices clone from different vendors. The `.of_map_mode`
was restricted to Silergy vendor as it is the only vendor I am able to
test.

> - [Low] The patch defines constraints for `regulator-initial-mode` but fails to define constraints for `regulator-allowed-modes`.

According to documentation `regulator-allowed-modes` is the list of
operating modes that software is allowed to configure for the regulator at
run-time. No one has expressed the need to be able to change mode by
software on this regulator for now. The need covered here is to change the
initial mode during regulator init.

> Pre-existing issues:
> - [High] A preexisting bug in `fan53555_set_mode()` corrupts the voltage register when setting `REGULATOR_MODE_NORMAL` on certain vendor variants like RK8602.

For Silergy vendor the `fan53555_set_mode()` writes to the correct register
since `di->mode_reg` is the same as `di->vol_reg`.

> For variants like the RK8602 where mode_reg and vol_reg are distinct
> hardware registers, clearing di->mode_mask (e.g. BIT(6)) in di->vol_reg
> could silently drop the output voltage by 64 steps (400mV). Could this lead
> to severe undervolting and system crashes if a consumer attempts to change
> the mode?

It is true that using `di->vol_reg` in this function seems wrong for
vendors that have distinct registers. However I don't have access to those
devices to test such a change. The submitted patch is perfectly safe as it
ignores the mode change for these untested vendors.

  reply	other threads:[~2026-07-28  8:56 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-23  9:39 [PATCH v3 0/4] Configure SYR82X regulator modes via device tree Victor Krawiec
2026-07-23  9:39 ` [PATCH v3 1/4] regulator: dt-bindings: Add fan53555 allowed modes Victor Krawiec
2026-07-28  7:28   ` Krzysztof Kozlowski
2026-07-28  8:56     ` Victor Krawiec [this message]
2026-07-23  9:39 ` [PATCH v3 2/4] arm64: dts: rk3399-rock-4c-plus: Use device tree bindings constants for SYR828 regulator initial mode Victor Krawiec
2026-07-23  9:40 ` [PATCH v3 3/4] arm64: dts: rockchip: rk3399-hugsun-x99: Update SYR828 regulator initial mode to use device tree bindings constants Victor Krawiec
2026-07-23  9:40 ` [PATCH v3 4/4] regulator: fan53555: Add support for mode operations on Silergy devices Victor Krawiec
2026-07-28 18:27 ` (subset) [PATCH v3 0/4] Configure SYR82X regulator modes via device tree Mark Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=463f14e0-ed5c-4662-8bab-d1f393b456a4@arturia.com \
    --to=victor.krawiec@arturia.com \
    --cc=broonie@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=krzk@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robh@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®