Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp4985316yba; Wed, 10 Apr 2019 08:57:37 -0700 (PDT) X-Google-Smtp-Source: APXvYqxDEvI+Jf9HGpdXVNpWdmk7EZSOGgTP630HhgN3pU0BOjicxBD7ww8Gl8DCF6y6wZq5Z7op X-Received: by 2002:a63:2208:: with SMTP id i8mr41000714pgi.223.1554911857687; Wed, 10 Apr 2019 08:57:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554911857; cv=none; d=google.com; s=arc-20160816; b=xhpwAPjcQu+veImgFFnhJ4Aoc3CBJp7WjNTTL+f2PCXkdTchtiNWpSYbWvBxEXg+fi v4gYD9K4SK3CLJ+aHbOnfubCeWTITqEbmJOxSKxhmKxYShpzUaoABTmDsIP/3JxKFNKn fZuZdj8LnvYoMr1EPxvXtIIXb+C4044nn6vAVuQPPdfbBiPVZU2qpvIAqEq2/aeT1F/x 412ktIbYCec6Vmyzw+E1M9db6cpxsu36Lqnb8EcpcNTs63QKbPT48jdZ1sPK9uqwoybK 6RrpfyEFGvU1kn03Dtu7cpqU0zvB7hhktsZWJDmnmhUE1Qox7HtDSZGyX+bY4V8mCA5q SGLw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=tqhwfCgBlKpPNuy5WsvQDadYlBUphfiVT9ljcpqd7LI=; b=R2zKZshqDalR26CNpdcHsOKb3Fa7cFtB4DTpXiFzRcoGNrS/A0nqQt4Q/6tfHDaJOt ELghi/7XU9FHyfmOPlygN/OaQtaa+7e0rN1yRun7lJsCJizqtIRqVAJWGGkNSHi9C+Q1 Yfs15ZZAN8wTfK+wQAOO/KjzCfUIK3IExMqXRl4dV3/9ZfZbKHrS3dF7ER62xFcd/BbS G4gH1kDciorzqwVK7rC8ahvCXMwSLm+AKad2/B5l1cp6mhHQ/DrWQVc08bhZGXGZrtj9 uyP1c06SWc98KsU5wiFIS9zwG1gImTW0NjtMzgdweq+G7xESSkjTvLnw4d0TC/YDwEX3 8x+g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q9si6669953pgq.393.2019.04.10.08.57.21; Wed, 10 Apr 2019 08:57:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730931AbfDJM2R (ORCPT + 99 others); Wed, 10 Apr 2019 08:28:17 -0400 Received: from charybdis-ext.suse.de ([195.135.221.2]:58172 "EHLO suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728881AbfDJM2Q (ORCPT ); Wed, 10 Apr 2019 08:28:16 -0400 Received: by suse.de (Postfix, from userid 1000) id C754A48D1; Wed, 10 Apr 2019 14:28:14 +0200 (CEST) Date: Wed, 10 Apr 2019 14:28:14 +0200 From: Oscar Salvador To: David Hildenbrand Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Andrew Morton , Michal Hocko , Pavel Tatashin , Wei Yang , Qian Cai , Arun KS , Mathieu Malaterre Subject: Re: [PATCH] mm/memory_hotplug: Drop memory device reference after find_memory_block() Message-ID: <20190410122811.jqlusigqc2a22647@d104.suse.de> References: <20190410101455.17338-1-david@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190410101455.17338-1-david@redhat.com> User-Agent: NeoMutt/20170421 (1.8.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Apr 10, 2019 at 12:14:55PM +0200, David Hildenbrand wrote: > While current node handling is probably terribly broken for memory block > devices that span several nodes (only possible when added during boot, > and something like that should be blocked completely), properly put the > device reference we obtained via find_memory_block() to get the nid. We even have nodes sharing sections, so tricky to "fix". But I agree that the way memblocks are being handled now sucks big time. > > Fixes: d0dc12e86b31 ("mm/memory_hotplug: optimize memory hotplug") > Cc: Andrew Morton > Cc: Oscar Salvador > Cc: Michal Hocko > Cc: David Hildenbrand > Cc: Pavel Tatashin > Cc: Wei Yang > Cc: Qian Cai > Cc: Arun KS > Cc: Mathieu Malaterre > Signed-off-by: David Hildenbrand Well spotted David ;-) Reviewed-by: Oscar Salvador -- Oscar Salvador SUSE L3