* [PATCH] mfd: cros_ec: Separate charge-control probing from USB-PD
@ 2025-05-21 14:42 Thomas Weißschuh
2025-05-28 11:46 ` Tom Vincent
2025-06-13 13:34 ` (subset) " Lee Jones
0 siblings, 2 replies; 3+ messages in thread
From: Thomas Weißschuh @ 2025-05-21 14:42 UTC (permalink / raw)
To: Lee Jones, Benson Leung, Guenter Roeck
Cc: chrome-platform, linux-kernel, Thomas Weißschuh
The charge-control subsystem in the ChromeOS EC is not strictly tied to
its USB-PD subsystem.
Since commit 7613bc0d116a ("mfd: cros_ec: Don't load charger with UCSI")
the presence of EC_FEATURE_UCSI_PPM would inhibit the probing of the
charge-control driver.
Furthermore recent versions of the EC firmware in Framework laptops
hard-disable EC_FEATURE_USB_PD to avoid probing cros-usbpd-charger,
which then also breaks cros-charge-control.
Instead use the dedicated EC_FEATURE_CHARGER.
Link: https://github.com/FrameworkComputer/EmbeddedController/commit/1d7bcf1d50137c8c01969eb65880bc83e424597e
Fixes: 555b5fcdb844 ("mfd: cros_ec: Register charge control subdevice")
Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
---
drivers/mfd/cros_ec_dev.c | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/drivers/mfd/cros_ec_dev.c b/drivers/mfd/cros_ec_dev.c
index 9f84a52b48d6a8994d23edba999398684303ee64..dc80a272726bb16b58253418999021cd56dfd975 100644
--- a/drivers/mfd/cros_ec_dev.c
+++ b/drivers/mfd/cros_ec_dev.c
@@ -87,7 +87,6 @@ static const struct mfd_cell cros_ec_sensorhub_cells[] = {
};
static const struct mfd_cell cros_usbpd_charger_cells[] = {
- { .name = "cros-charge-control", },
{ .name = "cros-usbpd-charger", },
{ .name = "cros-usbpd-logger", },
};
@@ -112,6 +111,10 @@ static const struct mfd_cell cros_ec_ucsi_cells[] = {
{ .name = "cros_ec_ucsi", },
};
+static const struct mfd_cell cros_ec_charge_control_cells[] = {
+ { .name = "cros-charge-control", },
+};
+
static const struct cros_feature_to_cells cros_subdevices[] = {
{
.id = EC_FEATURE_CEC,
@@ -148,6 +151,11 @@ static const struct cros_feature_to_cells cros_subdevices[] = {
.mfd_cells = cros_ec_keyboard_leds_cells,
.num_cells = ARRAY_SIZE(cros_ec_keyboard_leds_cells),
},
+ {
+ .id = EC_FEATURE_CHARGER,
+ .mfd_cells = cros_ec_charge_control_cells,
+ .num_cells = ARRAY_SIZE(cros_ec_charge_control_cells),
+ },
};
static const struct mfd_cell cros_ec_platform_cells[] = {
---
base-commit: 4a95bc121ccdaee04c4d72f84dbfa6b880a514b6
change-id: 20250521-cros-ec-mfd-chctl-probe-64a63ac9c160
Best regards,
--
Thomas Weißschuh <linux@weissschuh.net>
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] mfd: cros_ec: Separate charge-control probing from USB-PD
2025-05-21 14:42 [PATCH] mfd: cros_ec: Separate charge-control probing from USB-PD Thomas Weißschuh
@ 2025-05-28 11:46 ` Tom Vincent
2025-06-13 13:34 ` (subset) " Lee Jones
1 sibling, 0 replies; 3+ messages in thread
From: Tom Vincent @ 2025-05-28 11:46 UTC (permalink / raw)
To: linux; +Cc: bleung, chrome-platform, groeck, lee, linux-kernel
Hi Thomas,
Applied this on top of v6.14.7 with a Framework AI 340, BIOS 3.03 and
cros_charge_control and the knobs now work as expected.
Tested-by: Tom Vincent <linux@tlvince.com>
Thanks,
Tom
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: (subset) [PATCH] mfd: cros_ec: Separate charge-control probing from USB-PD
2025-05-21 14:42 [PATCH] mfd: cros_ec: Separate charge-control probing from USB-PD Thomas Weißschuh
2025-05-28 11:46 ` Tom Vincent
@ 2025-06-13 13:34 ` Lee Jones
1 sibling, 0 replies; 3+ messages in thread
From: Lee Jones @ 2025-06-13 13:34 UTC (permalink / raw)
To: Lee Jones, Benson Leung, Guenter Roeck, Thomas Weißschuh
Cc: chrome-platform, linux-kernel
On Wed, 21 May 2025 16:42:51 +0200, Thomas Weißschuh wrote:
> The charge-control subsystem in the ChromeOS EC is not strictly tied to
> its USB-PD subsystem.
> Since commit 7613bc0d116a ("mfd: cros_ec: Don't load charger with UCSI")
> the presence of EC_FEATURE_UCSI_PPM would inhibit the probing of the
> charge-control driver.
> Furthermore recent versions of the EC firmware in Framework laptops
> hard-disable EC_FEATURE_USB_PD to avoid probing cros-usbpd-charger,
> which then also breaks cros-charge-control.
>
> [...]
Applied, thanks!
[1/1] mfd: cros_ec: Separate charge-control probing from USB-PD
commit: 4752d35dd84ac911b041ef3a53c6d8a32003c26d
--
Lee Jones [李琼斯]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-06-13 13:34 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-05-21 14:42 [PATCH] mfd: cros_ec: Separate charge-control probing from USB-PD Thomas Weißschuh
2025-05-28 11:46 ` Tom Vincent
2025-06-13 13:34 ` (subset) " Lee Jones
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®