From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Hildenbrand Date: Wed, 08 May 2019 07:21:43 +0000 Subject: Re: [PATCH v2 7/8] mm/memory_hotplug: Make unregister_memory_block_under_nodes() never fail Message-Id: <1d369ae4-7183-b455-646a-65bbbe697281@redhat.com> List-Id: References: <20190507183804.5512-1-david@redhat.com> <20190507183804.5512-8-david@redhat.com> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Dan Williams Cc: Linux MM , Linux Kernel Mailing List , linux-ia64@vger.kernel.org, linuxppc-dev , linux-s390 , Linux-sh , Andrew Morton , Greg Kroah-Hartman , "Rafael J. Wysocki" , Alex Deucher , "David S. Miller" , Mark Brown , Chris Wilson , Oscar Salvador , Jonathan Cameron >> drivers/base/node.c | 18 +++++------------- >> include/linux/node.h | 5 ++--- >> 2 files changed, 7 insertions(+), 16 deletions(-) >> >> diff --git a/drivers/base/node.c b/drivers/base/node.c >> index 04fdfa99b8bc..9be88fd05147 100644 >> --- a/drivers/base/node.c >> +++ b/drivers/base/node.c >> @@ -803,20 +803,14 @@ int register_mem_sect_under_node(struct memory_block *mem_blk, void *arg) >> >> /* >> * Unregister memory block device under all nodes that it spans. >> + * Has to be called with mem_sysfs_mutex held (due to unlinked_nodes). > > Given this comment can bitrot relative to the implementation lets > instead add an explicit: > > lockdep_assert_held(&mem_sysfs_mutex); That would require to make the mutex non-static. Is that what you suggest, or any other alternative? Thanks Dan! > > With that you can add: > > Reviewed-by: Dan Williams > -- Thanks, David / dhildenb