From: Jerome Brunet <jbrunet@baylibre.com>
To: Guenter Roeck <linux@roeck-us.net>
Cc: Jean Delvare <jdelvare@suse.com>,
Jonathan Corbet <corbet@lwn.net>,
Patrick Rudolph <patrick.rudolph@9elements.com>,
Naresh Solanki <naresh.solanki@9elements.com>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Delphine CC Chiu <Delphine_CC_Chiu@wiwynn.com>,
linux-hwmon@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-doc@vger.kernel.org, devicetree@vger.kernel.org,
linux-i2c@vger.kernel.org
Subject: Re: [PATCH v3 3/6] hwmon: (pmbus/core) add wp module param
Date: Mon, 04 Nov 2024 15:39:05 +0100 [thread overview]
Message-ID: <1jfro783na.fsf@starbuckisacylon.baylibre.com> (raw)
In-Reply-To: <fa79de78-aed9-4cd3-bff9-310f2b4a32c9@roeck-us.net> (Guenter Roeck's message of "Mon, 4 Nov 2024 06:18:27 -0800")
On Mon 04 Nov 2024 at 06:18, Guenter Roeck <linux@roeck-us.net> wrote:
> On 11/4/24 00:43, Jerome Brunet wrote:
>
>>>> +/*
>>>> + * PMBus write protect forced mode:
>>>> + * PMBus may come up with a variety of write protection configuration.
>>>> + * 'pmbus_wp' may be used if a particular write protection is necessary.
>>>> + * The ability to actually alter the protection may also depend on the chip
>>>> + * so the actual runtime write protection configuration may differ from
>>>> + * the requested one. pmbus_core currently support the following value:
>>>> + * - 0: write protection removed
>>>> + * - 1: write protection fully enabled, including OPERATION and VOUT_COMMAND
>>>> + * registers. Chips essentially become read-only with this.
>>>
>>> Would it be desirable to also suppport the ability to set the output voltage
>>> but not limits (PB_WP_VOUT) ?
>> I was starting simple, it is doable sure.
>> It is not something I will be able to test on actual since does not
>> support that.
>> Do you want me to add "2: write protection enable execpt for
>> VOUT_COMMAND." ?
>>
>
> Please add it. I have a number of PMBus test boards and will be able to test it.
>
> Thee are three options, though. Per specification:
Any preference for the value mapped to each mode ? Using the one from
the spec does not seem practical (32768, 16384, 8192).
The bit number, maybe (7, 6, 5) ?
or just by order strongest locking ?
>
> 1000 0000 Disable all writes except to the WRITE_PROTECT command
3
> 0100 0000 Disable all writes except to the WRITE_PROTECT, OPERATION and
> PAGE commands
2
> 0010 0000 Disable all writes except to the WRITE_PROTECT, OPERATION,
> PAGE, ON_OFF_CONFIG and VOUT_COMMAND commands
1 ?
>
> The driver uses OPERATION and VOUT_COMMAND, so we should have options
> to disable them separately. It may be desirable, for example, to be able
> to turn on a regulator but not to change the voltages. Also, since
> full write protection also disables writes to the page register,
> the impact of full write protection on multi-page chips needs to be
> documented.
Noted. I'll update the documentation.
>
> Thanks,
> Guenter
--
Jerome
next prev parent reply other threads:[~2024-11-04 14:39 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-24 18:10 [PATCH v3 0/6] hwmon: pmbus: add tps25990 efuse support Jerome Brunet
2024-10-24 18:10 ` [PATCH v3 1/6] hwmon: (pmbus/core) allow drivers to override WRITE_PROTECT Jerome Brunet
2024-10-24 18:10 ` [PATCH v3 2/6] hwmon: (pmbus/core) improve handling of write protected regulators Jerome Brunet
2024-11-01 14:59 ` Guenter Roeck
2024-10-24 18:10 ` [PATCH v3 3/6] hwmon: (pmbus/core) add wp module param Jerome Brunet
2024-11-01 15:08 ` Guenter Roeck
2024-11-04 8:43 ` Jerome Brunet
2024-11-04 13:57 ` Guenter Roeck
2024-11-04 14:18 ` Guenter Roeck
2024-11-04 14:39 ` Jerome Brunet [this message]
2024-11-04 15:08 ` Guenter Roeck
2024-10-24 18:10 ` [PATCH v3 4/6] hwmon: (pmbus/core) clear faults after setting smbalert mask Jerome Brunet
2024-11-01 15:10 ` Guenter Roeck
2024-11-04 8:28 ` Jerome Brunet
2024-11-04 13:51 ` Guenter Roeck
2024-10-24 18:10 ` [PATCH v3 5/6] dt-bindings: hwmon: pmbus: add ti tps25990 support Jerome Brunet
2024-10-24 18:10 ` [PATCH v3 6/6] hwmon: (pmbus/tps25990): add initial support Jerome Brunet
2024-10-25 14:04 ` kernel test robot
2024-10-29 13:49 ` kernel test robot
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=1jfro783na.fsf@starbuckisacylon.baylibre.com \
--to=jbrunet@baylibre.com \
--cc=Delphine_CC_Chiu@wiwynn.com \
--cc=conor+dt@kernel.org \
--cc=corbet@lwn.net \
--cc=devicetree@vger.kernel.org \
--cc=jdelvare@suse.com \
--cc=krzk+dt@kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-hwmon@vger.kernel.org \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=naresh.solanki@9elements.com \
--cc=patrick.rudolph@9elements.com \
--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;
as well as URLs for NNTP newsgroup(s).