Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp2875813pxu; Sat, 19 Dec 2020 05:03:13 -0800 (PST) X-Google-Smtp-Source: ABdhPJzC3sWKPpW3SLM+RIsmjTLaQQDnBk/9vw3Y1X6TXb64iT2Tu9p08kjtgjW2xRi/qK0iyAGI X-Received: by 2002:a50:b224:: with SMTP id o33mr8865155edd.21.1608382993266; Sat, 19 Dec 2020 05:03:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1608382993; cv=none; d=google.com; s=arc-20160816; b=exGrdJ33BvWXub2H2zUHEsdrWRGgr3rmnX+s4W9HnYWfPYB7sN+t5i1KIFySI5nzwj XtAu+/oKq4qYSBZHYtZP2b83rmozyXSBGVHQ57pSym3QTxovPV8be2YcFiDOInbf9oFr vgzMG2ZnzzD0T2HrIEA1IL4z602QRbZm54UX+cqXeFvB9H2S9fHuUCiltj7+Z6AmMXlj IUogwkuRGES/HAzLKwlmMqW/NbNqefV5TGYkOKueqda1sC5St27KafvT+9ZX8rmljOxF Sdh8yzBCaBd+UeHOvofJO3dHPjiA5e0HuRxH2Efzh8olDdKBOO80wnL/bayI0U2/NVnz bNyA== 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; bh=B997Hxd8oP8VLkmwtcGAsYkHYLvqVP755HRREAIHoyk=; b=kloG00VvmI1ANdf3ZVHA//lT1uSriH1bmfqMH5/VhwnkFCQaUs2ADbI97BHObnoIUq ilv6G1yW5tj6WgqPB3UYUhAWLU+qljljPNM6Q+dxnIP3CXHL+nF309ZOG+L56aNrQmV5 LOKYH1wAl+whZrLXL+joEIcxDgeJ9aQ0nLprwlftYB2PyiKpLzk1mZ16WGD5CnHjr843 RlU/Cr3OMi3x7jdtMgR7o13h3r+4WQVdSBy12kanfVy6w73iatJfeznGoQpLEf7jz7hA NBwA/POsM7psfv2IpinSY/+jbmXHbkLtB9GxsOteoRXvdXRzJeO6uWQs7G3B0Ysw7S7L 5z9Q== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (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 dk7si7178594ejb.687.2020.12.19.05.02.50; Sat, 19 Dec 2020 05:03:13 -0800 (PST) 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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726865AbgLSNBG (ORCPT + 99 others); Sat, 19 Dec 2020 08:01:06 -0500 Received: from mail.kernel.org ([198.145.29.99]:46958 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728293AbgLSM7p (ORCPT ); Sat, 19 Dec 2020 07:59:45 -0500 From: Greg Kroah-Hartman Authentication-Results: mail.kernel.org; dkim=permerror (bad message/signature format) To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, James Morse , Borislav Petkov , Reinette Chatre , Sudip Mukherjee Subject: [PATCH 5.9 48/49] x86/resctrl: Remove unused struct mbm_state::chunks_bw Date: Sat, 19 Dec 2020 13:58:52 +0100 Message-Id: <20201219125347.013831067@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201219125344.671832095@linuxfoundation.org> References: <20201219125344.671832095@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: James Morse commit abe8f12b44250d02937665033a8b750c1bfeb26e upstream Nothing reads struct mbm_states's chunks_bw value, its a copy of chunks. Remove it. Signed-off-by: James Morse Signed-off-by: Borislav Petkov Reviewed-by: Reinette Chatre Link: https://lkml.kernel.org/r/20200708163929.2783-2-james.morse@arm.com Signed-off-by: Sudip Mukherjee Signed-off-by: Greg Kroah-Hartman --- arch/x86/kernel/cpu/resctrl/internal.h | 2 -- arch/x86/kernel/cpu/resctrl/monitor.c | 3 +-- 2 files changed, 1 insertion(+), 4 deletions(-) --- a/arch/x86/kernel/cpu/resctrl/internal.h +++ b/arch/x86/kernel/cpu/resctrl/internal.h @@ -283,7 +283,6 @@ struct rftype { * struct mbm_state - status for each MBM counter in each domain * @chunks: Total data moved (multiply by rdt_group.mon_scale to get bytes) * @prev_msr Value of IA32_QM_CTR for this RMID last time we read it - * @chunks_bw Total local data moved. Used for bandwidth calculation * @prev_bw_msr:Value of previous IA32_QM_CTR for bandwidth counting * @prev_bw The most recent bandwidth in MBps * @delta_bw Difference between the current and previous bandwidth @@ -292,7 +291,6 @@ struct rftype { struct mbm_state { u64 chunks; u64 prev_msr; - u64 chunks_bw; u64 prev_bw_msr; u32 prev_bw; u32 delta_bw; --- a/arch/x86/kernel/cpu/resctrl/monitor.c +++ b/arch/x86/kernel/cpu/resctrl/monitor.c @@ -279,8 +279,7 @@ static void mbm_bw_count(u32 rmid, struc return; chunks = mbm_overflow_count(m->prev_bw_msr, tval, rr->r->mbm_width); - m->chunks_bw += chunks; - m->chunks = m->chunks_bw; + m->chunks += chunks; cur_bw = (chunks * r->mon_scale) >> 20; if (m->delta_comp)