On Sat, Nov 14, 2015 at 06:59:16PM +0100, Pavel Machek wrote:
Hi!
If you're asking about the regulator API or embedded ALSA both of those are me but there are other things in here - the driver you're working with and the MFD core at least. At the minute I'm not convinced that the problem here isn't just that the MFD and/or MFD core hasn't set up the mappings to the child devices properly.
Ok, good. I don't understand how the things are expected to fit together. See above. I believe SND_SOC_ macros should have another argument "device", or maybe regulator names should have "device" name embedded in them.
Effectively the device is passed it is just implicit. If you look where the regulator is actually registered in soc-dapm.c
case snd_soc_dapm_regulator_supply: w->regulator = devm_regulator_get(dapm->dev, w->name); if (IS_ERR(w->regulator)) {
You see we are requesting the regulator with the dapm device, which will correspond to the CODEC.
Thanks, Charles