Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp39410rwb; Tue, 8 Nov 2022 21:59:07 -0800 (PST) X-Google-Smtp-Source: AMsMyM6JXMTAWbXy1LTJU0wNRyOaKT/tpH0delDF90OlHv+LBL3S+PdnupZO5sIPIDd7jitTEVpp X-Received: by 2002:a17:907:3ac3:b0:791:9801:e48a with SMTP id fi3-20020a1709073ac300b007919801e48amr1038389ejc.738.1667973547621; Tue, 08 Nov 2022 21:59:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1667973547; cv=none; d=google.com; s=arc-20160816; b=QfDNEU1h+Eb4uRKKPOesmAaRUqkzcDR0du/cPQ2bmUBmU6lFUgxIhWcmSzm1y/omNL yJgQQdqrCG+vmu68KxevMrhgkt/Ys9ESeYwhP5z+2yK62GgQiIK/AzHLG0vZtcsp/Mto 2oEo/dxvj3EyiznOFa+R9fY5poYMcZlwC4/6Ndxwu16+ZvXZoRxhY8Vg+XrC1f8BgE0e y3KPxtk+If0TTezfWgbaWun2kOJt5Wxpud4JceI0P2PID9szY4nUBY3Js+LIcMglpK93 f2t7v8d5w28eTYIazlMfkFZyU6QGrUiuZqsL27cK5rEfgxr5oQHLS3m7zN2CCXYKrFbG ekng== 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 :message-id:date:subject:cc:to:from; bh=Jmc5VQKzBHnezYiChHv9/H7gBaVDwr+lJ+8O6j8uQwY=; b=JwAql3LbAZoYiieHr/qH5B6N9wC7tF8sAwIDITVlTFJ9fMJzgsa8SYXRaFxKSN7cjH che/I4xDluJVmo9EbQNQegD4qcwk7Bii5+lovk6e9X4Q8ag1pcH6E49VcvKDlFJyopdR rqTjHGCQesZPCIJfVNVwd1RpG3L0+9pGjMgRbCNhuikzIs3uZzJUWkWBQnAMHJMBfjYn 2+7mi/elXMyWMQHebmcLVS8a+69IeAk4lI/fkDTMy1Gq+nbmwUSP06FxcnAXUmSJOJSK jXyWY9xbRbsqY5l6loXbAKv7/TsoJq9wcwn6rP7wF5vukRCviACYsRD/nfwpQX8if53N yqsw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id go35-20020a1709070da300b0078d23ac6981si15277100ejc.790.2022.11.08.21.58.44; Tue, 08 Nov 2022 21:59:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229681AbiKIFne (ORCPT + 93 others); Wed, 9 Nov 2022 00:43:34 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52748 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229447AbiKIFnc (ORCPT ); Wed, 9 Nov 2022 00:43:32 -0500 Received: from out30-130.freemail.mail.aliyun.com (out30-130.freemail.mail.aliyun.com [115.124.30.130]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6675EC5E; Tue, 8 Nov 2022 21:43:31 -0800 (PST) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R931e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018046059;MF=yang.lee@linux.alibaba.com;NM=1;PH=DS;RN=6;SR=0;TI=SMTPD_---0VUMVrOK_1667972607; Received: from localhost(mailfrom:yang.lee@linux.alibaba.com fp:SMTPD_---0VUMVrOK_1667972607) by smtp.aliyun-inc.com; Wed, 09 Nov 2022 13:43:29 +0800 From: Yang Li To: rafael@kernel.org Cc: viresh.kumar@linaro.org, linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, Yang Li , Abaci Robot Subject: [PATCH -next] cpufreq: Remove the unused variables Date: Wed, 9 Nov 2022 13:43:26 +0800 Message-Id: <20221109054326.89507-1-yang.lee@linux.alibaba.com> X-Mailer: git-send-email 2.20.1.7.g153144c MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-9.9 required=5.0 tests=BAYES_00, ENV_AND_HDR_SPF_MATCH,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2, SPF_HELO_NONE,SPF_PASS,UNPARSEABLE_RELAY,USER_IN_DEF_SPF_WL autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The function using variable 'acpi_cpufreq_online' has been deleted, so it is redundant. Similarly, variable 'ret' assigned to acpi_cpufreq_online is redundant, and 'ret' is not initialized, because its assignment statement has also been eliminated. Remove the unused variables to silence this warning: drivers/cpufreq/acpi-cpufreq.c:960:9: note: initialize the variable 'ret' to silence this warning Link: https://bugzilla.openanolis.cn/show_bug.cgi?id=2824 Fixes: 13fdbc8b8da6 ("cpufreq: ACPI: Defer setting boost MSRs") Reported-by: Abaci Robot Signed-off-by: Yang Li --- drivers/cpufreq/acpi-cpufreq.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/drivers/cpufreq/acpi-cpufreq.c b/drivers/cpufreq/acpi-cpufreq.c index c8fdfcf659e6..74ef0e05ff7b 100644 --- a/drivers/cpufreq/acpi-cpufreq.c +++ b/drivers/cpufreq/acpi-cpufreq.c @@ -953,12 +953,8 @@ static struct cpufreq_driver acpi_cpufreq_driver = { .attr = acpi_cpufreq_attr, }; -static enum cpuhp_state acpi_cpufreq_online; - static void __init acpi_cpufreq_boost_init(void) { - int ret; - if (!(boot_cpu_has(X86_FEATURE_CPB) || boot_cpu_has(X86_FEATURE_IDA))) { pr_debug("Boost capabilities not present in the processor\n"); return; @@ -966,8 +962,6 @@ static void __init acpi_cpufreq_boost_init(void) acpi_cpufreq_driver.set_boost = set_boost; acpi_cpufreq_driver.boost_enabled = boost_state(0); - - acpi_cpufreq_online = ret; } static int __init acpi_cpufreq_init(void) -- 2.20.1.7.g153144c