https://github.com/torvalds/linux
Revision 76af6a054da4055305ddb28c5eb151b9ee4f74f9 authored by Dave Hansen on 18 October 2021, 22:15:32 UTC, committed by Linus Torvalds on 19 October 2021, 06:22:02 UTC
Once upon a time, the node demotion updates were driven solely by memory
hotplug events.  But now, there are handlers for both CPU and memory
hotplug.

However, the #ifdef around the code checks only memory hotplug.  A
system that has HOTPLUG_CPU=y but MEMORY_HOTPLUG=n would miss CPU
hotplug events.

Update the #ifdef around the common code.  Add memory and CPU-specific
#ifdefs for their handlers.  These memory/CPU #ifdefs avoid unused
function warnings when their Kconfig option is off.

[arnd@arndb.de: rework hotplug_memory_notifier() stub]
  Link: https://lkml.kernel.org/r/20211013144029.2154629-1-arnd@kernel.org

Link: https://lkml.kernel.org/r/20210924161255.E5FE8F7E@davehans-spike.ostc.intel.com
Fixes: 884a6e5d1f93 ("mm/migrate: update node demotion order on hotplug events")
Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Cc: "Huang, Ying" <ying.huang@intel.com>
Cc: Michal Hocko <mhocko@suse.com>
Cc: Wei Xu <weixugc@google.com>
Cc: Oscar Salvador <osalvador@suse.de>
Cc: David Rientjes <rientjes@google.com>
Cc: Dan Williams <dan.j.williams@intel.com>
Cc: David Hildenbrand <david@redhat.com>
Cc: Greg Thelen <gthelen@google.com>
Cc: Yang Shi <yang.shi@linux.alibaba.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent 295be91
History
Tip revision: 76af6a054da4055305ddb28c5eb151b9ee4f74f9 authored by Dave Hansen on 18 October 2021, 22:15:32 UTC
mm/migrate: add CPU hotplug to demotion #ifdef
Tip revision: 76af6a0
File Mode Size
9p
adfs
affs
afs
autofs
befs
bfs
btrfs
cachefiles
ceph
cifs
coda
configfs
cramfs
crypto
debugfs
devpts
dlm
ecryptfs
efivarfs
efs
erofs
exfat
exportfs
ext2
ext4
f2fs
fat
freevxfs
fscache
fuse
gfs2
hfs
hfsplus
hostfs
hpfs
hugetlbfs
iomap
isofs
jbd2
jffs2
jfs
kernfs
ksmbd
lockd
minix
netfs
nfs
nfs_common
nfsd
nilfs2
nls
notify
ntfs
ntfs3
ocfs2
omfs
openpromfs
orangefs
overlayfs
proc
pstore
qnx4
qnx6
quota
ramfs
reiserfs
romfs
smbfs_common
squashfs
sysfs
sysv
tracefs
ubifs
udf
ufs
unicode
vboxsf
verity
xfs
zonefs
Kconfig -rw-r--r-- 9.6 KB
Kconfig.binfmt -rw-r--r-- 7.0 KB
Makefile -rw-r--r-- 4.5 KB
aio.c -rw-r--r-- 56.4 KB
anon_inodes.c -rw-r--r-- 6.8 KB
attr.c -rw-r--r-- 13.3 KB
bad_inode.c -rw-r--r-- 5.8 KB
binfmt_aout.c -rw-r--r-- 8.2 KB
binfmt_elf.c -rw-r--r-- 60.4 KB
binfmt_elf_fdpic.c -rw-r--r-- 43.6 KB
binfmt_flat.c -rw-r--r-- 28.5 KB
binfmt_misc.c -rw-r--r-- 17.4 KB
binfmt_script.c -rw-r--r-- 4.2 KB
buffer.c -rw-r--r-- 88.4 KB
char_dev.c -rw-r--r-- 16.5 KB
compat_binfmt_elf.c -rw-r--r-- 3.7 KB
coredump.c -rw-r--r-- 28.3 KB
d_path.c -rw-r--r-- 11.5 KB
dax.c -rw-r--r-- 46.1 KB
dcache.c -rw-r--r-- 85.4 KB
direct-io.c -rw-r--r-- 39.7 KB
drop_caches.c -rw-r--r-- 1.9 KB
eventfd.c -rw-r--r-- 12.0 KB
eventpoll.c -rw-r--r-- 63.9 KB
exec.c -rw-r--r-- 49.4 KB
fcntl.c -rw-r--r-- 23.8 KB
fhandle.c -rw-r--r-- 6.8 KB
file.c -rw-r--r-- 29.8 KB
file_table.c -rw-r--r-- 10.2 KB
filesystems.c -rw-r--r-- 6.5 KB
fs-writeback.c -rw-r--r-- 78.9 KB
fs_context.c -rw-r--r-- 17.7 KB
fs_parser.c -rw-r--r-- 10.1 KB
fs_pin.c -rw-r--r-- 1.9 KB
fs_struct.c -rw-r--r-- 3.4 KB
fs_types.c -rw-r--r-- 2.5 KB
fsopen.c -rw-r--r-- 11.0 KB
init.c -rw-r--r-- 6.1 KB
inode.c -rw-r--r-- 62.3 KB
internal.h -rw-r--r-- 5.6 KB
io-wq.c -rw-r--r-- 31.0 KB
io-wq.h -rw-r--r-- 3.7 KB
io_uring.c -rw-r--r-- 269.8 KB
ioctl.c -rw-r--r-- 24.0 KB
kernel_read_file.c -rw-r--r-- 4.3 KB
libfs.c -rw-r--r-- 39.3 KB
locks.c -rw-r--r-- 78.6 KB
mbcache.c -rw-r--r-- 12.0 KB
mount.h -rw-r--r-- 4.0 KB
mpage.c -rw-r--r-- 20.5 KB
namei.c -rw-r--r-- 132.6 KB
namespace.c -rw-r--r-- 110.2 KB
no-block.c -rw-r--r-- 478 bytes
nsfs.c -rw-r--r-- 6.6 KB
open.c -rw-r--r-- 34.2 KB
pipe.c -rw-r--r-- 34.6 KB
pnode.c -rw-r--r-- 15.1 KB
pnode.h -rw-r--r-- 2.0 KB
posix_acl.c -rw-r--r-- 23.6 KB
proc_namespace.c -rw-r--r-- 8.1 KB
read_write.c -rw-r--r-- 39.1 KB
readdir.c -rw-r--r-- 13.9 KB
remap_range.c -rw-r--r-- 13.8 KB
select.c -rw-r--r-- 34.7 KB
seq_file.c -rw-r--r-- 25.5 KB
signalfd.c -rw-r--r-- 9.0 KB
splice.c -rw-r--r-- 38.8 KB
stack.c -rw-r--r-- 2.5 KB
stat.c -rw-r--r-- 21.2 KB
statfs.c -rw-r--r-- 9.7 KB
super.c -rw-r--r-- 45.2 KB
sync.c -rw-r--r-- 10.5 KB
timerfd.c -rw-r--r-- 13.9 KB
userfaultfd.c -rw-r--r-- 54.5 KB
utimes.c -rw-r--r-- 7.6 KB
xattr.c -rw-r--r-- 27.4 KB

back to top