lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <c55d1433-2573-4458-0175-95f2a4b259b8@arm.com>
Date:   Fri, 17 Sep 2021 17:58:07 +0100
From:   James Morse <james.morse@....com>
To:     Reinette Chatre <reinette.chatre@...el.com>, x86@...nel.org,
        linux-kernel@...r.kernel.org
Cc:     Fenghua Yu <fenghua.yu@...el.com>,
        Thomas Gleixner <tglx@...utronix.de>,
        Ingo Molnar <mingo@...hat.com>, Borislav Petkov <bp@...en8.de>,
        H Peter Anvin <hpa@...or.com>,
        Babu Moger <Babu.Moger@....com>,
        shameerali.kolothum.thodi@...wei.com,
        Jamie Iles <jamie@...iainc.com>,
        D Scott Phillips OS <scott@...amperecomputing.com>,
        lcherian@...vell.com, bobo.shaobowang@...wei.com
Subject: Re: [PATCH v1 11/20] x86/resctrl: Calculate bandwidth from the total
 bytes counter

Hi Reinette,

On 01/09/2021 22:31, Reinette Chatre wrote:
> Apologies but I find the changelog hard to understand.

No problem, clearly room for improvement!


> On 7/29/2021 3:36 PM, James Morse wrote:
>> mbm_bw_count() maintains its own copy of prev_msr to allow it to
>> calculate the bandwidth as the number of chunks counted since the
>> last time mbm_bw_count() was invoked.
> 
> ok, I understand there is an extra copy

The point I was trying to get across here is mbm_bw_count() is holding a hardware value,
which means it isn't architecture agnostic. Calculating bytes first paves the way to using
an arch helper that returns bytes.

This was originally later in the series, and it looks like it got damaged during a rebase.
I've rewritten it to calculate bandwidth based on the value read by the previous
__mon_event_count(), this is simpler and less noisy for the rest of the series.



Thanks,

James

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ