From: Lorenz Brun <lorenz@brun.one>
To: Guenter Roeck <linux@roeck-us.net>
Cc: Jean Delvare <jdelvare@suse.com>,
linux-hwmon@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] hwmon: pwm-fan: set usage_power on PWM state
Date: Fri, 17 Mar 2023 12:33:57 +0100 [thread overview]
Message-ID: <LGXNRR.0Q7OXCG5DVDQ2@brun.one> (raw)
In-Reply-To: <ec52f540-0f78-4cf0-ae61-314cab33ac80@roeck-us.net>
Am Mi, 15. Mär 2023 um 19:26:26 -07:00:00 schrieb Guenter Roeck
<linux@roeck-us.net>:
> This doesn't seem to be used anywhere else. I do not understand the
> rationale, and I do not understand the practical impact of this
> change.
> This needs to be confirmed by someone who understands what the flag is
> supposed to be used for, its impact, and if it is indeed appropriate
> in this context.
>
> Also, since in practice there is no such "less flexible hardware"
> in the upstream kernel, please describe the use case in more detail.
> The only pwm driver that supports usage_power is pwm-pca9685,
> and that driver uses the flag for EMI reasons, not because it is
> "less flexible hardware". I am not inclined to accept such a change
> without specific use case or need.
The reason for this is that I have a PWM-driven fan on a Mediatek
MT7986a whose PWM signal is inverted by a MOSFET.
The PWM peripheral of the MT7986a however doesn't support inverted
output, at least not in a strict sense (i.e. if inverted mathematically
it is out of phase). The maintainer of the PWM subsystem recommended
that I only mathematically invert if usage_power is set as this means
that phase doesn't matter.
See
https://lore.kernel.org/linux-pwm/20230309010410.2106525-1-lorenz@brun.one/
for the PWM-side patch.
Regards,
Lorenz
next prev parent reply other threads:[~2023-03-17 11:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-09 1:10 [PATCH] hwmon: pwm-fan: set usage_power on PWM state Lorenz Brun
2023-03-16 2:26 ` Guenter Roeck
2023-03-17 11:33 ` Lorenz Brun [this message]
2023-03-21 15:03 ` Guenter Roeck
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=LGXNRR.0Q7OXCG5DVDQ2@brun.one \
--to=lorenz@brun.one \
--cc=jdelvare@suse.com \
--cc=linux-hwmon@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@roeck-us.net \
/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).