On Fri, Sep 08, 2017 at 01:10:12AM +0200, Łukasz Majewski wrote:
> >Just add a property to this cpu node like:
> > clock = <&clks IMX6QDL_CLK_SSI2>;
>
> This doesn't solve the issue:
I have a patch locally that should be able to solve your problem.
But I need to first verify on my board toni
Hi Nicolin,
On Wed, Sep 06, 2017 at 08:35:50PM +0200, Łukasz Majewski wrote:
clocks = <&clks IMX6QDL_CLK_SSI2_IPG>,
<&clks IMX6QDL_CLK_SSI2>;
clock-names = "ipg", "baud";
dailink_master: cpu {
sound-dai =
On Thu, Sep 07, 2017 at 02:44:11PM +0100, Mark Brown wrote:
> > On the other hand, the sys clock (baudclk in the driver) should be
> > configured whenever it's related to external clock outputs. When I
> > implemented this set_sysclk() for fsl_ssi.c, I used it to set this
> > sys clock (baudclk)
On Tue, Sep 05, 2017 at 10:45:29AM -0700, Nicolin Chen wrote:
> The ipg clock is merely used to access registers, and has nothing
> (directly) to do with external clock outputs. The driver shall not
> change the ipg clock as the system ipg clock (its parent clock)
> might be messed and even system
On 09/06/2017 09:47 PM, Nicolin Chen wrote:
On Wed, Sep 06, 2017 at 08:35:50PM +0200, Łukasz Majewski wrote:
clocks = <&clks IMX6QDL_CLK_SSI2_IPG>,
<&clks IMX6QDL_CLK_SSI2>;
clock-names = "ipg", "baud";
dailink_master: cpu {
On Wed, Sep 06, 2017 at 08:35:50PM +0200, Łukasz Majewski wrote:
> clocks = <&clks IMX6QDL_CLK_SSI2_IPG>,
><&clks IMX6QDL_CLK_SSI2>;
> clock-names = "ipg", "baud";
> >>dailink_master: cpu {
> >>sound-dai = <&ssi2>;
> >>
Hi Nicolin,
On Wed, Sep 06, 2017 at 11:22:48AM +0200, Łukasz Majewski wrote:
Here is the routine that I understood from the code:
1) asoc_simple_card_parse_clk_cpu(dev, cpu, dai_link, cpu_dai);
=> asoc_simple_card_parse_clk(dev, cpu,// cpu node in sound{} [1]
On Wed, Sep 06, 2017 at 11:22:48AM +0200, Łukasz Majewski wrote:
> >Here is the routine that I understood from the code:
> >1) asoc_simple_card_parse_clk_cpu(dev, cpu, dai_link, cpu_dai);
> >=> asoc_simple_card_parse_clk(dev, cpu,// cpu node in sound{} [1]
> >
Hi Nicolin,
On Tue, Sep 05, 2017 at 11:13:40PM +0200, Łukasz Majewski wrote:
They key point here is the asoc_simple_card_parse_clk() function
from simple-card-utils.c
Please look how the clock is assigned; It first checks for cpu
clock, then for "system-clock-frequency" DTS node and _finally_
Hi Fabio,
On Tue, Sep 5, 2017 at 6:13 PM, Łukasz Majewski wrote:
&i2c1 {
clock-frequency = <40>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_i2c1>;
status = "okay";
codec: tfa9879@6C {
#sound-dai-cells = <0>;
On Tue, Sep 5, 2017 at 6:13 PM, Łukasz Majewski wrote:
> &i2c1 {
> clock-frequency = <40>;
> pinctrl-names = "default";
> pinctrl-0 = <&pinctrl_i2c1>;
> status = "okay";
>
> codec: tfa9879@6C {
> #sound-dai-cells = <0>;
>
On Tue, Sep 05, 2017 at 11:13:40PM +0200, Łukasz Majewski wrote:
> They key point here is the asoc_simple_card_parse_clk() function
> from simple-card-utils.c
>
> Please look how the clock is assigned; It first checks for cpu
> clock, then for "system-clock-frequency" DTS node and _finally_
> loo
Hi Fabio,
Hi Lukasz,
On Tue, Sep 5, 2017 at 5:35 AM, Łukasz Majewski wrote:
Note:
[*] - I could workaround this problem by setting:
system-clock-frequency = <0> in
dailink_master: cpu {
sound-dai = <&ssi2>;
};
Hi Nicolin,
On Tue, Sep 05, 2017 at 10:35:34AM +0200, Łukasz Majewski wrote:
And apparently, we shouldn't set bitclk to 66MHz either. Can
you help to find where this 66MHz comes from?
2. int asoc_simple_card_init_dai() @ simple-card-utils.c
Oh, I just searched in the simple-card.c but mis
Hi Lukasz,
On Tue, Sep 5, 2017 at 5:35 AM, Łukasz Majewski wrote:
> Note:
> [*] - I could workaround this problem by setting:
>
> system-clock-frequency = <0> in
>
> dailink_master: cpu {
> sound-dai = <&ssi2>;
> };
>
W
On Tue, Sep 05, 2017 at 10:35:34AM +0200, Łukasz Majewski wrote:
> >And apparently, we shouldn't set bitclk to 66MHz either. Can
> >you help to find where this 66MHz comes from?
> 2. int asoc_simple_card_init_dai() @ simple-card-utils.c
Oh, I just searched in the simple-card.c but missed this fi
On Tue, Sep 05, 2017 at 04:15:50PM +0100, Mark Brown wrote:
> > Just to be clear:
>
> > What clock shall be set with:
>
> > struct snd_soc_dai_ops {
> > int (*set_sysclk)(struct snd_soc_dai *dai,
> > int clk_id, unsigned int freq, int dir);
> > }
>
> > callback?
>
> > The SSI
On Tue, Sep 05, 2017 at 10:19:05AM +0200, Łukasz Majewski wrote:
> On 09/05/2017 09:52 AM, Nicolin Chen wrote:
> > Can you elaborate why you set ipg clock as bclk? I don't remember SSI could
> > derive bitclock from ipg clock.
> Just to be clear:
> What clock shall be set with:
> struct snd_soc
On 09/05/2017 07:20 AM, Nicolin Chen wrote:
On Sun, Sep 03, 2017 at 04:40:21PM +0200, Łukasz Majewski wrote:
/*
* Hardware limitation: The bclk rate must be
* never greater than 1/5 IPG clock rate
*/
if (freq * 5 > clk_get_rate(ssi_private->clk)) {
dev_err(cpu_dai->dev, "bitclk > ipgclk/5\n");
r
On 09/05/2017 09:52 AM, Nicolin Chen wrote:
On Tue, Sep 05, 2017 at 09:37:43AM +0200, Łukasz Majewski wrote:
The last call is changing the bit clock (BCLK) frequency to SSI's IP
block clock (ipg = 66 MHz) [1].
I think a bigger question here is why the routine sets BCLK to 66MHz.
Yes, exactl
On Tue, Sep 05, 2017 at 09:37:43AM +0200, Łukasz Majewski wrote:
> >>The last call is changing the bit clock (BCLK) frequency to SSI's IP
> >>block clock (ipg = 66 MHz) [1].
> >
> >I think a bigger question here is why the routine sets BCLK to 66MHz.
>
> Yes, exactly.
>
> In my case the bclk is
On 09/05/2017 07:06 AM, Nicolin Chen wrote:
On Sun, Sep 03, 2017 at 01:05:01PM +0200, Lukasz Majewski wrote:
The problem is visible in the following setup (on the imx6q):
"simple-audio-card" -> ssi2 -> I2S + I2C -> codec
The function call log (simple-card probe -> CONFIG_SND_SIMPLE_CARD):
asoc
On Sun, Sep 03, 2017 at 04:40:21PM +0200, Łukasz Majewski wrote:
> >/*
> >* Hardware limitation: The bclk rate must be
> >* never greater than 1/5 IPG clock rate
> >*/
> >if (freq * 5 > clk_get_rate(ssi_private->clk)) {
> >dev_err(cpu_dai->dev, "bitclk > ipgclk/5\n");
> >return -EINVAL;
> >}
> >
>
On Sun, Sep 03, 2017 at 01:05:01PM +0200, Lukasz Majewski wrote:
> The problem is visible in the following setup (on the imx6q):
> "simple-audio-card" -> ssi2 -> I2S + I2C -> codec
>
> The function call log (simple-card probe -> CONFIG_SND_SIMPLE_CARD):
>
> asoc_simple_card_init_dai() @ sound/soc
On Sun, Sep 3, 2017 at 11:40 AM, Łukasz Majewski wrote:
> This is the part of fsl_ssi_set_bclk() function which is called after
> fsl_ssi_set_dai_sysclk() (which sets ssi_private->bitclk_freq = freq;).
>
> Before the aforementioned check we do have:
>
> if (ssi_private->bitclk_freq)
>
From: Lukasz Majewski
Sent: Sunday, September 3, 2017 8:05:01 AM
To: Timur Tabi; Nicolin Chen; Xiubo Li; Fabio Estevam; Liam Girdwood; Mark
Brown; Jaroslav Kysela; Takashi Iwai
Cc: alsa-de...@alsa-project.org; linuxppc-...@lists.ozlabs.org;
linux-kernel@vger.kernel.org; Lukasz Majewski
The problem is visible in the following setup (on the imx6q):
"simple-audio-card" -> ssi2 -> I2S + I2C -> codec
The function call log (simple-card probe -> CONFIG_SND_SIMPLE_CARD):
asoc_simple_card_init_dai() @ sound/soc/generic/simple-card-utils.c
snd_soc_dai_set_sysclk()
fsl_ssi_set_dai_sysclk(
27 matches
Mail list logo