From: Daasaradhi Mannava <daasaradhimannava@gmail.com>
To: "Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>
Cc: Denis Benato <denis.benato@linux.dev>,
Nikita Kravets <teackot@gmail.com>,
Hans de Goede <hansg@kernel.org>,
platform-driver-x86@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] platform/x86: msi-ec: Report valid charge thresholds when unset
Date: Sat, 19 Sep 2026 00:19:55 +0530 [thread overview]
Message-ID: <20260918184958.6211-1-daasaradhimannava@gmail.com> (raw)
In-Reply-To: <12cdf224-08aa-d19f-62fd-fbc6e26d6103@linux.intel.com>
[Resending as plain text, the lists rejected my previous reply.]
On Thu, 17 Sep 2026, Ilpo Järvinen wrote:
> This seems similar to case in commits:
>
> 186bf9031666 ("platform/x86: asus-wmi: do not enforce a battery charge threshold")
> 78bf392ba77d ("platform/x86: asus-wmi: temporarily revert to setting a charge limit")
>
> (The latter reverts first one as userspace could not handle -ENODATA but
> thought the feature was available.)
>
> So ideally, I'd tend to think we'd want to return -ENODATA when the
> threshold hasn't been set. But whether userspace survives that is a
> question we cannot ignore.
Hi Ilpo,
Thanks for the pointers.
I agree -ENODATA describes the state better. The asus-wmi revert was
caused by upower's udev rule reading the attribute to detect support
(upower#347). That was fixed in upower 1.91.3 (commit 83f86c75,
July 2026), but current stable distros still ship older versions,
e.g. Debian 13 has 1.90.9 and Ubuntu 26.04 has 1.91.1. Returning
-ENODATA from msi-ec now would hide the GNOME battery health toggle
for most MSI users.
Unlike asus-wmi before 186bf9031666, msi-ec never writes the threshold
at boot, so this patch only changes what is reported: today it is
-10/0, which is outside the documented 0-100 range and makes the
limit look set to 0%.
So I'd suggest taking this patch as is for now, and switching both
drivers to -ENODATA together once a fixed upower is widely available.
If you'd rather have -ENODATA right away, I'm happy to send a v2.
Thanks,
Daasaradhi
next prev parent reply other threads:[~2026-09-18 18:50 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-16 17:48 [PATCH] platform/x86: msi-ec: Report valid charge thresholds when unset Daasaradhi Mannava
2026-09-17 8:44 ` Ilpo Järvinen
2026-09-18 18:49 ` Daasaradhi Mannava [this message]
2026-10-05 17:44 ` Ilpo Järvinen
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=20260918184958.6211-1-daasaradhimannava@gmail.com \
--to=daasaradhimannava@gmail.com \
--cc=denis.benato@linux.dev \
--cc=hansg@kernel.org \
--cc=ilpo.jarvinen@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=platform-driver-x86@vger.kernel.org \
--cc=teackot@gmail.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.