spi: cs42l43: Add GPIO speaker id support to the bridge configuration
authorSimon Trimmer <simont@opensource.cirrus.com>
Tue, 12 Nov 2024 13:14:34 +0000 (13:14 +0000)
committerMark Brown <broonie@kernel.org>
Wed, 13 Nov 2024 13:24:16 +0000 (13:24 +0000)
commitf3c605147741e0ad8f1c51a7decef2040debfd16
treeb3255dad0be8de1fc02b4a9685e86ef10c2f4e0b
parentb1e7828cf9343e1da6c575f3ebaa0f511d8b8cbd
spi: cs42l43: Add GPIO speaker id support to the bridge configuration

OEMs can use the spk-id-gpios ACPI property to indicate the type of
speakers fitted to a device.

Attempt to read a spk-id value using the GPIO method when a usable
spk-id value is not obtained from the 01fa-spk-id-val ACPI property.

Obtaining the spk-id value has been moved earlier in the function to the
other sidecar block, so that an -EPROBE_DEFER from a GPIO driver is
handled more efficiently.

Signed-off-by: Simon Trimmer <simont@opensource.cirrus.com>
Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Link: https://patch.msgid.link/20241112131434.678882-1-ckeepax@opensource.cirrus.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-cs42l43.c