[{"id":1761566,"web_url":"http://patchwork.ozlabs.org/comment/1761566/","msgid":"<87h8wm686b.fsf@concordia.ellerman.id.au>","date":"2017-09-01T10:10:36","subject":"Re: [PATCH V12] powerpc/vphn: Update CPU topology when VPHN enabled","submitter":{"id":46580,"url":"http://patchwork.ozlabs.org/api/people/46580/","name":"Michael Ellerman","email":"mpe@ellerman.id.au"},"content":"Hi Michael,\n\nThanks for trying to reduce this down to the minimum required.\n\nBut ...\n\nMichael Bringmann <mwb@linux.vnet.ibm.com> writes:\n> powerpc/numa: On Power systems with shared configurations of CPUs\n> and memory, there are some issues with the association of additional\n> CPUs and memory to nodes when hot-adding resources.  This patch\n> addresses some of those problems.\n>\n> First, it corrects the currently broken capability to set the\n> topology for shared CPUs in LPARs.  At boot time for shared CPU\n> lpars, the topology for each CPU was being set to node zero.  Now\n> when numa_update_cpu_topology() is called appropriately, the Virtual\n> Processor Home Node (VPHN) capabilities information provided by the\n> pHyp allows the appropriate node in the shared configuration to be\n> selected for the CPU.\n\nThat should be one patch.\n\n> Next, it updates the initialization checks to independently recognize\n> PRRN or VPHN support.\n\nAnd another.\n\n> Next, during hotplug CPU operations, it resets the timer on topology\n> update work function to a small value to better ensure that the CPU\n> topology is detected and configured sooner.\n\nAnother.\n\n> Also, fix an end-of-updates processing problem observed occasionally\n> in numa_update_cpu_topology().\n\nAnd another.\n\n\nI would have let you get away with lumping it all in together, except\nthat it doesn't compile when CONFIG_PPC_SPLPAR=n:\n\n  In file included from ../include/linux/topology.h:35:0,\n                   from ../include/linux/gfp.h:8,\n                   from ../include/linux/irq.h:17,\n                   from ../arch/powerpc/include/asm/hardirq.h:5,\n                   from ../include/linux/hardirq.h:8,\n                   from ../include/linux/interrupt.h:12,\n                   from ../arch/powerpc/platforms/pseries/hotplug-cpu.c:24:\n  ../arch/powerpc/platforms/pseries/hotplug-cpu.c: In function ‘dlpar_online_cpu’:\n  ../arch/powerpc/include/asm/topology.h:103:38: error: statement with no effect [-Werror=unused-value]\n   #define timed_topology_update(nsecs) 0\n                                        ^\n  ../arch/powerpc/platforms/pseries/hotplug-cpu.c:366:4: note: in expansion of macro ‘timed_topology_update’\n      timed_topology_update(1);\n      ^~~~~~~~~~~~~~~~~~~~~\n  ../arch/powerpc/platforms/pseries/hotplug-cpu.c: In function ‘dlpar_offline_cpu’:\n  ../arch/powerpc/include/asm/topology.h:103:38: error: statement with no effect [-Werror=unused-value]\n   #define timed_topology_update(nsecs) 0\n                                        ^\n  ../arch/powerpc/platforms/pseries/hotplug-cpu.c:533:5: note: in expansion of macro ‘timed_topology_update’\n       timed_topology_update(1);\n       ^~~~~~~~~~~~~~~~~~~~~\n  cc1: all warnings being treated as errors\n\n\nSo please fix that up, split it, and resend.\n\nI know it would have been fairly easy for me to fix that compiler error,\nbut it tells me you haven't tested that configuration at all, which is\nthe bigger problem. Please at least give it a smoke test.\n\ncheers","headers":{"Return-Path":"<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>","X-Original-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Delivered-To":["patchwork-incoming@ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Received":["from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\t(using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3xkFS96H3tz9t2Z\n\tfor <patchwork-incoming@ozlabs.org>;\n\tFri,  1 Sep 2017 20:13:13 +1000 (AEST)","from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\tby lists.ozlabs.org (Postfix) with ESMTP id 3xkFS95QQ9zDrKx\n\tfor <patchwork-incoming@ozlabs.org>;\n\tFri,  1 Sep 2017 20:13:13 +1000 (AEST)","from ozlabs.org (ozlabs.org [IPv6:2401:3900:2:1::2])\n\t(using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby lists.ozlabs.org (Postfix) with ESMTPS id 3xkFP94vvvzDqmb\n\tfor <linuxppc-dev@lists.ozlabs.org>;\n\tFri,  1 Sep 2017 20:10:37 +1000 (AEST)","from authenticated.ozlabs.org (localhost [127.0.0.1])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128\n\tbits)) (No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPSA id 3xkFP92YBkz9t2Z;\n\tFri,  1 Sep 2017 20:10:37 +1000 (AEST)"],"From":"Michael Ellerman <mpe@ellerman.id.au>","To":"Michael Bringmann <mwb@linux.vnet.ibm.com>, linuxppc-dev@lists.ozlabs.org,\n\tlinux-kernel@vger.kernel.org","Subject":"Re: [PATCH V12] powerpc/vphn: Update CPU topology when VPHN enabled","In-Reply-To":"<ab71f6fe-4afa-16ce-ee95-4f255a4ece44@linux.vnet.ibm.com>","References":"<ab71f6fe-4afa-16ce-ee95-4f255a4ece44@linux.vnet.ibm.com>","User-Agent":"Notmuch/0.21 (https://notmuchmail.org)","Date":"Fri, 01 Sep 2017 20:10:36 +1000","Message-ID":"<87h8wm686b.fsf@concordia.ellerman.id.au>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Transfer-Encoding":"quoted-printable","X-BeenThere":"linuxppc-dev@lists.ozlabs.org","X-Mailman-Version":"2.1.23","Precedence":"list","List-Id":"Linux on PowerPC Developers Mail List\n\t<linuxppc-dev.lists.ozlabs.org>","List-Unsubscribe":"<https://lists.ozlabs.org/options/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=unsubscribe>","List-Archive":"<http://lists.ozlabs.org/pipermail/linuxppc-dev/>","List-Post":"<mailto:linuxppc-dev@lists.ozlabs.org>","List-Help":"<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=help>","List-Subscribe":"<https://lists.ozlabs.org/listinfo/linuxppc-dev>,\n\t<mailto:linuxppc-dev-request@lists.ozlabs.org?subject=subscribe>","Cc":"Nathan Fontenot <nfont@linux.vnet.ibm.com>,\n\tMichael Bringmann <mwb@linux.vnet.ibm.com>,\n\tJohn Allen <jallen@linux.vnet.ibm.com>","Errors-To":"linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org","Sender":"\"Linuxppc-dev\"\n\t<linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org>"}}]