Skip to contentSkip to conversation

platform/x86: ayaneo-ec: Enable charge control on Flip KB

PATCH In review Hijae Song 3 participants 3 messages Nov 8 – Nov 23

Subsystems (2)
lore
Share & tools
lore

Hijae Song

author
#0 lore raw

PATCH 1/1 platform/x86: ayaneo-ec: Enable charge control on Flip KB

Flip KB was matched to quirk_fan (fan control only), the same quirk used for boards without a working charge-limit EC interface. Testing on real hardware shows the charge-limit register works identically to AIR/AIR 1S/KUN, so switch it to quirk_charge_limit.

Verified on real hardware: switching charge_behaviour to inhibit-charge stops the charge current (status: Not charging,
power_now: 0), and switching back to auto resumes charging.

---
 drivers/platform/x86/ayaneo-ec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/platform/x86/ayaneo-ec.c +1 -1
index 41a24e09..6fe2387d 100644
@@ -88,7 +88,7 @@ static const struct dmi_system_id dmi_table[] = {
 			DMI_MATCH(DMI_BOARD_VENDOR, "AYANEO"),
 			DMI_MATCH(DMI_BOARD_NAME, "FLIP"),
 		},
-		.driver_data = (void *)&quirk_fan,
+		.driver_data = (void *)&quirk_charge_limit,
 	},
 	{
 		.matches = {
Signature · 1 line
2.54.0 (Apple Git-157)
maintainer Reviewed-by on v1 1/1
#1 lore raw
Quoted 11 lines · Hijae Song

Flip KB was matched to quirk_fan (fan control only), the same quirk used for boards without a working charge-limit EC interface. Testing on real hardware shows the charge-limit register works identically to AIR/AIR 1S/KUN, so switch it to quirk_charge_limit.

Verified on real hardware: switching charge_behaviour to inhibit-charge stops the charge current (status: Not charging,
power_now: 0), and switching back to auto resumes charging.

I would have liked a slightly shorter description with the slop " Verified on real hardware:" cut out, but it is not worth resending. Ideally dropping the second paragraph, and swapping "real hardware" with "the device"

Antheas

Quoted 22 lines
---
 drivers/platform/x86/ayaneo-ec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/platform/x86/ayaneo-ec.c +1 -2
index 41a24e09..6fe2387d 100644
@@ -88,7 +88,7 @@ static const struct dmi_system_id dmi_table[] = {
                        DMI_MATCH(DMI_BOARD_VENDOR, "AYANEO"),
                        DMI_MATCH(DMI_BOARD_NAME, "FLIP"),
                },
-               .driver_data = (void *)&quirk_fan,
+               .driver_data = (void *)&quirk_charge_limit,
        },
        {
                .matches = {
--

2.54.0 (Apple Git-157)

maintainer
#2 lore raw
In reply to Hijae Song
Quoted 11 lines · Hijae Song

Flip KB was matched to quirk_fan (fan control only), the same quirk used for boards without a working charge-limit EC interface. Testing on real hardware shows the charge-limit register works identically to AIR/AIR 1S/KUN, so switch it to quirk_charge_limit.

Verified on real hardware: switching charge_behaviour to inhibit-charge stops the charge current (status: Not charging,
power_now: 0), and switching back to auto resumes charging.

[...]

Thank you for your contribution, it has been applied to my local review-ilpo-next branch. Note it will show up in the public platform-drivers-x86/review-ilpo-next branch only once I've pushed my local branch there, which might take a while.

FYI [if applicable to your patch], as per Linus' policy change, also fixes are mostly routed through for-next unless the fix is for a commit introduced in the most recent cycle or is clearly a regression fix.

The list of commits applied:
[1/1] platform/x86: ayaneo-ec: Enable charge control on Flip KB

      commit: 89d070e138afffe8184daf0f5d0f3be013898f37

--
i.