Good news!
I finally managed to get battery readings! I finally gave up on trying to figure out what is wrong in kernel land and resorted to a userspace implementation. I think the kernel I2C ACPI operation region implementation is not really compatible with the TPT10 ACPI. After implementing my small userspace solution I now have a very vague idea what might be wrong but I need to test this.
Anyway, the userspace program is pretty straight forward once you know what to do. I will post it somewhere soon once I cleaned up the code a bit.
Sound is also making progress! Pierre-Louis Bossart posted two really small patches to the Alsa devel mailinglist that add two quirks to the Intel SST ASOC drivers:
https://www.spinics.net/lists/alsa-devel/msg59183.html
https://www.spinics.net/lists/alsa-devel/msg59184.html
After applying select
config SND_SOC_INTEL_CHT_BSW_RT5672_MACH tristate "ASoC Audio driver for Intel Cherrytrail & Braswell with RT5672 codec"
in your kernel config and it will init and load the firmware (you will need the firmware file intel/fw_sst_22a8.bin).
The ASoC architecture is pretty nifty and complex. It allow to dynamically route audio signals between sources (Frontend, FE) and sinks (Backend, BE). Without any further configs you will find this message in your kernel dmesg when trying to play something (and the app trying to play will fail):
Audio Port: ASoC: no backend DAIs enabled for Audio Port
The routing can be done by alsa_mixer or amixer but there are 276 mixer settings! Which one does one need to change!?
The following two will at least get rid of the above error from dmesg and an app like aplay or mpv will play audio just fine:
amixer sset "media0_out mix 0 media1_in" on amixer sset "codec_out1 mix 0 pcm0_in" on
But still no audio output, neither from the speakers nor from the headphones 🙁 Oh well…
Update: Look at the next post, it’s working now!
BTW, I found that the Broadcom BCM20791 NFC chip in the TPT10 is NFC NCI compatible 🙂