Hi,
I wrote and submitted a few Linux drivers for various features exposed by the Embedded Controller on Framework machines.
They are only tested on my Framework 13 AMD and it would be great to get some more test reports.
All patches should apply cleanly on top of current Linux mainline.
If you want to apply all patches at once there will be conflicts but these are trivial to resolve.
- LED: [PATCH v2 0/5] ChromeOS Embedded Controller LED driver - Thomas Weißschuh
- Charge control: [PATCH v3 0/5] ChromeOS Embedded Controller charge control driver - Thomas Weißschuh
- Keyboard backlight: [PATCH v3 0/4] cros_kbd_led_backlight: allow binding through cros_ec mfd device - Thomas Weißschuh
- [DONE] Sensors: [PATCH v4 0/3] ChromeOS Embedded controller hwmon driver - Thomas Weißschuh
- More sensors: [PATCH 0/5] hwmon: (cros_ec): fan target, fan pwm control and temperature thresholds - Thomas Weißschuh
If you want to be notified about new revisions, let me know.
All of these patches need to be built as part of a kernel tree build,
they can not be used out-of-tree.
These drivers differ from the one of @dhowett in the following ways:
- They are not Framework specific and should work on all machines with a
ChromeOS embedded controller - One module per subsystem instead of one big module.
- The keyboard backlight patch fully reuses an existing driver.
- The LED driver allows to fully shut off the power LED and also to manage the
battery LED, including color, automatic EC control can be enabled/disabled. - The battery control driver also supports charge behaviour (force discharge, inhibit charge)
- The hwmon driver has a simpler implementation and also supports temperature readings.
(It does not yet support fan control but that can be added later, the API provides the feature)
By splitting it up, I hope mainlining will be faster and easier.
Also I guess that the custom Framework APIs will go away at some point as the
upstream CrOS EC APIs provide the same or even more features out of the box.