All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
       [not found] <1575600438-26795-1-git-send-email-skomatineni@nvidia.com>
@ 2019-12-06  2:47 ` Sowjanya Komatineni
  2019-12-06  7:09   ` Greg KH
  0 siblings, 1 reply; 18+ messages in thread
From: Sowjanya Komatineni @ 2019-12-06  2:47 UTC (permalink / raw)
  To: skomatineni; +Cc: stable

mclk is from clk_out_1 which is part of Tegra PMC block and pmc clocks
are moved to Tegra PMC driver with pmc as clock provider and using pmc
clock ids.

New device tree uses clk_out_1 from pmc clock provider.

So, this patch adds fallback to extern1 in case of retrieving mclk fails
to be backward compatible of new device tree with older kernels.

Cc: stable@vger.kernel.org

Signed-off-by: Sowjanya Komatineni <skomatineni@nvidia.com>
---
 sound/soc/tegra/tegra_asoc_utils.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/sound/soc/tegra/tegra_asoc_utils.c b/sound/soc/tegra/tegra_asoc_utils.c
index 8e3a3740df7c..f7408d5240c0 100644
--- a/sound/soc/tegra/tegra_asoc_utils.c
+++ b/sound/soc/tegra/tegra_asoc_utils.c
@@ -211,8 +211,14 @@ int tegra_asoc_utils_init(struct tegra_asoc_utils_data *data,
 	data->clk_cdev1 = clk_get(dev, "mclk");
 	if (IS_ERR(data->clk_cdev1)) {
 		dev_err(data->dev, "Can't retrieve clk cdev1\n");
-		ret = PTR_ERR(data->clk_cdev1);
-		goto err_put_pll_a_out0;
+		data->clk_cdev1 = clk_get_sys("clk_out_1", "extern1");
+		if (IS_ERR(data->clk_cdev1)) {
+			dev_err(data->dev, "Can't retrieve clk extern1\n");
+			ret = PTR_ERR(data->clk_cdev1);
+			goto err_put_pll_a_out0;
+		}
+
+		dev_err(data->dev, "Falling back to extern1\n");
 	}
 
 	/*
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-06  2:47 ` [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk Sowjanya Komatineni
@ 2019-12-06  7:09   ` Greg KH
  2019-12-06 16:19     ` Sowjanya Komatineni
  0 siblings, 1 reply; 18+ messages in thread
From: Greg KH @ 2019-12-06  7:09 UTC (permalink / raw)
  To: Sowjanya Komatineni; +Cc: stable

On Thu, Dec 05, 2019 at 06:47:12PM -0800, Sowjanya Komatineni wrote:
> mclk is from clk_out_1 which is part of Tegra PMC block and pmc clocks
> are moved to Tegra PMC driver with pmc as clock provider and using pmc
> clock ids.
> 
> New device tree uses clk_out_1 from pmc clock provider.
> 
> So, this patch adds fallback to extern1 in case of retrieving mclk fails
> to be backward compatible of new device tree with older kernels.
> 
> Cc: stable@vger.kernel.org
> 
> Signed-off-by: Sowjanya Komatineni <skomatineni@nvidia.com>
> ---
>  sound/soc/tegra/tegra_asoc_utils.c | 10 ++++++++--
>  1 file changed, 8 insertions(+), 2 deletions(-)

<formletter>

This is not the correct way to submit patches for inclusion in the
stable kernel tree.  Please read:
    https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html
for how to do this properly.

</formletter>

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-06  7:09   ` Greg KH
@ 2019-12-06 16:19     ` Sowjanya Komatineni
  2019-12-06 16:29       ` Greg KH
  0 siblings, 1 reply; 18+ messages in thread
From: Sowjanya Komatineni @ 2019-12-06 16:19 UTC (permalink / raw)
  To: Greg KH; +Cc: stable


On 12/5/19 11:09 PM, Greg KH wrote:
> On Thu, Dec 05, 2019 at 06:47:12PM -0800, Sowjanya Komatineni wrote:
>> mclk is from clk_out_1 which is part of Tegra PMC block and pmc clocks
>> are moved to Tegra PMC driver with pmc as clock provider and using pmc
>> clock ids.
>>
>> New device tree uses clk_out_1 from pmc clock provider.
>>
>> So, this patch adds fallback to extern1 in case of retrieving mclk fails
>> to be backward compatible of new device tree with older kernels.
>>
>> Cc: stable@vger.kernel.org
>>
>> Signed-off-by: Sowjanya Komatineni <skomatineni@nvidia.com>
>> ---
>>   sound/soc/tegra/tegra_asoc_utils.c | 10 ++++++++--
>>   1 file changed, 8 insertions(+), 2 deletions(-)
> <formletter>
>
> This is not the correct way to submit patches for inclusion in the
> stable kernel tree.  Please read:
>      https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html
> for how to do this properly.
>
> </formletter>

Hi Greg,

link says to option-1 is strongly preferred for for all patches except 
for submissions that are not in net/ and security related.

Option-1 is to add Cc: stable@vger.kernel.org in sign-off area and I 
followed this.

Please help if I miss understood your feedback.

Thanks



-----------------------------------------------------------------------------------
This email message is for the sole use of the intended recipient(s) and may contain
confidential information.  Any unauthorized review, use, disclosure or distribution
is prohibited.  If you are not the intended recipient, please contact the sender by
reply email and destroy all copies of the original message.
-----------------------------------------------------------------------------------

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-06 16:19     ` Sowjanya Komatineni
@ 2019-12-06 16:29       ` Greg KH
  2019-12-06 17:11         ` Sowjanya Komatineni
  0 siblings, 1 reply; 18+ messages in thread
From: Greg KH @ 2019-12-06 16:29 UTC (permalink / raw)
  To: Sowjanya Komatineni; +Cc: stable

On Fri, Dec 06, 2019 at 08:19:26AM -0800, Sowjanya Komatineni wrote:
> 
> On 12/5/19 11:09 PM, Greg KH wrote:
> > On Thu, Dec 05, 2019 at 06:47:12PM -0800, Sowjanya Komatineni wrote:
> > > mclk is from clk_out_1 which is part of Tegra PMC block and pmc clocks
> > > are moved to Tegra PMC driver with pmc as clock provider and using pmc
> > > clock ids.
> > > 
> > > New device tree uses clk_out_1 from pmc clock provider.
> > > 
> > > So, this patch adds fallback to extern1 in case of retrieving mclk fails
> > > to be backward compatible of new device tree with older kernels.
> > > 
> > > Cc: stable@vger.kernel.org
> > > 
> > > Signed-off-by: Sowjanya Komatineni <skomatineni@nvidia.com>
> > > ---
> > >   sound/soc/tegra/tegra_asoc_utils.c | 10 ++++++++--
> > >   1 file changed, 8 insertions(+), 2 deletions(-)
> > <formletter>
> > 
> > This is not the correct way to submit patches for inclusion in the
> > stable kernel tree.  Please read:
> >      https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html
> > for how to do this properly.
> > 
> > </formletter>
> 
> Hi Greg,
> 
> link says to option-1 is strongly preferred for for all patches except for
> submissions that are not in net/ and security related.
> 
> Option-1 is to add Cc: stable@vger.kernel.org in sign-off area and I
> followed this.

That's fine, but then why did you just email a patch to yourself and the
list?  Shouldn't you also submit the patch upstream to get it properly
merged first?

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-06 16:29       ` Greg KH
@ 2019-12-06 17:11         ` Sowjanya Komatineni
  2019-12-06 17:15           ` Sowjanya Komatineni
  0 siblings, 1 reply; 18+ messages in thread
From: Sowjanya Komatineni @ 2019-12-06 17:11 UTC (permalink / raw)
  To: Greg KH; +Cc: stable


On 12/6/19 8:29 AM, Greg KH wrote:
> On Fri, Dec 06, 2019 at 08:19:26AM -0800, Sowjanya Komatineni wrote:
>> On 12/5/19 11:09 PM, Greg KH wrote:
>>> On Thu, Dec 05, 2019 at 06:47:12PM -0800, Sowjanya Komatineni wrote:
>>>> mclk is from clk_out_1 which is part of Tegra PMC block and pmc clocks
>>>> are moved to Tegra PMC driver with pmc as clock provider and using pmc
>>>> clock ids.
>>>>
>>>> New device tree uses clk_out_1 from pmc clock provider.
>>>>
>>>> So, this patch adds fallback to extern1 in case of retrieving mclk fails
>>>> to be backward compatible of new device tree with older kernels.
>>>>
>>>> Cc: stable@vger.kernel.org
>>>>
>>>> Signed-off-by: Sowjanya Komatineni <skomatineni@nvidia.com>
>>>> ---
>>>>    sound/soc/tegra/tegra_asoc_utils.c | 10 ++++++++--
>>>>    1 file changed, 8 insertions(+), 2 deletions(-)
>>> <formletter>
>>>
>>> This is not the correct way to submit patches for inclusion in the
>>> stable kernel tree.  Please read:
>>>       https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html
>>> for how to do this properly.
>>>
>>> </formletter>
>> Hi Greg,
>>
>> link says to option-1 is strongly preferred for for all patches except for
>> submissions that are not in net/ and security related.
>>
>> Option-1 is to add Cc: stable@vger.kernel.org in sign-off area and I
>> followed this.
> That's fine, but then why did you just email a patch to yourself and the
> list?  Shouldn't you also submit the patch upstream to get it properly
> merged first?
>
> thanks,
>
> greg k-h

I set patches to the mailing list as per get_maintainers script.

Do I need to add any other alias to get patch applied for stable kernel 
other than cc tag?




-----------------------------------------------------------------------------------
This email message is for the sole use of the intended recipient(s) and may contain
confidential information.  Any unauthorized review, use, disclosure or distribution
is prohibited.  If you are not the intended recipient, please contact the sender by
reply email and destroy all copies of the original message.
-----------------------------------------------------------------------------------

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-06 17:11         ` Sowjanya Komatineni
@ 2019-12-06 17:15           ` Sowjanya Komatineni
  2019-12-06 17:55             ` Greg KH
  0 siblings, 1 reply; 18+ messages in thread
From: Sowjanya Komatineni @ 2019-12-06 17:15 UTC (permalink / raw)
  To: Greg KH; +Cc: stable


On 12/6/19 9:11 AM, Sowjanya Komatineni wrote:
>
> On 12/6/19 8:29 AM, Greg KH wrote:
>> On Fri, Dec 06, 2019 at 08:19:26AM -0800, Sowjanya Komatineni wrote:
>>> On 12/5/19 11:09 PM, Greg KH wrote:
>>>> On Thu, Dec 05, 2019 at 06:47:12PM -0800, Sowjanya Komatineni wrote:
>>>>> mclk is from clk_out_1 which is part of Tegra PMC block and pmc 
>>>>> clocks
>>>>> are moved to Tegra PMC driver with pmc as clock provider and using 
>>>>> pmc
>>>>> clock ids.
>>>>>
>>>>> New device tree uses clk_out_1 from pmc clock provider.
>>>>>
>>>>> So, this patch adds fallback to extern1 in case of retrieving mclk 
>>>>> fails
>>>>> to be backward compatible of new device tree with older kernels.
>>>>>
>>>>> Cc: stable@vger.kernel.org
>>>>>
>>>>> Signed-off-by: Sowjanya Komatineni <skomatineni@nvidia.com>
>>>>> ---
>>>>>    sound/soc/tegra/tegra_asoc_utils.c | 10 ++++++++--
>>>>>    1 file changed, 8 insertions(+), 2 deletions(-)
>>>> <formletter>
>>>>
>>>> This is not the correct way to submit patches for inclusion in the
>>>> stable kernel tree.  Please read:
>>>> https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html 
>>>>
>>>> for how to do this properly.
>>>>
>>>> </formletter>
>>> Hi Greg,
>>>
>>> link says to option-1 is strongly preferred for for all patches 
>>> except for
>>> submissions that are not in net/ and security related.
>>>
>>> Option-1 is to add Cc: stable@vger.kernel.org in sign-off area and I
>>> followed this.
>> That's fine, but then why did you just email a patch to yourself and the
>> list?  Shouldn't you also submit the patch upstream to get it properly
>> merged first?
>>
>> thanks,
>>
>> greg k-h
>
> I set patches to the mailing list as per get_maintainers script.
>
> Do I need to add any other alias to get patch applied for stable 
> kernel other than cc tag?
>
Does this patch need to be sent separate to upstream (not part of this 
series) with cc stable tag?
-----------------------------------------------------------------------------------
This email message is for the sole use of the intended recipient(s) and may contain
confidential information.  Any unauthorized review, use, disclosure or distribution
is prohibited.  If you are not the intended recipient, please contact the sender by
reply email and destroy all copies of the original message.
-----------------------------------------------------------------------------------

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-06 17:15           ` Sowjanya Komatineni
@ 2019-12-06 17:55             ` Greg KH
  0 siblings, 0 replies; 18+ messages in thread
From: Greg KH @ 2019-12-06 17:55 UTC (permalink / raw)
  To: Sowjanya Komatineni; +Cc: stable

On Fri, Dec 06, 2019 at 09:15:20AM -0800, Sowjanya Komatineni wrote:
> -----------------------------------------------------------------------------------
> This email message is for the sole use of the intended recipient(s) and may contain
> confidential information.  Any unauthorized review, use, disclosure or distribution
> is prohibited.  If you are not the intended recipient, please contact the sender by
> reply email and destroy all copies of the original message.
> -----------------------------------------------------------------------------------

Now deleted, this is not compatible with public mailing lists, sorry.

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-10 18:59           ` Mark Brown
@ 2019-12-12  2:17             ` Dmitry Osipenko
  0 siblings, 0 replies; 18+ messages in thread
From: Dmitry Osipenko @ 2019-12-12  2:17 UTC (permalink / raw)
  To: Mark Brown
  Cc: robh+dt, mark.rutland, Sowjanya Komatineni, thierry.reding,
	jonathanh, mperttunen, gregkh, sboyd, tglx, allison,
	pdeschrijver, pgaikwad, mturquette, horms+renesas, Jisheng.Zhang,
	krzk, arnd, spujar, josephl, vidyas, daniel.lezcano, mmaddireddy,
	markz, devicetree, linux-clk, linux-tegra, linux-kernel,
	lgirdwood, perex, tiwai, alexios.zavras, alsa-devel

10.12.2019 21:59, Mark Brown пишет:
> On Tue, Dec 10, 2019 at 09:24:43PM +0300, Dmitry Osipenko wrote:
> 
>> In some cases it could be painful to maintain device-tree compatibility
>> for platforms like NVIDIA Tegra SoCs because hardware wasn't modeled
>> correctly from the start.
> 
>> I agree that people should use relevant device-trees. It's quite a lot
>> of hassle to care about compatibility for platforms that are permanently
>> in a development state. It could be more reasonable to go through the
>> pain if kernel required a full-featured device tree for every SoC from
>> the start.
> 
> We absolutely should support the newer kernel with older device tree
> case, what's less clear to me is the new device tree with old kernel
> which is applying LTS updates case.  That does seem incredibly
> specialist - I'd honestly never heard of people doing that before this
> thread.
> 

There was a precedent in the past [1].

[1] https://lkml.org/lkml/2018/8/20/497

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-10 18:24         ` Dmitry Osipenko
@ 2019-12-10 18:59           ` Mark Brown
  2019-12-12  2:17             ` Dmitry Osipenko
  0 siblings, 1 reply; 18+ messages in thread
From: Mark Brown @ 2019-12-10 18:59 UTC (permalink / raw)
  To: Dmitry Osipenko
  Cc: robh+dt, mark.rutland, Sowjanya Komatineni, thierry.reding,
	jonathanh, mperttunen, gregkh, sboyd, tglx, allison,
	pdeschrijver, pgaikwad, mturquette, horms+renesas, Jisheng.Zhang,
	krzk, arnd, spujar, josephl, vidyas, daniel.lezcano, mmaddireddy,
	markz, devicetree, linux-clk, linux-tegra, linux-kernel,
	lgirdwood, perex, tiwai, alexios.zavras, alsa-devel

[-- Attachment #1: Type: text/plain, Size: 827 bytes --]

On Tue, Dec 10, 2019 at 09:24:43PM +0300, Dmitry Osipenko wrote:

> In some cases it could be painful to maintain device-tree compatibility
> for platforms like NVIDIA Tegra SoCs because hardware wasn't modeled
> correctly from the start.

> I agree that people should use relevant device-trees. It's quite a lot
> of hassle to care about compatibility for platforms that are permanently
> in a development state. It could be more reasonable to go through the
> pain if kernel required a full-featured device tree for every SoC from
> the start.

We absolutely should support the newer kernel with older device tree
case, what's less clear to me is the new device tree with old kernel
which is applying LTS updates case.  That does seem incredibly
specialist - I'd honestly never heard of people doing that before this
thread.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-09 20:47       ` Mark Brown
@ 2019-12-10 18:24         ` Dmitry Osipenko
  2019-12-10 18:59           ` Mark Brown
  0 siblings, 1 reply; 18+ messages in thread
From: Dmitry Osipenko @ 2019-12-10 18:24 UTC (permalink / raw)
  To: Mark Brown, robh+dt, mark.rutland
  Cc: Sowjanya Komatineni, thierry.reding, jonathanh, mperttunen,
	gregkh, sboyd, tglx, allison, pdeschrijver, pgaikwad, mturquette,
	horms+renesas, Jisheng.Zhang, krzk, arnd, spujar, josephl,
	vidyas, daniel.lezcano, mmaddireddy, markz, devicetree,
	linux-clk, linux-tegra, linux-kernel, lgirdwood, perex, tiwai,
	alexios.zavras, alsa-devel

09.12.2019 23:47, Mark Brown пишет:
> On Mon, Dec 09, 2019 at 11:31:59PM +0300, Dmitry Osipenko wrote:
>> 09.12.2019 19:40, Mark Brown пишет:
> 
>>> Why would this need to be a stable fix?  Presumably people with stable
>>> kernels are using the old device tree anyway?
> 
>> At least Rob Herring is asking to maintain backwards compatibility
>> because some ditros are using newer device-trees with stable kernels.
> 
> You're talking about forwards compatibility not backwards here.  Are
> those distros actually using LTS kernels?

I think openSUSE Leap could be one of those distros that use LTS kernel
with newer device-trees, but that's not 100%. Maybe Rob could help
clarifying that.

>> I'm personally also tending to use the newer DTB with older kernel
>> version whenever there is a need to check something using stable kernel.
>> Perhaps losing sound is not very important, but will be nicer if that
>> doesn't happen.
> 
> That really does sound like a "you broke it, you get all the pieces"
> situation TBH...  I'd be a lot more comfortable if the stable kernels
> were sticking to bugfix only though I do appreciate that they're not
> really that any more.

In some cases it could be painful to maintain device-tree compatibility
for platforms like NVIDIA Tegra SoCs because hardware wasn't modeled
correctly from the start.

I agree that people should use relevant device-trees. It's quite a lot
of hassle to care about compatibility for platforms that are permanently
in a development state. It could be more reasonable to go through the
pain if kernel required a full-featured device tree for every SoC from
the start.

But maybe Tegra / device-tree maintainers have a different opinion.
IIUC, device-trees are meant to be stable and software-agnostic, at
least that was the case not so long time ago and I don't think that this
premise changed.

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-09 20:31     ` Dmitry Osipenko
@ 2019-12-09 20:47       ` Mark Brown
  2019-12-10 18:24         ` Dmitry Osipenko
  0 siblings, 1 reply; 18+ messages in thread
From: Mark Brown @ 2019-12-09 20:47 UTC (permalink / raw)
  To: Dmitry Osipenko
  Cc: Sowjanya Komatineni, thierry.reding, jonathanh, mperttunen,
	gregkh, sboyd, tglx, robh+dt, mark.rutland, allison,
	pdeschrijver, pgaikwad, mturquette, horms+renesas, Jisheng.Zhang,
	krzk, arnd, spujar, josephl, vidyas, daniel.lezcano, mmaddireddy,
	markz, devicetree, linux-clk, linux-tegra, linux-kernel,
	lgirdwood, perex, tiwai, alexios.zavras, alsa-devel

[-- Attachment #1: Type: text/plain, Size: 975 bytes --]

On Mon, Dec 09, 2019 at 11:31:59PM +0300, Dmitry Osipenko wrote:
> 09.12.2019 19:40, Mark Brown пишет:

> > Why would this need to be a stable fix?  Presumably people with stable
> > kernels are using the old device tree anyway?

> At least Rob Herring is asking to maintain backwards compatibility
> because some ditros are using newer device-trees with stable kernels.

You're talking about forwards compatibility not backwards here.  Are
those distros actually using LTS kernels?

> I'm personally also tending to use the newer DTB with older kernel
> version whenever there is a need to check something using stable kernel.
> Perhaps losing sound is not very important, but will be nicer if that
> doesn't happen.

That really does sound like a "you broke it, you get all the pieces"
situation TBH...  I'd be a lot more comfortable if the stable kernels
were sticking to bugfix only though I do appreciate that they're not
really that any more.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-09 16:40   ` Mark Brown
@ 2019-12-09 20:31     ` Dmitry Osipenko
  2019-12-09 20:47       ` Mark Brown
  0 siblings, 1 reply; 18+ messages in thread
From: Dmitry Osipenko @ 2019-12-09 20:31 UTC (permalink / raw)
  To: Mark Brown, Sowjanya Komatineni
  Cc: thierry.reding, jonathanh, mperttunen, gregkh, sboyd, tglx,
	robh+dt, mark.rutland, allison, pdeschrijver, pgaikwad,
	mturquette, horms+renesas, Jisheng.Zhang, krzk, arnd, spujar,
	josephl, vidyas, daniel.lezcano, mmaddireddy, markz, devicetree,
	linux-clk, linux-tegra, linux-kernel, lgirdwood, perex, tiwai,
	alexios.zavras, alsa-devel

09.12.2019 19:40, Mark Brown пишет:
> On Thu, Dec 05, 2019 at 06:48:49PM -0800, Sowjanya Komatineni wrote:
>> mclk is from clk_out_1 which is part of Tegra PMC block and pmc clocks
>> are moved to Tegra PMC driver with pmc as clock provider and using pmc
>> clock ids.
>>
>> New device tree uses clk_out_1 from pmc clock provider.
>>
>> So, this patch adds fallback to extern1 in case of retrieving mclk fails
>> to be backward compatible of new device tree with older kernels.
>>
>> Cc: stable@vger.kernel.org
> 
> Why would this need to be a stable fix?  Presumably people with stable
> kernels are using the old device tree anyway?
> 

Presumably, yes.

At least Rob Herring is asking to maintain backwards compatibility
because some ditros are using newer device-trees with stable kernels.
I'm personally also tending to use the newer DTB with older kernel
version whenever there is a need to check something using stable kernel.
Perhaps losing sound is not very important, but will be nicer if that
doesn't happen.

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-06  2:48   ` Sowjanya Komatineni
  (?)
  (?)
@ 2019-12-09 16:40   ` Mark Brown
  2019-12-09 20:31     ` Dmitry Osipenko
  -1 siblings, 1 reply; 18+ messages in thread
From: Mark Brown @ 2019-12-09 16:40 UTC (permalink / raw)
  To: Sowjanya Komatineni
  Cc: thierry.reding, jonathanh, digetx, mperttunen, gregkh, sboyd,
	tglx, robh+dt, mark.rutland, allison, pdeschrijver, pgaikwad,
	mturquette, horms+renesas, Jisheng.Zhang, krzk, arnd, spujar,
	josephl, vidyas, daniel.lezcano, mmaddireddy, markz, devicetree,
	linux-clk, linux-tegra, linux-kernel, lgirdwood, perex, tiwai,
	alexios.zavras, alsa-devel

[-- Attachment #1: Type: text/plain, Size: 598 bytes --]

On Thu, Dec 05, 2019 at 06:48:49PM -0800, Sowjanya Komatineni wrote:
> mclk is from clk_out_1 which is part of Tegra PMC block and pmc clocks
> are moved to Tegra PMC driver with pmc as clock provider and using pmc
> clock ids.
> 
> New device tree uses clk_out_1 from pmc clock provider.
> 
> So, this patch adds fallback to extern1 in case of retrieving mclk fails
> to be backward compatible of new device tree with older kernels.
> 
> Cc: stable@vger.kernel.org

Why would this need to be a stable fix?  Presumably people with stable
kernels are using the old device tree anyway?

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-06 17:49     ` Sowjanya Komatineni
  (?)
@ 2019-12-06 17:56     ` Greg KH
  -1 siblings, 0 replies; 18+ messages in thread
From: Greg KH @ 2019-12-06 17:56 UTC (permalink / raw)
  To: Sowjanya Komatineni
  Cc: thierry.reding, jonathanh, digetx, mperttunen, sboyd, tglx,
	robh+dt, mark.rutland, allison, pdeschrijver, pgaikwad,
	mturquette, horms+renesas, Jisheng.Zhang, krzk, arnd, spujar,
	josephl, vidyas, daniel.lezcano, mmaddireddy, markz, devicetree,
	linux-clk, linux-tegra, linux-kernel, lgirdwood, broonie, perex,
	tiwai, alexios.zavras, alsa-devel

On Fri, Dec 06, 2019 at 09:49:49AM -0800, Sowjanya Komatineni wrote:
> Thanks Greg.
> 
> Sorry, Will send this patch separately (out of this series) with stable tag
> to get this applied to stable kernels once review is done for this series.

Why not just properly add the tag in the original patch when it gets
merged?  That's how everyone else does it :)

This isn't new, it's been happening this way for 12+ years now...

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-06  2:48   ` Sowjanya Komatineni
@ 2019-12-06 17:49     ` Sowjanya Komatineni
  -1 siblings, 0 replies; 18+ messages in thread
From: Sowjanya Komatineni @ 2019-12-06 17:49 UTC (permalink / raw)
  To: thierry.reding, jonathanh, digetx, mperttunen, gregkh, sboyd,
	tglx, robh+dt, mark.rutland
  Cc: allison, pdeschrijver, pgaikwad, mturquette, horms+renesas,
	Jisheng.Zhang, krzk, arnd, spujar, josephl, vidyas,
	daniel.lezcano, mmaddireddy, markz, devicetree, linux-clk,
	linux-tegra, linux-kernel, lgirdwood, broonie, perex, tiwai,
	alexios.zavras, alsa-devel

Thanks Greg.

Sorry, Will send this patch separately (out of this series) with stable 
tag to get this applied to stable kernels once review is done for this 
series.

On 12/5/19 6:48 PM, Sowjanya Komatineni wrote:
> mclk is from clk_out_1 which is part of Tegra PMC block and pmc clocks
> are moved to Tegra PMC driver with pmc as clock provider and using pmc
> clock ids.
>
> New device tree uses clk_out_1 from pmc clock provider.
>
> So, this patch adds fallback to extern1 in case of retrieving mclk fails
> to be backward compatible of new device tree with older kernels.
>
> Cc: stable@vger.kernel.org
>
> Signed-off-by: Sowjanya Komatineni <skomatineni@nvidia.com>
> ---
>   sound/soc/tegra/tegra_asoc_utils.c | 10 ++++++++--
>   1 file changed, 8 insertions(+), 2 deletions(-)
>
> diff --git a/sound/soc/tegra/tegra_asoc_utils.c b/sound/soc/tegra/tegra_asoc_utils.c
> index 8e3a3740df7c..f7408d5240c0 100644
> --- a/sound/soc/tegra/tegra_asoc_utils.c
> +++ b/sound/soc/tegra/tegra_asoc_utils.c
> @@ -211,8 +211,14 @@ int tegra_asoc_utils_init(struct tegra_asoc_utils_data *data,
>   	data->clk_cdev1 = clk_get(dev, "mclk");
>   	if (IS_ERR(data->clk_cdev1)) {
>   		dev_err(data->dev, "Can't retrieve clk cdev1\n");
> -		ret = PTR_ERR(data->clk_cdev1);
> -		goto err_put_pll_a_out0;
> +		data->clk_cdev1 = clk_get_sys("clk_out_1", "extern1");
> +		if (IS_ERR(data->clk_cdev1)) {
> +			dev_err(data->dev, "Can't retrieve clk extern1\n");
> +			ret = PTR_ERR(data->clk_cdev1);
> +			goto err_put_pll_a_out0;
> +		}
> +
> +		dev_err(data->dev, "Falling back to extern1\n");
>   	}
>   
>   	/*

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
@ 2019-12-06 17:49     ` Sowjanya Komatineni
  0 siblings, 0 replies; 18+ messages in thread
From: Sowjanya Komatineni @ 2019-12-06 17:49 UTC (permalink / raw)
  To: thierry.reding, jonathanh, digetx, mperttunen, gregkh, sboyd,
	tglx, robh+dt, mark.rutland
  Cc: allison, pdeschrijver, pgaikwad, mturquette, horms+renesas,
	Jisheng.Zhang, krzk, arnd, spujar, josephl, vidyas,
	daniel.lezcano, mmaddireddy, markz, devicetree, linux-clk,
	linux-tegra, linux-kernel, lgirdwood, broonie, perex, tiwai,
	alexios.zavras, alsa-devel

Thanks Greg.

Sorry, Will send this patch separately (out of this series) with stable 
tag to get this applied to stable kernels once review is done for this 
series.

On 12/5/19 6:48 PM, Sowjanya Komatineni wrote:
> mclk is from clk_out_1 which is part of Tegra PMC block and pmc clocks
> are moved to Tegra PMC driver with pmc as clock provider and using pmc
> clock ids.
>
> New device tree uses clk_out_1 from pmc clock provider.
>
> So, this patch adds fallback to extern1 in case of retrieving mclk fails
> to be backward compatible of new device tree with older kernels.
>
> Cc: stable@vger.kernel.org
>
> Signed-off-by: Sowjanya Komatineni <skomatineni@nvidia.com>
> ---
>   sound/soc/tegra/tegra_asoc_utils.c | 10 ++++++++--
>   1 file changed, 8 insertions(+), 2 deletions(-)
>
> diff --git a/sound/soc/tegra/tegra_asoc_utils.c b/sound/soc/tegra/tegra_asoc_utils.c
> index 8e3a3740df7c..f7408d5240c0 100644
> --- a/sound/soc/tegra/tegra_asoc_utils.c
> +++ b/sound/soc/tegra/tegra_asoc_utils.c
> @@ -211,8 +211,14 @@ int tegra_asoc_utils_init(struct tegra_asoc_utils_data *data,
>   	data->clk_cdev1 = clk_get(dev, "mclk");
>   	if (IS_ERR(data->clk_cdev1)) {
>   		dev_err(data->dev, "Can't retrieve clk cdev1\n");
> -		ret = PTR_ERR(data->clk_cdev1);
> -		goto err_put_pll_a_out0;
> +		data->clk_cdev1 = clk_get_sys("clk_out_1", "extern1");
> +		if (IS_ERR(data->clk_cdev1)) {
> +			dev_err(data->dev, "Can't retrieve clk extern1\n");
> +			ret = PTR_ERR(data->clk_cdev1);
> +			goto err_put_pll_a_out0;
> +		}
> +
> +		dev_err(data->dev, "Falling back to extern1\n");
>   	}
>   
>   	/*

^ permalink raw reply	[flat|nested] 18+ messages in thread

* [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
  2019-12-06  2:48 [PATCH v3 00/15] Move PMC clocks into Tegra PMC driver Sowjanya Komatineni
@ 2019-12-06  2:48   ` Sowjanya Komatineni
  0 siblings, 0 replies; 18+ messages in thread
From: Sowjanya Komatineni @ 2019-12-06  2:48 UTC (permalink / raw)
  To: skomatineni, thierry.reding, jonathanh, digetx, mperttunen,
	gregkh, sboyd, tglx, robh+dt, mark.rutland
  Cc: allison, pdeschrijver, pgaikwad, mturquette, horms+renesas,
	Jisheng.Zhang, krzk, arnd, spujar, josephl, vidyas,
	daniel.lezcano, mmaddireddy, markz, devicetree, linux-clk,
	linux-tegra, linux-kernel, lgirdwood, broonie, perex, tiwai,
	alexios.zavras, alsa-devel

mclk is from clk_out_1 which is part of Tegra PMC block and pmc clocks
are moved to Tegra PMC driver with pmc as clock provider and using pmc
clock ids.

New device tree uses clk_out_1 from pmc clock provider.

So, this patch adds fallback to extern1 in case of retrieving mclk fails
to be backward compatible of new device tree with older kernels.

Cc: stable@vger.kernel.org

Signed-off-by: Sowjanya Komatineni <skomatineni@nvidia.com>
---
 sound/soc/tegra/tegra_asoc_utils.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/sound/soc/tegra/tegra_asoc_utils.c b/sound/soc/tegra/tegra_asoc_utils.c
index 8e3a3740df7c..f7408d5240c0 100644
--- a/sound/soc/tegra/tegra_asoc_utils.c
+++ b/sound/soc/tegra/tegra_asoc_utils.c
@@ -211,8 +211,14 @@ int tegra_asoc_utils_init(struct tegra_asoc_utils_data *data,
 	data->clk_cdev1 = clk_get(dev, "mclk");
 	if (IS_ERR(data->clk_cdev1)) {
 		dev_err(data->dev, "Can't retrieve clk cdev1\n");
-		ret = PTR_ERR(data->clk_cdev1);
-		goto err_put_pll_a_out0;
+		data->clk_cdev1 = clk_get_sys("clk_out_1", "extern1");
+		if (IS_ERR(data->clk_cdev1)) {
+			dev_err(data->dev, "Can't retrieve clk extern1\n");
+			ret = PTR_ERR(data->clk_cdev1);
+			goto err_put_pll_a_out0;
+		}
+
+		dev_err(data->dev, "Falling back to extern1\n");
 	}
 
 	/*
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk
@ 2019-12-06  2:48   ` Sowjanya Komatineni
  0 siblings, 0 replies; 18+ messages in thread
From: Sowjanya Komatineni @ 2019-12-06  2:48 UTC (permalink / raw)
  To: skomatineni, thierry.reding, jonathanh, digetx, mperttunen,
	gregkh, sboyd, tglx, robh+dt, mark.rutland
  Cc: allison, pdeschrijver, pgaikwad, mturquette, horms+renesas,
	Jisheng.Zhang, krzk, arnd, spujar, josephl, vidyas,
	daniel.lezcano, mmaddireddy, markz, devicetree, linux-clk,
	linux-tegra, linux-kernel, lgirdwood, broonie, perex, tiwai,
	alexios.zavras, alsa-devel

mclk is from clk_out_1 which is part of Tegra PMC block and pmc clocks
are moved to Tegra PMC driver with pmc as clock provider and using pmc
clock ids.

New device tree uses clk_out_1 from pmc clock provider.

So, this patch adds fallback to extern1 in case of retrieving mclk fails
to be backward compatible of new device tree with older kernels.

Cc: stable@vger.kernel.org

Signed-off-by: Sowjanya Komatineni <skomatineni@nvidia.com>
---
 sound/soc/tegra/tegra_asoc_utils.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/sound/soc/tegra/tegra_asoc_utils.c b/sound/soc/tegra/tegra_asoc_utils.c
index 8e3a3740df7c..f7408d5240c0 100644
--- a/sound/soc/tegra/tegra_asoc_utils.c
+++ b/sound/soc/tegra/tegra_asoc_utils.c
@@ -211,8 +211,14 @@ int tegra_asoc_utils_init(struct tegra_asoc_utils_data *data,
 	data->clk_cdev1 = clk_get(dev, "mclk");
 	if (IS_ERR(data->clk_cdev1)) {
 		dev_err(data->dev, "Can't retrieve clk cdev1\n");
-		ret = PTR_ERR(data->clk_cdev1);
-		goto err_put_pll_a_out0;
+		data->clk_cdev1 = clk_get_sys("clk_out_1", "extern1");
+		if (IS_ERR(data->clk_cdev1)) {
+			dev_err(data->dev, "Can't retrieve clk extern1\n");
+			ret = PTR_ERR(data->clk_cdev1);
+			goto err_put_pll_a_out0;
+		}
+
+		dev_err(data->dev, "Falling back to extern1\n");
 	}
 
 	/*
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2019-12-12  2:17 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <1575600438-26795-1-git-send-email-skomatineni@nvidia.com>
2019-12-06  2:47 ` [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk Sowjanya Komatineni
2019-12-06  7:09   ` Greg KH
2019-12-06 16:19     ` Sowjanya Komatineni
2019-12-06 16:29       ` Greg KH
2019-12-06 17:11         ` Sowjanya Komatineni
2019-12-06 17:15           ` Sowjanya Komatineni
2019-12-06 17:55             ` Greg KH
2019-12-06  2:48 [PATCH v3 00/15] Move PMC clocks into Tegra PMC driver Sowjanya Komatineni
2019-12-06  2:48 ` [PATCH v3 09/15] ASoC: tegra: Add fallback for audio mclk Sowjanya Komatineni
2019-12-06  2:48   ` Sowjanya Komatineni
2019-12-06 17:49   ` Sowjanya Komatineni
2019-12-06 17:49     ` Sowjanya Komatineni
2019-12-06 17:56     ` Greg KH
2019-12-09 16:40   ` Mark Brown
2019-12-09 20:31     ` Dmitry Osipenko
2019-12-09 20:47       ` Mark Brown
2019-12-10 18:24         ` Dmitry Osipenko
2019-12-10 18:59           ` Mark Brown
2019-12-12  2:17             ` Dmitry Osipenko

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.