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] [day] [month] [year] [list]
Message-ID: <877dfactwm.fsf@yhuang6-desk2.ccr.corp.intel.com>
Date:   Tue, 21 Sep 2021 14:41:29 +0800
From:   "Huang, Ying" <ying.huang@...el.com>
To:     Thomas Gleixner <tglx@...utronix.de>
Cc:     Andrew Morton <akpm@...ux-foundation.org>, linux-mm@...ck.org,
        linux-kernel@...r.kernel.org,
        Dave Hansen <dave.hansen@...ux.intel.com>,
        Yang Shi <shy828301@...il.com>, Zi Yan <ziy@...dia.com>,
        Michal Hocko <mhocko@...e.com>, Wei Xu <weixugc@...gle.com>,
        Oscar Salvador <osalvador@...e.de>,
        David Rientjes <rientjes@...gle.com>,
        Dan Williams <dan.j.williams@...el.com>,
        David Hildenbrand <david@...hat.com>,
        Greg Thelen <gthelen@...gle.com>,
        Keith Busch <kbusch@...nel.org>
Subject: Re: [PATCH] mm/migrate: fix CPUHP state to update node demotion order

Thomas Gleixner <tglx@...utronix.de> writes:

> On Sat, Sep 18 2021 at 10:58, Huang Ying wrote:
>> @@ -72,6 +72,7 @@ enum cpuhp_state {
>>  	CPUHP_SLUB_DEAD,
>>  	CPUHP_DEBUG_OBJ_DEAD,
>>  	CPUHP_MM_WRITEBACK_DEAD,
>> +	CPUHP_MM_DEMOTION_OFFLINE,
>
> Please keep the _DEAD convention in that section. The plugged CPU is
> already gone.

Sure.  Will do that.

>>  	CPUHP_MM_VMSTAT_DEAD,
>>  	CPUHP_SOFTIRQ_DEAD,
>>  	CPUHP_NET_MVNETA_DEAD,
>> @@ -240,6 +241,7 @@ enum cpuhp_state {
>>  	CPUHP_AP_BASE_CACHEINFO_ONLINE,
>>  	CPUHP_AP_ONLINE_DYN,
>>  	CPUHP_AP_ONLINE_DYN_END		= CPUHP_AP_ONLINE_DYN + 30,
>> +	CPUHP_AP_MM_DEMOTION_ONLINE,
>
> Are there any ordering requirements of these states vs. other CPU
> hotplug states?
>
> If not, then please use the dynamically allocated states.
>
> If so, then please add a comment:
>
> +	/* Must be before CPUHP_XXX and after CPUHP_YYY */
> +	CPUHP_MM_DEMOTION_OFFLINE,

The callbacks need to be called after node_states[N_CPU] has been
updated during CPU online/offline.  While node_states[N_CPU] is updated
in CPUHP_AP_ONLINE_DYN and CPUHP_MM_VMSTAT_DEAD.  So the new state must
be before CPUHP_MM_VMSTAT_DEAD for offline and after CPUHP_AP_ONLINE_DYN
for online.  I will update the patch and add the comments.

Best Regards,
Huang, Ying

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ