On Fri, Feb 07, 2014 at 01:05:16PM +0800, Sean Cross wrote:
> Novena uses an ES8328 audio codec connected via I2S.

The CODEC looked pretty simple, can this use simple-card?

> +     /* Headphone jack detection */
> +     if (gpio_is_valid(data->jack_gpio)) {
> +             ret = snd_soc_jack_new(rtd->codec, "Headset",
> +                                    SND_JACK_HEADSET | SND_JACK_BTN_0,
> +                                    &headset_jack);
> +             if (ret)
> +                     return ret;
> +
> +             headset_jack_gpios[0].gpio = data->jack_gpio;
> +             ret = snd_soc_jack_add_gpios(&headset_jack,
> +                                          ARRAY_SIZE(headset_jack_gpios),
> +                                          headset_jack_gpios);
> +     }

We'd need to add support for this but that shouldn't be too hard.

> +static int imx_set_frequency(struct imx_novena_data *data, int freq) {
> +     int ret;
> +
> +     ret = clk_set_parent(data->system_cko, data->codec_clk);
> +     if (ret) {
> +             dev_err(data->dev, "unable to set clk output");
> +             return ret;
> +     }
> +
> +     ret = clk_set_parent(data->codec_clk_sel, data->codec_clk_post_div);
> +     if (ret) {
> +             dev_err(data->dev, "unable to set clk parent");
> +             return ret;
> +     }

There's supposed to be support for this sort of thing going into the
clock API with some sort of generic binding.

Attachment: signature.asc
Description: Digital signature

Reply via email to