Re: [PATCH 1/6] ASoC: Intel: soc-acpi-cht: Add Lenovo Yoga Tab 3 Pro YT3-X90 quirk

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On 10/23/23 20:45, Pierre-Louis Bossart wrote:
> 
> 
> On 10/21/23 16:15, Hans de Goede wrote:
>> The Lenovo Yoga Tab 3 Pro YT3-X90 x86 tablet, which ships with Android with
>> a custom kernel as factory OS, does not list the used WM5102 codec inside
>> its DSDT.
>>
>> Workaround this with a new snd_soc_acpi_intel_baytrail_machines[] entry
>> which matches on the SST id instead of the codec id like nocodec does,
>> combined with using a machine_quirk callback which returns NULL on
>> other machines to skip the new entry on other machines.
> 
> The work-around sounds fine, but out of curiosity what causes the codec
> driver to probe if there's no ACPI HID?
> 
> Really wondering how we avoid the -517 error code with the deferred
> probe never completing because the codec driver never probed and
> registered the needed components?


These x86 android tablets ship with pretty broken DSDTs with
A whole bunch of (usually i2c) devices missing like
e.g. the touchscreen and the accelerometer.

For the factory Android install this is not an issue because
it uses drivers which instantiate the i2c-clients itself using
hardcoded i2c-bus, i2c-address and irqs.

To make this work under Linux I've written a special helper
"driver" which loads only on these broken DSDT devices
based on DMI modalias and then identifies the exact
model (also by DMI) and instantiates the correct devices
from this "driver" (really more of an old fashioned
board file). This code also adds all the necessary
properties, etc. to make standard drivers work, so all
model specific knowledge missing from the DSDT is encoded
in this special x86-android-tablets driver.

I've also submitted a patch for that driver to instantiate
the codec SPI device using spi_device_id matching instead
of acpi_device_id matching:

https://lore.kernel.org/platform-driver-x86/20231014205314.59333-5-hdegoede@xxxxxxxxxx/

So this is the other side of the puzzle, I hope this
helps explain how I actually got this working.

Regards,

Hans





[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux