[alsa-devel] [PATCH] firmware: vpd: Add an interface to read VPD value
Srinivas Kandagatla
srinivas.kandagatla at linaro.org
Wed Oct 9 16:05:12 CEST 2019
On 08/10/2019 16:14, Stephen Boyd wrote:
>> 3) As my use case does not use device tree, it is hard for ASoC
>> machine to access nvmem device. I am wondering if I can use
>> nvm_cell_lookup so machine driver can find the nvmem device using a
>> con_id. But currently the cell lookup API requires a matched device,
>> which does not fit my usage because there will be different machine
>> drivers requesting the value.
>> I think I can still workaround this by adding the lookup table in
>> machine driver. This would seem to be a bit weird because I found that
>> most lookup table is added in provider side, not consumer side. Not
>> sure if this is logically correct.
> Maybe Srini has some input here. It looks like your main concern is
> consumer to provider mapping?
>
In non-DT setup, there are various ways to lookup nvmem provider.
1> nvmem_device_get()/put() using provider devid/name. I think you
should be able to use this in your case.
2> nvmem_register_notifier() which notifies when nvmem provider is added
to system.
3> nvmem_device_find() with own match function this will be merged in
next window (https://lkml.org/lkml/2019/10/3/215)
If none of these are of any help, could explain what exactly are you
looking for w.r.t nvmem to be able to move to what Stephen Boyd suggested?
--srini
More information about the Alsa-devel
mailing list