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]
Date:   Tue, 29 Nov 2022 13:10:51 +0100
From:   Frederic Weisbecker <frederic@...nel.org>
To:     Leonardo Brás <leobras@...hat.com>
Cc:     Peter Zijlstra <peterz@...radead.org>,
        Steffen Klassert <steffen.klassert@...unet.com>,
        Herbert Xu <herbert@...dor.apana.org.au>,
        "David S. Miller" <davem@...emloft.net>,
        Bjorn Helgaas <bhelgaas@...gle.com>,
        Ingo Molnar <mingo@...hat.com>,
        Juri Lelli <juri.lelli@...hat.com>,
        Vincent Guittot <vincent.guittot@...aro.org>,
        Dietmar Eggemann <dietmar.eggemann@....com>,
        Steven Rostedt <rostedt@...dmis.org>,
        Ben Segall <bsegall@...gle.com>, Mel Gorman <mgorman@...e.de>,
        Daniel Bristot de Oliveira <bristot@...hat.com>,
        Valentin Schneider <vschneid@...hat.com>,
        Tejun Heo <tj@...nel.org>,
        Lai Jiangshan <jiangshanlai@...il.com>,
        Eric Dumazet <edumazet@...gle.com>,
        Jakub Kicinski <kuba@...nel.org>,
        Paolo Abeni <pabeni@...hat.com>, Phil Auld <pauld@...hat.com>,
        Antoine Tenart <atenart@...nel.org>,
        Christophe JAILLET <christophe.jaillet@...adoo.fr>,
        Wang Yufen <wangyufen@...wei.com>, mtosatti@...hat.com,
        linux-crypto@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-pci@...r.kernel.org, netdev@...r.kernel.org,
        fweisbec@...il.com
Subject: Re: [PATCH v2 3/4] sched/isolation: Add HK_TYPE_WQ to isolcpus=domain

On Fri, Oct 14, 2022 at 01:27:25PM -0300, Leonardo Brás wrote:
> Hello Frederic,
> 
> So, IIUC you are removing all flags composing nohz_full= parameter in favor of a
> unified NOHZ_FULL flag. 
> 
> I am very new to the code, and I am probably missing the whole picture, but I
> actually think it's a good approach to keep them split for a couple reasons:
> 1 - They are easier to understand in code (IMHO): 
> "This cpu should not do this, because it's not able to do WQ housekeeping" looks
> better than "because it's not in DOMAIN or NOHZ_FULL housekeeping"

A comment above each site may solve that.

> 
> 2 - They are simpler for using: 
> Suppose we have this function that should run at a WQ, but we want to keep them
> out of the isolated cpus. If we have the unified flags, we need to combine both
> DOMAIN and NOHZ_FULL bitmasks, and then combine it again with something like
> cpu_online_mask. It usually means allocating a new cpumask_t, and also freeing
> it afterwards.
> If we have a single WQ flag, we can avoid the allocation altogether by using
> for_each_cpu_and(), making the code much simpler.

I guess having a specific function for workqueues would arrange for it.

> 
> 3 - It makes easier to compose new isolation modes:
> In case the future requires a new isolation mode that also uses the types of
> isolation we currently have implemented, it would be much easier to just compose
> it with the current HK flags, instead of having to go through all usages and do
> a cpumask_and() there. Also, new isolation modes would make (2) worse.

Actually having a new feature merged in HK_NOHZ_FULL would make it easier to
handle as it avoids spreading cpumasks. I'm not sure I understand what you
mean.

Thanks.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ