Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1574958
| From | Mark Brown <broonie@kernel.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH v1 3/3] ASoC: zx-i2s: support zx296718 SoC for ZTE's i2s controller driver |
| Date | 2017-02-06 17:30 +0100 |
| Message-ID | <t7UkW-7hD-15@gated-at.bofh.it> (permalink) |
| References | <t7RZM-5F5-23@gated-at.bofh.it> <t7RZM-5F5-35@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
[Multipart message — attachments visible in raw view] - view raw
On Mon, Feb 06, 2017 at 09:50:20PM +0800, Baoyou Xie wrote:
> +static void zx_i2s_set_clk(struct zx_i2s_info *i2s,
> + unsigned int ch_num, unsigned int sample_rate)
> +{
> + unsigned long val = sample_rate * ch_num * CLK_RAT;
> +
> + clk_set_rate(i2s->dai_wclk, val);
> +
> + if (i2s->dai_pclk)
> + clk_set_rate(i2s->dai_pclk, val);
> +}
There's no error checking here, if we don't care if these calls succeed
we could save some power and not enable the clocks. This function is
also very small and has exactly one user so it's not clear why it's
split out.
> static const struct of_device_id zx_i2s_dt_ids[] = {
> { .compatible = "zte,zx296702-i2s", },
> + { .compatible = "zte,zx296718-i2s", },
> {}
> };
> MODULE_DEVICE_TABLE(of, zx_i2s_dt_ids);
This adds a new DT binding but does not update the binding document.
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH v1 3/3] ASoC: zx-i2s: support zx296718 SoC for ZTE's i2s controller driver Baoyou Xie <baoyou.xie@linaro.org> - 2017-02-06 15:00 +0100 Re: [PATCH v1 3/3] ASoC: zx-i2s: support zx296718 SoC for ZTE's i2s controller driver Mark Brown <broonie@kernel.org> - 2017-02-06 17:30 +0100
csiph-web