linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Elad Nachman <enachman@marvell.com>
To: "Pali Rohár" <pali@kernel.org>,
	"Wojciech Bartczak" <wbartczak@marvell.com>
Cc: "Marek Behún" <kabel@kernel.org>,
	"Viresh Kumar" <viresh.kumar@linaro.org>,
	"Gregory CLEMENT" <gregory.clement@bootlin.com>,
	"Robert Marko" <robert.marko@sartura.hr>,
	"Tomasz Maciej Nowak" <tmn505@gmail.com>,
	"Anders Trier Olesen" <anders.trier.olesen@gmail.com>,
	"Philip Soares" <philips@netisense.com>,
	"linux-pm@vger.kernel.org" <linux-pm@vger.kernel.org>,
	"Sebastian Hesselbarth" <sebastian.hesselbarth@gmail.com>,
	"linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>, nnet <nnet@fastmail.fm>
Subject: RE: [EXT] Re: [PATCH v2] cpufreq: armada-37xx: forbid cpufreq for 1.2 GHz variant
Date: Mon, 1 Aug 2022 14:01:07 +0000	[thread overview]
Message-ID: <BN9PR18MB4251768A59D38A44C264E1FEDB9A9@BN9PR18MB4251.namprd18.prod.outlook.com> (raw)
In-Reply-To: <20220801123616.uol4wrs6trttumsg@pali>

Hi Pali,

There is an errata for that.

"
Switching from L2/L3 state (200/300 MHz) to L0 state (1200 MHz) requires sudden changes of VDD supply, and it
requires time to stabilize the VDD supply. The solution is to use gradual switching from L2/L3 to L1 and then L1 to L0
state.
"

I would also add additional delay for the VDD supply stabilization.

FYI,

Elad.

-----Original Message-----
From: Pali Rohár <pali@kernel.org> 
Sent: Monday, August 1, 2022 3:36 PM
To: Elad Nachman <enachman@marvell.com>; Wojciech Bartczak <wbartczak@marvell.com>
Cc: Marek Behún <kabel@kernel.org>; Viresh Kumar <viresh.kumar@linaro.org>; Gregory CLEMENT <gregory.clement@bootlin.com>; Robert Marko <robert.marko@sartura.hr>; Tomasz Maciej Nowak <tmn505@gmail.com>; Anders Trier Olesen <anders.trier.olesen@gmail.com>; Philip Soares <philips@netisense.com>; linux-pm@vger.kernel.org; Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>; linux-arm-kernel@lists.infradead.org; nnet <nnet@fastmail.fm>
Subject: [EXT] Re: [PATCH v2] cpufreq: armada-37xx: forbid cpufreq for 1.2 GHz variant

External Email

----------------------------------------------------------------------
+ Elad and Wojciech from Marvell

Could you please look at this issue and/or forward it to relevant Marvell team?

Maintainer Viresh already wrote that we cannot hang forever for Marvell and patch which disables support for 1.2 GHz was merged:
https://urldefense.proofpoint.com/v2/url?u=https-3A__lore.kernel.org_linux-2Dpm_20210809040224.j2rvopmmqda3utc5-40vireshk-2Di7_&d=DwIDaQ&c=nKjWec2b6R0mOyPaz7xtfQ&r=eTeNTLEK5-TxXczjOcKPhANIFtlB9pP4lq9qhdlFrwQ&m=5nMMKyKOOM3XdMe_PerZRx8L7-D7MkWhCl7GxpXTPiotVf1TR4j8v3bpjQmRKCLC&s=cXiCZByknfz1rOIgJl4fJHl1KLLRq2shHul2-VPpYP0&e= 

On Sunday 08 August 2021 21:30:26 Pali Rohár wrote:
> Gentle reminder. This is really serious issue. Could you please look at it?
> 
> Adding more MarvellEmbeddedProcessors people to the loop: Evan, 
> Benjamin an Igal
> 
> On Thursday 15 July 2021 21:33:21 Pali Rohár wrote:
> > Ping! Gentle reminder for Marvell people.
> > 
> > On Thursday 08 July 2021 16:34:51 Pali Rohár wrote:
> > > Konstantin, Nadav, Ken, Victor, Jason: This issue is pretty 
> > > serious, CPU on 1.2GHz A3720 is crashing. Could you please look at it?
> > > 
> > > On Friday 02 July 2021 18:30:35 Pali Rohár wrote:
> > > > +Jason from GlobalScale as this issue affects GlobalScale Espressobin Ultra and V7 1.2 GHz boards.
> > > > 
> > > > On Thursday 01 July 2021 00:56:01 Marek Behún wrote:
> > > > > The 1.2 GHz variant of the Armada 3720 SOC is unstable with 
> > > > > DVFS: when the SOC boots, the WTMI firmware sets clocks and 
> > > > > AVS values that work correctly with 1.2 GHz CPU frequency, but 
> > > > > random crashes occur once cpufreq driver starts scaling.
> > > > > 
> > > > > We do not know currently what is the reason:
> > > > > - it may be that the voltage value for L0 for 1.2 GHz variant provided
> > > > >   by the vendor in the OTP is simply incorrect when scaling is 
> > > > > used,
> > > > > - it may be that some delay is needed somewhere,
> > > > > - it may be something else.
> > > > > 
> > > > > The most sane solution now seems to be to simply forbid the 
> > > > > cpufreq driver on 1.2 GHz variant.
> > > > > 
> > > > > Signed-off-by: Marek Behún <kabel@kernel.org>
> > > > > Fixes: 92ce45fb875d ("cpufreq: Add DVFS support for Armada 
> > > > > 37xx")
> > > > > ---
> > > > > If someone from Marvell could look into this, it would be 
> > > > > great since basically 1.2 GHz variant cannot scale, which is a 
> > > > > feature that was claimed to be supported by the SOC.
> > > > > 
> > > > > Ken Ma / Victor Gu, you have worked on commit 
> > > > > https://urldefense.proofpoint.com/v2/url?u=https-3A__github.co
> > > > > m_MarvellEmbeddedProcessors_linux-2Dmarvell_commit_d6719fdc2b3
> > > > > cac58064f41b531f86993c919aa9a&d=DwIDaQ&c=nKjWec2b6R0mOyPaz7xtf
> > > > > Q&r=eTeNTLEK5-TxXczjOcKPhANIFtlB9pP4lq9qhdlFrwQ&m=5nMMKyKOOM3X
> > > > > dMe_PerZRx8L7-D7MkWhCl7GxpXTPiotVf1TR4j8v3bpjQmRKCLC&s=b9cDKem
> > > > > t70OiTJF6KXj0ySzbxpsB_nuteXJE87via80&e=
> > > > > in linux-marvell.
> > > > > Your patch takes away the 1202 mV constant for 1.2 GHz base 
> > > > > CPU frequency and instead adds code that computes the voltages 
> > > > > from the voltage found in L0 AVS register (which is filled in by WTMI firmware).
> > > > > 
> > > > > Do you know why the code does not work correctly for some 1.2 
> > > > > GHz boards? Do we need to force the L0 voltage to 1202 mV if 
> > > > > it is lower, or something?
> > > > > ---
> > > > >  drivers/cpufreq/armada-37xx-cpufreq.c | 6 +++++-
> > > > >  1 file changed, 5 insertions(+), 1 deletion(-)
> > > > > 
> > > > > diff --git a/drivers/cpufreq/armada-37xx-cpufreq.c 
> > > > > b/drivers/cpufreq/armada-37xx-cpufreq.c
> > > > > index 3fc98a3ffd91..c10fc33b29b1 100644
> > > > > --- a/drivers/cpufreq/armada-37xx-cpufreq.c
> > > > > +++ b/drivers/cpufreq/armada-37xx-cpufreq.c
> > > > > @@ -104,7 +104,11 @@ struct armada_37xx_dvfs {  };
> > > > >  
> > > > >  static struct armada_37xx_dvfs armada_37xx_dvfs[] = {
> > > > > -	{.cpu_freq_max = 1200*1000*1000, .divider = {1, 2, 4, 6} },
> > > > > +	/*
> > > > > +	 * The cpufreq scaling for 1.2 GHz variant of the SOC is currently
> > > > > +	 * unstable because we do not know how to configure it properly.
> > > > > +	 */
> > > > > +	/* {.cpu_freq_max = 1200*1000*1000, .divider = {1, 2, 4, 6} 
> > > > > +}, */
> > > > >  	{.cpu_freq_max = 1000*1000*1000, .divider = {1, 2, 4, 5} },
> > > > >  	{.cpu_freq_max = 800*1000*1000,  .divider = {1, 2, 3, 4} },
> > > > >  	{.cpu_freq_max = 600*1000*1000,  .divider = {2, 4, 5, 6} },
> > > > > --
> > > > > 2.31.1
> > > > > 
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2022-08-01 14:03 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-30 13:59 [PATCH] " Marek Behún
2021-06-30 14:02 ` Marek Behún
2021-06-30 15:22 ` Andrew Lunn
2021-06-30 22:56 ` [PATCH v2] " Marek Behún
2021-07-01  2:05   ` Viresh Kumar
2021-07-02 16:30   ` Pali Rohár
2021-07-08 14:34     ` Pali Rohár
2021-07-15 19:33       ` Pali Rohár
2021-08-08 19:30         ` Pali Rohár
2021-08-09  4:02           ` Viresh Kumar
2022-08-01 12:36           ` Pali Rohár
2022-08-01 14:01             ` Elad Nachman [this message]
2022-08-01 14:12               ` [EXT] " Pali Rohár
2022-08-01 14:15                 ` Elad Nachman
2022-08-01 17:56                   ` Pali Rohár
     [not found]                     ` <BN9PR18MB42518C761E574D862D30CDA7DB9A9@BN9PR18MB4251.namprd18.prod.outlook.com>
2022-08-02 16:42                       ` Robert Marko
2022-08-02 16:52                         ` Elad Nachman
2022-08-02 16:56                           ` Robert Marko
2022-08-02 17:17                             ` Pali Rohár
2022-08-17  9:40                               ` Robert Marko
2022-08-17 23:10                                 ` Pali Rohár
2022-08-18  8:14                                   ` Robert Marko
2022-08-25 21:49                                     ` Pali Rohár

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=BN9PR18MB4251768A59D38A44C264E1FEDB9A9@BN9PR18MB4251.namprd18.prod.outlook.com \
    --to=enachman@marvell.com \
    --cc=anders.trier.olesen@gmail.com \
    --cc=gregory.clement@bootlin.com \
    --cc=kabel@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=nnet@fastmail.fm \
    --cc=pali@kernel.org \
    --cc=philips@netisense.com \
    --cc=robert.marko@sartura.hr \
    --cc=sebastian.hesselbarth@gmail.com \
    --cc=tmn505@gmail.com \
    --cc=viresh.kumar@linaro.org \
    --cc=wbartczak@marvell.com \
    --subject='RE: [EXT] Re: [PATCH v2] cpufreq: armada-37xx: forbid cpufreq for 1.2 GHz variant' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).