From patchwork Fri Feb 10 23:45:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Borislav Petkov X-Patchwork-Id: 55654 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp1237243wrn; Fri, 10 Feb 2023 15:47:11 -0800 (PST) X-Google-Smtp-Source: AK7set8mN2TKYR7hE3oUbkLBtwjjry6QI1vaA3xMasGgBydGrPbeVNImVKq1L9nkNNLc6lrEim78 X-Received: by 2002:a17:906:7952:b0:884:b467:ae4a with SMTP id l18-20020a170906795200b00884b467ae4amr21337978ejo.64.1676072831688; Fri, 10 Feb 2023 15:47:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1676072831; cv=none; d=google.com; s=arc-20160816; b=QutubPSk2JSzu4DCJLBoXQAOxZjKliZnhvy0bZk54L9+6DB8h1PtU9cvAK2gH4Sjev XjsLjhHVPTGNJXvekkZgwQ86B66tHv/3PiQLo+2o6xE2P9F8Wl3jGX8Bia+LfOv2l7UO wDk2dlA7238M09IhyCiUuHiVnkutll8ubkY6R+KbRiJyRipRMsePRNVVucqEINAowehC 4dV9HQXfpWYuwfat/W0IPH+GTn/PSify/81vjkZMoZV8cFvrS67mJzYBAU4vP7Yalh9r 01ErPakSAQQa9v5d/HTP9n2MCZhUxsDRh4lA3dypKkNcaLPlfe4TGUyIt/4dQ+DueJQY 2zrg== 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:dkim-signature; bh=PJ0MCIKmicATxfrO7Q7VcthrEobh2IANYeLpCnb2HiE=; b=bSJh01XQRIc6fQV1j2zVbrg6h03RLHcB5ycnBHTNIOeg4mwPZK/hojwcXrjric3ZIc BPw1TkF9v+o2+RKgcKCbqswCmSYGeVp2exAPqo4+cPhqfrUkbdJOJmhMMHJO06J6LwES BEPeIn+OzU9t6zabR1nFrz9zM9/H0fu/Rgq6BPd4UhJB73tbZbs4oMc1w+voysaHM+YH 4BZ7qbSRtS7wLkr5csW9pGfMzdosgWulftGrLVnVvSTX6QUiIXHcTNCNUXHL59sTxqxs lxPoGcrYmtw+CTXEHywwKJ00p5sUwfKXTXg94aFyB+t/ODLyTSAPs3vYLXLvpSMfxnJ8 /7Gg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=HzZbrocO; 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=alien8.de Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id up30-20020a170907cc9e00b008787afd881asi5841397ejc.458.2023.02.10.15.46.48; Fri, 10 Feb 2023 15:47:11 -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; dkim=pass header.i=@alien8.de header.s=dkim header.b=HzZbrocO; 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=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229907AbjBJXqW (ORCPT + 99 others); Fri, 10 Feb 2023 18:46:22 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56460 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229836AbjBJXqU (ORCPT ); Fri, 10 Feb 2023 18:46:20 -0500 Received: from mail.skyhub.de (mail.skyhub.de [5.9.137.197]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0948516330 for ; Fri, 10 Feb 2023 15:45:53 -0800 (PST) Received: from zn.tnic (p5de8e9fe.dip0.t-ipconnect.de [93.232.233.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 456D91EC0758; Sat, 11 Feb 2023 00:45:48 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1676072748; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type: content-transfer-encoding:content-transfer-encoding:in-reply-to: references; bh=PJ0MCIKmicATxfrO7Q7VcthrEobh2IANYeLpCnb2HiE=; b=HzZbrocOhAKhfcka5Zv+XFRFjIC35p0EyEw+Y2T2pBGIvQrUpdIC1A28BSZyWQxvKCB8qf XP0ltu6K3NRJ+D3rvZWImFBSKC9QXCTxRFauNQcQ6b9LRCr5XckK8zqqyKcFBroLR5Bq9Z SdEJSP+cD1n7CLO6c2bonbt8JySXwnk= From: Borislav Petkov To: X86 ML Cc: LKML Subject: [PATCH] x86/cacheinfo: Remove unused trace variable Date: Sat, 11 Feb 2023 00:45:41 +0100 Message-Id: <20230210234541.9694-1-bp@alien8.de> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1757489745646354109?= X-GMAIL-MSGID: =?utf-8?q?1757489745646354109?= From: "Borislav Petkov (AMD)" 15cd8812ab2c ("x86: Remove the CPU cache size printk's") removed the last use of the trace local var. Remove it too and the useless trace cache case. No functional changes. Signed-off-by: Borislav Petkov (AMD) --- arch/x86/kernel/cpu/cacheinfo.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/arch/x86/kernel/cpu/cacheinfo.c b/arch/x86/kernel/cpu/cacheinfo.c index f4e5aa27eec6..4063e8991211 100644 --- a/arch/x86/kernel/cpu/cacheinfo.c +++ b/arch/x86/kernel/cpu/cacheinfo.c @@ -734,7 +734,7 @@ void init_hygon_cacheinfo(struct cpuinfo_x86 *c) void init_intel_cacheinfo(struct cpuinfo_x86 *c) { /* Cache sizes */ - unsigned int trace = 0, l1i = 0, l1d = 0, l2 = 0, l3 = 0; + unsigned int l1i = 0, l1d = 0, l2 = 0, l3 = 0; unsigned int new_l1d = 0, new_l1i = 0; /* Cache sizes from cpuid(4) */ unsigned int new_l2 = 0, new_l3 = 0, i; /* Cache sizes from cpuid(4) */ unsigned int l2_id = 0, l3_id = 0, num_threads_sharing, index_msb; @@ -835,9 +835,6 @@ void init_intel_cacheinfo(struct cpuinfo_x86 *c) case LVL_3: l3 += cache_table[k].size; break; - case LVL_TRACE: - trace += cache_table[k].size; - break; } break;