From mboxrd@z Thu Jan 1 00:00:00 1970 From: Antti P Miettinen Subject: [PATCH 4/6] cpufreq: Preserve sysfs min/max request Date: Fri, 6 Jan 2012 02:36:24 +0200 Message-ID: <1325810186-28986-5-git-send-email-amiettinen@nvidia.com> References: <1325810186-28986-1-git-send-email-amiettinen@nvidia.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1325810186-28986-1-git-send-email-amiettinen@nvidia.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-pm-bounces@lists.linux-foundation.org Errors-To: linux-pm-bounces@lists.linux-foundation.org To: linux-pm@lists.linux-foundation.org Cc: Antti P Miettinen List-Id: linux-pm@vger.kernel.org Store the value received via sysfs as the user_policy min/max value instead of the currently enforced min/max. This allows restoring the user min/max values when constraints on enforced min/max change. Signed-off-by: Antti P Miettinen --- drivers/cpufreq/cpufreq.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c index e63b29f..65a512b 100644 --- a/drivers/cpufreq/cpufreq.c +++ b/drivers/cpufreq/cpufreq.c @@ -389,7 +389,7 @@ static ssize_t store_##file_name \ return -EINVAL; \ \ ret = __cpufreq_set_policy(policy, &new_policy); \ - policy->user_policy.object = policy->object; \ + policy->user_policy.object = new_policy.object; \ \ return ret ? ret : count; \ } -- 1.7.4.1