Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp4597775pxj; Wed, 12 May 2021 08:58:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzPDCCoQyUU5nL1yKKw2yqfn4MYu5r9XJ38vQcuISD+OPqrAjitZWTtU5I4xa07wX6OGT/2 X-Received: by 2002:a05:6402:3481:: with SMTP id v1mr2301949edc.312.1620835098413; Wed, 12 May 2021 08:58:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620835098; cv=none; d=google.com; s=arc-20160816; b=ElT/uyu9GBO/qe0duuM2txNyL10x18wkOMvKRFZ2nRHwKXz7b+3NrLRdaUMa3ND/S+ ZTaHsyhpAfLJKh86lP5W6eFrcc2h/33733hO29h3ncAAy83yR3+KURr16mC8IPsJ77sq noaD4UMqMUwEOiDV6akOSMrJC5xvZUUr2kmla2Ed0Iz72vhUevkcGVFxwx4SUQ0RFhnL h76trd+oPnX2K6C/eKefytj7ZqkAVGDWI/AmcBjXJy9iPpaCfia8WI7i1L4x/RmF1+2z MMmgcrWH+TiCMFFRBCrF3qylmZWgdpbzUkur1KuOZ7rW37nvx++nbFvhmDxMEbZY+D3s U3Fw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=Ekvl/JtxnLoQqqSeQBIQemfpKqm5xJS4pttvKE7t1vk=; b=aWaE+dx+kgItWMmEYo3fq3l6r3+bDwT9dKO8972arr/E3wRlrapEasT1D0sXdBs4BO oIF93NV/gqmV64THF2WKZl9i88Dga8b9l/L6fmB/YWtDrLhP7A5WVRZsXkHLTiHaLW2n x4/eHlg3XAAP8QQcO7p1Y1B0MQxWm1O9oXiM8/UiZt7ecY+KKMnpoBlGLM1ArSKHH+x4 k3Ixn0zTfkBdQv4gm3OSaEm6geuc8t66o+AwKNL7e7nJOGCpHBSd1P9ugkx3QTT/LVXT vVxKz/NFnuPtG5WMP1/qKToCc1ra8zKrpJMx/HtpyZSXA8w6fBUyHqrWis1UfrK/wel+ KALw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=bBiEu5Jg; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id gg17si329293ejb.131.2021.05.12.08.57.49; Wed, 12 May 2021 08:58:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=bBiEu5Jg; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235902AbhELPy6 (ORCPT + 99 others); Wed, 12 May 2021 11:54:58 -0400 Received: from mail.kernel.org ([198.145.29.99]:40490 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235055AbhELP0e (ORCPT ); Wed, 12 May 2021 11:26:34 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 37D4561964; Wed, 12 May 2021 15:11:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1620832283; bh=jMRFKLtuHBe/8d98bmIpfSpVfZ2W8Ytw0+bWLvzF0vA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=bBiEu5JgyHyS7n6lGGpmKysRftVMOmeqOB7OT3RLtAReOjVNL4afUR2k06hpPBlU7 4ReY6Rsj+cwKPGzz+AMH34ja8yhKaJJPf+xy9nPBo3G6avIgrV2lgtwKxJNx/G/pFP KHqWiG7WWW/AcXZR5ccpi4lbK8QzvlsBUuHkM9lA= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Dong Aisheng , Chanwoo Choi , Sasha Levin Subject: [PATCH 5.10 215/530] PM / devfreq: Use more accurate returned new_freq as resume_freq Date: Wed, 12 May 2021 16:45:25 +0200 Message-Id: <20210512144826.906732767@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210512144819.664462530@linuxfoundation.org> References: <20210512144819.664462530@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Dong Aisheng [ Upstream commit 62453f1ba5d5def9d58e140a50f3f168f028da38 ] Use the more accurate returned new_freq as resume_freq. It's the same as how devfreq->previous_freq was updated. Fixes: 83f8ca45afbf0 ("PM / devfreq: add support for suspend/resume of a devfreq device") Signed-off-by: Dong Aisheng Signed-off-by: Chanwoo Choi Signed-off-by: Sasha Levin --- drivers/devfreq/devfreq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq/devfreq.c index 1db04cbcf227..98f03a02d112 100644 --- a/drivers/devfreq/devfreq.c +++ b/drivers/devfreq/devfreq.c @@ -377,7 +377,7 @@ static int devfreq_set_target(struct devfreq *devfreq, unsigned long new_freq, devfreq->previous_freq = new_freq; if (devfreq->suspend_freq) - devfreq->resume_freq = cur_freq; + devfreq->resume_freq = new_freq; return err; } -- 2.30.2