[alsa-devel] WM5102 - Help to make baytrail machine driver work

Charles Keepax ckeepax at opensource.wolfsonmicro.com
Thu May 5 11:11:22 CEST 2016


On Wed, May 04, 2016 at 10:21:21PM -0300, Paulo Sergio wrote:
> Hi list,
> 
> I've been trying to make Lenovo Yoga 2 (Model 1051F) sound work on
> Android-x86/ Linux. [1]
> 
> Based on already discussed info from Christian Hartmann with members (see
> [2] and [3] ) of this list and some efforts (basically patch pxa2xx with
> Mika Westerberg changes, set the correct gpio int values {246 for reset /
> 405 for ldoena and 342 for irq_gpio} and set LDO1 vcc suppliers) we could
> have wm5102 initialized through spi / regmap (arizona code on drivers/mfd)
> and register the DAI's.
> 
> I also ported a machine driver code from a kernel Lenovo made available for
> a similar hardware (Lenovo yoga 2 1050 - uses the same baytrail Z3745 and
> wolfson wm5102 audio) [4]
> 
> Although machine driver is registered, we still don't have sound. Tried
> some mixer settings / routes used on raspberry pi, but none help.
> Application (in this case alsa / Android players) returns a "Device or
> resource busy" when trying to ioctl pcm device:

A quick look through your machine driver looks like the parts
relating the CODEC look ok.

I am not so sure about the AP side routing but for the CODEC,

'HPOUT1L Input 1' AIF1RX1
'HPOUT1R Input 1' AIF1RX2
'HPOUT1 Digital Switch' 1

Should be enough to route some audio out the headphones, assuming
AIF1 is connected to the AP and HPOUT1L is the headphones (it is
very rare for people to not wire things up that way so its quite
a good bet, and your machine driver suggests this is how it is
connected).

If you provide some kernel logs with the LOG_DEVICE in
drivers/base/regmap/regmap.c set to the CODEC spi device, I am
happy to sanity check what is going to the CODEC. Although at the
moment I think your issue looks mostly like getting through the
AP side.

Thanks,
Charles


More information about the Alsa-devel mailing list