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: <Z5Eyg58jl8YqkU_j@gourry-fedora-PF4VCD3F>
Date: Wed, 22 Jan 2025 13:01:39 -0500
From: Gregory Price <gourry@...rry.net>
To: Bharata B Rao <bharata@....com>
Cc: abhishekd@...a.com, akpm@...ux-foundation.org, david@...hat.com,
	donettom@...ux.ibm.com, feng.tang@...el.com, hannes@...xchg.org,
	kbusch@...a.com, kernel-team@...a.com, linux-doc@...r.kernel.org,
	linux-kernel@...r.kernel.org, linux-mm@...ck.org,
	nehagholkar@...a.com, nphamcs@...il.com,
	ying.huang@...ux.alibaba.com
Subject: Re: [PATCH v3 2/6] memory: move conditionally defined enums use
 inside ifdef tags

On Tue, Jan 21, 2025 at 10:03:55AM +0530, Bharata B Rao wrote:
> I don't think moving count_vm_numa_event() to within
> CONFIG_NUMA_BALANCING is necessary as it is defined separately as NOP
> for !CONFIG_NUMA_BALANCING.
> 

NUMA_HINT_FAULTS and NUMA_HINT_FAULTS_LOCAL are only defined if
CONFIG_NUMA_BALANCING

include/linux/vm_event_item.h

#ifdef CONFIG_NUMA_BALANCING
                NUMA_PTE_UPDATES,
                NUMA_HUGE_PTE_UPDATES,
                NUMA_HINT_FAULTS,
                NUMA_HINT_FAULTS_LOCAL,
                NUMA_PAGE_MIGRATE,
#endif

> In fact numa_migrate_check() should be within CONFIG_NUMA_BALANCING as
> it should ideally be  called only if NUMA balancing is enabled. The same
> could be said for the callers of numa_migrate_check() which are
> do_numa_page() and do_huge_pmd_numa_page().
> 

Really what i'm reading is that these functions are in the wrong file,
since ifdef spaghetti in *.c files is not encouraged.  These functions
should be moved somewhere else and given stubs if the build option is
off.

> Regards,
> Bharata.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ