Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp1110522rwb; Wed, 16 Nov 2022 12:13:01 -0800 (PST) X-Google-Smtp-Source: AA0mqf4NsfYQccUv3DeBRskNh3fU97m6/SoIL1EUmIITBByHYGJiYvB502C3OsheA0i8OtxKg/yI X-Received: by 2002:a17:906:ce57:b0:7ad:e161:b026 with SMTP id se23-20020a170906ce5700b007ade161b026mr19418263ejb.760.1668629581089; Wed, 16 Nov 2022 12:13:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668629581; cv=none; d=google.com; s=arc-20160816; b=pnntHXoUvHOD6A09JQH8TpgZEwd7+p3KD9fD5LfycoRrRUY5EDNH83uTpeuOl9TPPR C63oLEvMIzzCJee7lAHRpwsNVmgZFVDKV8AiHhy+MsypRINTgqXUqkjJrIFCimpGo5OD 0EMvaWIJw1kyKf9of6V+MSVuVO+q9m/Vaji5pZTJGhQcfSIKXlLXEDpdu5bAILv5Q/hH Hu34zzNf6A8ii0UbgO60ZMQSq6abJ0+g7u5IhlOSTIcc5lYaKUtYSWIYd4aPhkViAhCd LwZVxpg1gQpt3NGps3D/0pBYjBVUKEAJ3gsL41iDNSTNsQpYo5PULafBGbt7vjTeiZoV D4rg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version; bh=BN5F/4SLMsWjv+SqMlOL2vb1K62iKbshTk4wJRTKB4w=; b=IUJxGeadSwJgar5fmIONttY1bwIGrISo73fDM7u4RN5B7EkQi/mL0FEFIAoEKepdzU rlGfO1brWbo09pu2tiX80faCSPU8KBvYbGNcSx+VZhdHmd5izOA72v7RQbv1l47j9aFZ 68L0E2FoOEzNWgUHdRYIlK0YY85EarUgoz3p2okT21M8hSXaRrATGJ4LPnfeC6ltgGvz NPQgqbhZz5OI75iolkJKqm9WwsTwJiRNHdhYtiOOScCBCjqfguA8laUFx0ppdcMUNsZK x3W7oYwPdMsG7wkrHVYF5CSCxnJy857xwWn2hxETx1a2KpdUceFRKRylTGOgx1YJp02j SJ1A== 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id p12-20020a05640243cc00b0046195676c75si14201575edc.536.2022.11.16.12.12.38; Wed, 16 Nov 2022 12:13:01 -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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234068AbiKPTu5 (ORCPT + 91 others); Wed, 16 Nov 2022 14:50:57 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54862 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230471AbiKPTuy (ORCPT ); Wed, 16 Nov 2022 14:50:54 -0500 Received: from mail-qt1-f179.google.com (mail-qt1-f179.google.com [209.85.160.179]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 83A5643AC2; Wed, 16 Nov 2022 11:50:53 -0800 (PST) Received: by mail-qt1-f179.google.com with SMTP id jr19so11408281qtb.7; Wed, 16 Nov 2022 11:50:53 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=BN5F/4SLMsWjv+SqMlOL2vb1K62iKbshTk4wJRTKB4w=; b=KaRNy+FTK13YzDLsfA5pYPI1a2aN6CSlBrS/XRrHwrSJD4DhoSG1XVVxL/38rdnVSj 8YRCtseQE0WFZ1M5xEYKXOzRI4N2O2HuetXHdNK7HbYsItFS0XUZZ55HVMLqZGW98KQC hntaGWxaN00I6KwK31vgcNcTf+FNoXVa/zlFKeLDjDExq2aPpNKhe0MB9Wr4fRiShjX6 xpZHCRJ5Qn5BGOogKi3U1JaaSwVetpE87CxksX3Z77mIybUpFNc2/wVyq4S7JjiIITkG /kpzcDWs8Xo1k33n9Nha3sekNlMACqUnV9U5yq7fef5WX/dwyOp+HFzjgvapShhi9bHB 838w== X-Gm-Message-State: ANoB5pmn929xuMgpZmgbbnpuv1Vy02Q6AtgG2L02drVyf12zcknEUdPA 8oVLnZGVp/jIAoyvoyA4JcC1/t8xtv6kgk4hl+A= X-Received: by 2002:ac8:5198:0:b0:3a5:1e6f:7e05 with SMTP id c24-20020ac85198000000b003a51e6f7e05mr22586496qtn.357.1668628252715; Wed, 16 Nov 2022 11:50:52 -0800 (PST) MIME-Version: 1.0 References: <20221108170103.3375832-1-nathan@kernel.org> In-Reply-To: From: "Rafael J. Wysocki" Date: Wed, 16 Nov 2022 20:50:41 +0100 Message-ID: Subject: Re: [PATCH] cpufreq: ACPI: Remove unused variables 'acpi_cpufreq_online' and 'ret' To: Nathan Chancellor Cc: "Rafael J. Wysocki" , Viresh Kumar , Stuart Hayes , Nick Desaulniers , Tom Rix , linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-1.6 required=5.0 tests=BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE, SPF_PASS autolearn=no 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 On Wed, Nov 16, 2022 at 8:34 PM Nathan Chancellor wrote: > > Hi all, > > Small ping, was there an issue with this change? It seems pretty > straight forward to me and it is wreaking havoc on our build matrix due > to -Werror. Applied now, thanks! > On Tue, Nov 08, 2022 at 10:01:03AM -0700, Nathan Chancellor wrote: > > Clang warns: > > > > drivers/cpufreq/acpi-cpufreq.c:970:24: error: variable 'ret' is uninitialized when used here [-Werror,-Wuninitialized] > > acpi_cpufreq_online = ret; > > ^~~ > > drivers/cpufreq/acpi-cpufreq.c:960:9: note: initialize the variable 'ret' to silence this warning > > int ret; > > ^ > > = 0 > > 1 error generated. > > > > Both ret and acpi_cpufreq_online are now unused so they can be safely > > removed, clearing up the warning. > > > > Fixes: 13fdbc8b8da6 ("cpufreq: ACPI: Defer setting boost MSRs") > > Link: https://github.com/ClangBuiltLinux/linux/issues/1757 > > Signed-off-by: Nathan Chancellor > > --- > > 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) > > > > base-commit: 21cdb6c18f85fe538ca8740bc79f11fbe08d0197 > > -- > > 2.38.1 > >