Thread (8 messages) 8 messages, 3 authors, 2022-02-02

Re: [PATCH RFC v1] drivers/base/node: consolidate node device subsystem initialization in node_dev_init()

From: Anatoly Pugachev <hidden>
Date: 2022-02-01 10:03:02
Also in: linux-arm-kernel, linux-mips, linux-mm, linux-riscv, linux-s390, linux-sh, lkml, sparclinux

On Mon, Jan 31, 2022 at 2:11 PM David Hildenbrand [off-list ref] wrote:
... and call node_dev_init() after memory_dev_init() from driver_init(),
so before any of the existing arch/subsys calls. All online nodes should
be known at that point.

This is in line with memory_dev_init(), which initializes the memory
device subsystem and creates all memory block devices.

Similar to memory_dev_init(), panic() if anything goes wrong, we don't
want to continue with such basic initialization errors.

The important part is that node_dev_init() gets called after
memory_dev_init() and after cpu_dev_init(), but before any of the
relevant archs call register_cpu() to register the new cpu device under
the node device. The latter should be the case for the current users
of topology_init().

RFC because I tested only on x86-64 and s390x, I think I cross-compiled all
applicable architectures except riscv and sparc.
Compiled and boot tested on sparc.

Tested-by: Anatoly Pugachev <redacted> (sparc64)
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help