24 Jun
2011
24 Jun
'11
3:37 p.m.
On Thu, Jun 23, 2011 at 01:13:58PM +0200, Raffaele Recalcati wrote:
I have this spi commands in a char driver and I suppose I could leave the protocol there also for making easier the parameteres tuning from user-space and also I could call that commands from snd_soc_codec_set_cache_io function. Any comment?
Are you writing to actual registers? If so just make sure whatever the register format you are using is supported by soc-cache and soc-io and everything will be fine. If you're not writing to actual registers then using the register cache isn't terribly sensible. If your device has broken registers for some reason (variably sized registers for example) then you'll need to open code the I/O in your driver.