From patchwork Tue Nov 28 03:11:30 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 119790 Delivered-To: patch@linaro.org Received: by 10.140.22.227 with SMTP id 90csp1175004qgn; Mon, 27 Nov 2017 19:11:41 -0800 (PST) X-Google-Smtp-Source: AGs4zMZzOw3SqKILqE1pK5ubkBXsdVL/HgbWI4wsV1C2WhgLSk40F/9bRI6uaoVu8kpYgCJN9Kvh X-Received: by 10.84.248.145 with SMTP id q17mr39803096pll.416.1511838701185; Mon, 27 Nov 2017 19:11:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1511838701; cv=none; d=google.com; s=arc-20160816; b=anjuwvVA6djD3ImzkJSiU8GjcmX9DY5LHfRYYsZkmiAnsh2Rg2RUO3WlPn7qfLWC34 thRLZyDBS5rhk4scbwh093vawZ9yFO01hqcd4EXdtHjy1G8OGpJMSzbU1figVBT5YBky twg+QK2fKY0+ycjk28Ldj3fpxCwOvID251UlS7dbarZkNj4mtQfyUOGlBqF7BbAAOpzB 7sQL91ZBT2gJ23I3pF5sKwFsXLrwzEvcLHTs4mf41sy+ye7bIIRHBr3TZwP+iyzHyX1w /vlqR2QTv39tzP6gdtdj1ZWjAkfpRX6g2mDqWLuY8dL56Shqb62nfPKLmuvapVSAerkc VGqA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=uRrbU+FEbnm6nY3DZ6k+fsOJHFxxV3K4tAIar8HrwZ8=; b=V+vywGi+HKiBHrRjlG7GADDg/c/2qY8Wyy2R28Vb9mJoZc6j07QGxbgjZ+VQPmZzKr wHLggsEJZdkkChhBvzdxy0GMC4aJV/oFP8v/6aw+rTdNhWPsbGic0A40bRGGSwPfh/fg nm+j/EZOsGVPGY984izupZNmGSqBDSorgofiZRkmwPHPHB1A2jw0tuG5KZxvT6LYW0Ga r3n/huDxjN/br3UNu6IdHmRueG+fhxGGrEeZ6CCP8illU/rXO8AepAoMJ+ioo+FnfeR1 0aDwrq9a3uKVV016mZrMT2Xd5TiAzLbrYOgTTLXn0tFAWnIIerOVnKi4s8fqsa5bErZK p9WQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=PaO4U4UF; spf=pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k125si15325842pgk.495.2017.11.27.19.11.40; Mon, 27 Nov 2017 19:11:41 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=PaO4U4UF; spf=pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751717AbdK1DLj (ORCPT + 9 others); Mon, 27 Nov 2017 22:11:39 -0500 Received: from mail-pl0-f66.google.com ([209.85.160.66]:41673 "EHLO mail-pl0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751350AbdK1DLi (ORCPT ); Mon, 27 Nov 2017 22:11:38 -0500 Received: by mail-pl0-f66.google.com with SMTP id u14so9786195plm.8 for ; Mon, 27 Nov 2017 19:11:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=uRrbU+FEbnm6nY3DZ6k+fsOJHFxxV3K4tAIar8HrwZ8=; b=PaO4U4UFXBytknEoVE9yJPT0q0c0rO5H8ZmomGPF+db8UCmhR51yHRthHpiXKY5GPY JAC6MOeVgmy+7eK6g2oBZy23fCrfcx8ulxq9iMmfsiKCTXhSyqu9i6y30KlCcWlVbfa2 ZHnT6V6oyfLt9DQS1HrqN5vCIpKI67HbHRjNk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=uRrbU+FEbnm6nY3DZ6k+fsOJHFxxV3K4tAIar8HrwZ8=; b=SkhlhtRJAVjEgd8vDCtDT5Nf5T8Ffvse4L/ytIsk3iStkvku1F7sHvaU1uV8eGci0K VXMIfFKRMPhC20sCAHSlofSFrZd2wqS9kWknB1IlSNQLyGONy/h1Uz98zNqFNiDIAqgW 1pmsB2aUVt/60yws25hZShmnxLEK6eTs1qQT7alxxwGSrK/rZ9GJQZHSS1z3E8SW23r7 Nt4KEMNxUzxd+PixvrVcHiIjDUulQxtT5od8j1APxoxRzGDyymZgHCFdfxiqwepQNSRL aEhCli3+vfl4bw9kVbSpSSTT5tpKUrQp7YtX+cIwHa7U0DNVH+t/BAIfnxz3qcUCQx7y xasA== X-Gm-Message-State: AJaThX6CNnlAdVZ7UQGG6awbkOMx/UzoMg5F86zBJB/dfvgOoI89qYjA shlat0/O1m56Tv5ttP2QXvgb7w== X-Received: by 10.84.128.34 with SMTP id 31mr16900217pla.303.1511838697635; Mon, 27 Nov 2017 19:11:37 -0800 (PST) Received: from localhost ([122.171.67.58]) by smtp.gmail.com with ESMTPSA id q12sm42810734pgn.56.2017.11.27.19.11.35 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 27 Nov 2017 19:11:36 -0800 (PST) From: Viresh Kumar To: Rafael Wysocki , mroos@linux.ee Cc: Viresh Kumar , linux-pm@vger.kernel.org, Vincent Guittot , "4 . 14+" , linux-kernel@vger.kernel.org Subject: [PATCH] cpufreq: longhaul: Set transition_delay_us to 20 ms Date: Tue, 28 Nov 2017 08:41:30 +0530 Message-Id: X-Mailer: git-send-email 2.15.0.194.g9af6a3dea062 In-Reply-To: References: Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org The commit e948bc8fbee0 ("cpufreq: Cap the default transition delay value to 10 ms") caused a regression on EPIA-M min-ITX computer where shutdown or reboot hangs occasionally with a print message like: longhaul: Warning: Timeout while waiting for idle PCI bus cpufreq: __target_index: Failed to change cpu frequency: -16 This probably happens because the cpufreq governor tries to change the frequency of the CPU faster than allowed by the hardware. With the above commit, the default transition delay comes to 10 ms for a transition_latency of 200 us. Set the default transition delay to 20 ms directly to fix this regression. Fixes: e948bc8fbee0 ("cpufreq: Cap the default transition delay value to 10 ms") Cc: 4.14+ # 4.14+ Reported-by: Meelis Roos Suggested-by: Rafael J. Wysocki Signed-off-by: Viresh Kumar --- drivers/cpufreq/longhaul.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.15.0.194.g9af6a3dea062 diff --git a/drivers/cpufreq/longhaul.c b/drivers/cpufreq/longhaul.c index c46a12df40dd..56eafcb07859 100644 --- a/drivers/cpufreq/longhaul.c +++ b/drivers/cpufreq/longhaul.c @@ -894,7 +894,7 @@ static int longhaul_cpu_init(struct cpufreq_policy *policy) if ((longhaul_version != TYPE_LONGHAUL_V1) && (scale_voltage != 0)) longhaul_setup_voltagescaling(); - policy->cpuinfo.transition_latency = 200000; /* nsec */ + policy->transition_delay_us = 20000; /* usec */ return cpufreq_table_validate_and_show(policy, longhaul_table); }