Hi,
I'm developing a DT-based driver for an ARM SoC device with the following special clock routing:
- WM8758 codec attached to the CPU DAI via I2S - the codec is I2S clock master - the CPU feeds the codec with 12MHz clock (outside of the I2S) - the codec converts the 12MHz internally to 48kHz*256 or 44.1kHz *256 clock and provides it to I2S as MCLK
So the special set-up needed here is that the codec needs to be configured to: a) generate the proper MCLK b) enable the respective GPIO pin as clock output
What is the best way of representing this set-up using device tree? I'm wondering if this can be done by adding a specific option in the codec DT binding for enabling the clock output and then use the simple audio card. Or do I need to write a specific soundcard driver that sets up the codec registers? I would like to avoid that if possible and use existing code...
What would you recommend?
Thanks