lkml.org 
[lkml]   [2015]   [Nov]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] ASoC: Atmel: ClassD: Set GCK's parent clock
From
Date


On 11/21/2015 02:08, Mark Brown wrote:
> On Thu, Nov 19, 2015 at 11:26:30AM +0800, Songjun Wu wrote:
>> Set GCK's parent clock as audio clock, make
>> sure the GCK's parent clock is audio clock.
>
>> + ret = clk_set_parent(dd->gclk, dd->aclk);
>> + if (ret) {
>> + dev_err(dev, "failed to set GCK parent clock: %d\n", ret);
>> + return ret;
>> + }
>
> Why are we doing this in the driver? This should be done by whatever
> creates the clock tree, not by the driver that uses the clocks - that
> way if some future SoC has a different clock tree the driver will
> continue to work.
>

You are right. The GCK's parent clock should be assigned in device tree,
not in the driver. The DT binding for classD should be modified to set
the GCK's parent clock as audio clock.
Thank you.


\
 
 \ /
  Last update: 2015-11-23 04:21    [W:0.081 / U:0.064 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site