All of lore.kernel.org
 help / color / mirror / Atom feed
From: Viresh Kumar <viresh.kumar@linaro.org>
To: Nicola Mazzucato <nicola.mazzucato@arm.com>
Cc: linux-kernel@vger.kernel.org, sudeep.holla@arm.com,
	rjw@rjwysocki.net, linux-arm-kernel@lists.infradead.org,
	linux-pm@vger.kernel.org, lukasz.luba@arm.com
Subject: Re: [PATCH 2/2] cpufreq: arm_scmi: Set fast_switch_possible conditionally
Date: Thu, 18 Jun 2020 15:24:29 +0530	[thread overview]
Message-ID: <20200618095429.tj3ddquy5m2q367e@vireshk-i7> (raw)
In-Reply-To: <20200617094332.8391-2-nicola.mazzucato@arm.com>

On 17-06-20, 10:43, Nicola Mazzucato wrote:
> Currently the fast_switch_possible flag is set unconditionally
> to true. Based on this, schedutil does not create a
> thread for frequency switching and would always use the
> fast switch path.
> However, if the platform does not support frequency
> fast switch, this may cause the governor to attempt an
> operation that is not supported by the platform.
> 
> Fix this by correctly retrieve the fast_switch capability
> from the driver which knows if the platform can support
> this feature.
> 
> Suggested-by: Lukasz Luba <lukasz.luba@arm.com>
> Signed-off-by: Nicola Mazzucato <nicola.mazzucato@arm.com>
> ---
>  drivers/cpufreq/scmi-cpufreq.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/cpufreq/scmi-cpufreq.c b/drivers/cpufreq/scmi-cpufreq.c
> index 61623e2ff149..1cf688fcb56b 100644
> --- a/drivers/cpufreq/scmi-cpufreq.c
> +++ b/drivers/cpufreq/scmi-cpufreq.c
> @@ -198,7 +198,8 @@ static int scmi_cpufreq_init(struct cpufreq_policy *policy)
>  
>  	policy->cpuinfo.transition_latency = latency;
>  
> -	policy->fast_switch_possible = true;
> +	policy->fast_switch_possible =
> +		handle->perf_ops->fast_switch_possible(handle, cpu_dev);
>  
>  	em_register_perf_domain(policy->cpus, nr_opp, &em_cb);

Acked-by: Viresh Kumar <viresh.kumar@linaro.org>

-- 
viresh

WARNING: multiple messages have this Message-ID (diff)
From: Viresh Kumar <viresh.kumar@linaro.org>
To: Nicola Mazzucato <nicola.mazzucato@arm.com>
Cc: linux-pm@vger.kernel.org, rjw@rjwysocki.net,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org, sudeep.holla@arm.com,
	lukasz.luba@arm.com
Subject: Re: [PATCH 2/2] cpufreq: arm_scmi: Set fast_switch_possible conditionally
Date: Thu, 18 Jun 2020 15:24:29 +0530	[thread overview]
Message-ID: <20200618095429.tj3ddquy5m2q367e@vireshk-i7> (raw)
In-Reply-To: <20200617094332.8391-2-nicola.mazzucato@arm.com>

On 17-06-20, 10:43, Nicola Mazzucato wrote:
> Currently the fast_switch_possible flag is set unconditionally
> to true. Based on this, schedutil does not create a
> thread for frequency switching and would always use the
> fast switch path.
> However, if the platform does not support frequency
> fast switch, this may cause the governor to attempt an
> operation that is not supported by the platform.
> 
> Fix this by correctly retrieve the fast_switch capability
> from the driver which knows if the platform can support
> this feature.
> 
> Suggested-by: Lukasz Luba <lukasz.luba@arm.com>
> Signed-off-by: Nicola Mazzucato <nicola.mazzucato@arm.com>
> ---
>  drivers/cpufreq/scmi-cpufreq.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/cpufreq/scmi-cpufreq.c b/drivers/cpufreq/scmi-cpufreq.c
> index 61623e2ff149..1cf688fcb56b 100644
> --- a/drivers/cpufreq/scmi-cpufreq.c
> +++ b/drivers/cpufreq/scmi-cpufreq.c
> @@ -198,7 +198,8 @@ static int scmi_cpufreq_init(struct cpufreq_policy *policy)
>  
>  	policy->cpuinfo.transition_latency = latency;
>  
> -	policy->fast_switch_possible = true;
> +	policy->fast_switch_possible =
> +		handle->perf_ops->fast_switch_possible(handle, cpu_dev);
>  
>  	em_register_perf_domain(policy->cpus, nr_opp, &em_cb);

Acked-by: Viresh Kumar <viresh.kumar@linaro.org>

-- 
viresh

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  parent reply	other threads:[~2020-06-18  9:54 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-19 22:03 [PATCH] firmware: arm_scmi: Fix SCMI Generic Power Domain probing Cristian Marussi
2020-06-19 22:03 ` Cristian Marussi
2020-07-03 14:49 ` Sudeep Holla
2020-07-03 14:49   ` Sudeep Holla
2020-07-01 15:53   ` [PATCH v11 0/9] SCMI Notifications Core Support Cristian Marussi
2020-07-01 15:53     ` Cristian Marussi
2020-07-01 15:53     ` [PATCH v11 1/9] firmware: arm_scmi: Add notification protocol-registration Cristian Marussi
2020-07-01 15:53       ` Cristian Marussi
2020-07-01 15:53     ` [PATCH v11 2/9] firmware: arm_scmi: Add notification callbacks-registration Cristian Marussi
2020-07-01 15:53       ` Cristian Marussi
2020-07-01 15:53     ` [PATCH v11 3/9] firmware: arm_scmi: Add notification dispatch and delivery Cristian Marussi
2020-07-01 15:53       ` Cristian Marussi
2020-07-01 15:53     ` [PATCH v11 4/9] firmware: arm_scmi: Enable notification core Cristian Marussi
2020-07-01 15:53       ` Cristian Marussi
2020-07-01 15:53     ` [PATCH v11 5/9] firmware: arm_scmi: Add power notifications support Cristian Marussi
2020-07-01 15:53       ` Cristian Marussi
2020-07-01 15:53     ` [PATCH v11 6/9] firmware: arm_scmi: Add perf " Cristian Marussi
2020-07-01 15:53       ` Cristian Marussi
2020-07-01 15:53     ` [PATCH v11 7/9] firmware: arm_scmi: Add sensor " Cristian Marussi
2020-07-01 15:53       ` Cristian Marussi
2020-07-01 15:53     ` [PATCH v11 8/9] firmware: arm_scmi: Add reset " Cristian Marussi
2020-07-01 15:53       ` Cristian Marussi
2020-07-01 15:53     ` [PATCH v11 9/9] firmware: arm_scmi: Add base " Cristian Marussi
2020-07-01 15:53       ` Cristian Marussi
2020-07-03 14:49     ` [PATCH v11 0/9] SCMI Notifications Core Support Sudeep Holla
2020-07-03 14:49       ` Sudeep Holla
2020-06-17  9:43       ` [PATCH 1/2] firmware: arm_scmi: Add fast_switch_possible() api Nicola Mazzucato
2020-06-17  9:43         ` Nicola Mazzucato
2020-06-17  9:43         ` [PATCH 2/2] cpufreq: arm_scmi: Set fast_switch_possible conditionally Nicola Mazzucato
2020-06-17  9:43           ` Nicola Mazzucato
2020-06-17 12:47           ` Sudeep Holla
2020-06-17 12:47             ` Sudeep Holla
2020-06-18  6:14             ` Viresh Kumar
2020-06-18  6:14               ` Viresh Kumar
2020-06-18  8:08               ` Sudeep Holla
2020-06-18  8:08                 ` Sudeep Holla
2020-06-18  9:54           ` Viresh Kumar [this message]
2020-06-18  9:54             ` Viresh Kumar
2020-07-03 14:49         ` [PATCH 1/2] firmware: arm_scmi: Add fast_switch_possible() api Sudeep Holla
2020-07-03 14:49           ` Sudeep Holla
2020-06-25 10:19           ` [PATCH] firmware: arm_scmi: Use HAVE_ARM_SMCCC_DISCOVERY instead of ARM_PSCI_FW Sudeep Holla
2020-06-25 10:19             ` Sudeep Holla
2020-07-03 14:49             ` Sudeep Holla
2020-07-03 14:49               ` Sudeep Holla
2020-06-09 13:45               ` [PATCH] firmware: arm_scmi: Use signed integer to report transfer status Sudeep Holla
2020-06-09 13:45                 ` Sudeep Holla
2020-06-09 14:00                 ` Lukasz Luba
2020-06-09 14:00                   ` Lukasz Luba
2020-07-03 14:49                 ` Sudeep Holla
2020-07-03 14:49                   ` Sudeep Holla

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=20200618095429.tj3ddquy5m2q367e@vireshk-i7 \
    --to=viresh.kumar@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=lukasz.luba@arm.com \
    --cc=nicola.mazzucato@arm.com \
    --cc=rjw@rjwysocki.net \
    --cc=sudeep.holla@arm.com \
    /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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.