On 28.01.22 16:15, David Hildenbrand 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(). > > Cc: Andrew Morton <a...@linux-foundation.org> > Cc: Greg Kroah-Hartman <gre...@linuxfoundation.org> > Cc: Michal Hocko <mho...@suse.com> > Cc: Oscar Salvador <osalva...@suse.de> > Cc: Catalin Marinas <catalin.mari...@arm.com> > Cc: Will Deacon <w...@kernel.org> > Cc: Thomas Bogendoerfer <tsbog...@alpha.franken.de> > Cc: Michael Ellerman <m...@ellerman.id.au> > Cc: Benjamin Herrenschmidt <b...@kernel.crashing.org> > Cc: Paul Mackerras <pau...@samba.org> > Cc: Paul Walmsley <paul.walms...@sifive.com> > Cc: Palmer Dabbelt <pal...@dabbelt.com> > Cc: Albert Ou <a...@eecs.berkeley.edu> > Cc: Heiko Carstens <h...@linux.ibm.com> > Cc: Vasily Gorbik <g...@linux.ibm.com> > Cc: Yoshinori Sato <ys...@users.sourceforge.jp> > Cc: Rich Felker <dal...@libc.org> > Cc: "David S. Miller" <da...@davemloft.net> > Cc: Thomas Gleixner <t...@linutronix.de> > Cc: Ingo Molnar <mi...@redhat.com> > Cc: Borislav Petkov <b...@alien8.de> > Cc: Dave Hansen <dave.han...@linux.intel.com> > Cc: "Rafael J. Wysocki" <raf...@kernel.org> > Cc: x...@kernel.org > Cc: linux-arm-ker...@lists.infradead.org > Cc: linux-ker...@vger.kernel.org > Cc: linux-i...@vger.kernel.org > Cc: linux-m...@vger.kernel.org > Cc: linuxppc-dev@lists.ozlabs.org > Cc: linux-ri...@lists.infradead.org > Cc: linux-s...@vger.kernel.org > Cc: linux...@vger.kernel.org > Cc: sparcli...@vger.kernel.org > Cc: linux...@kvack.org > Signed-off-by: David Hildenbrand <da...@redhat.com>
If there are no further comments, then I'll resend as !RFC with a slightly extended patch description, testing at least under arm64 and ppc64 as they are relatively easy to test for me. -- Thanks, David / dhildenb