From patchwork Wed Feb 13 09:40:34 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michal Hocko X-Patchwork-Id: 10809455 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id F26C613BF for ; Wed, 13 Feb 2019 09:40:52 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D8F722CAAF for ; Wed, 13 Feb 2019 09:40:52 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D6CEE2CAFE; Wed, 13 Feb 2019 09:40:52 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 632ED2CAAF for ; Wed, 13 Feb 2019 09:40:47 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 3D1468E0002; Wed, 13 Feb 2019 04:40:46 -0500 (EST) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id 358EA8E0001; Wed, 13 Feb 2019 04:40:46 -0500 (EST) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 1FDA38E0002; Wed, 13 Feb 2019 04:40:46 -0500 (EST) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from mail-wm1-f70.google.com (mail-wm1-f70.google.com [209.85.128.70]) by kanga.kvack.org (Postfix) with ESMTP id BB1C58E0001 for ; Wed, 13 Feb 2019 04:40:45 -0500 (EST) Received: by mail-wm1-f70.google.com with SMTP id b186so346709wmc.8 for ; Wed, 13 Feb 2019 01:40:45 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-original-authentication-results:x-gm-message-state:from:to:cc :subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=KPQIvusfQffcbSiTMJqq6ntVvlDynZgSpryXWkwTGaM=; b=YbNHc8vHUEF5MmMVeCHITnjJcX3vGXJ9IrK7l0gKefZ6FOwFEGxXDfXuyDiNgxUuYJ YzW7fcjPfDJIxW7SAAK1N6osDFLzaNvefX+g+q6NxVBt27YWORbIZmfhgj1CV+/y9YDo NSSZQjXtAqHRqPo8X4j5zyGrG3c0JuYi/AFbe8EvLKjUMkDEtJkIT18nLEFd9SE6YhFQ NVIUoUS7qe9fSNqd/t8ykXtI3/l7S1oXB7cgM7Q9fdx845sphngx3rnj62Ipd1n09sRe CXzkTl/3GX/Tx6URL6hKWQWfh7VMJap5oq1nQ/J+PhjveQTOJGvlmMstW1w+AoQ3wBhp 0uXg== X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of mstsxfx@gmail.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=mstsxfx@gmail.com; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org X-Gm-Message-State: AHQUAuaU5upIylwCnx4UC6JrRVKQr9rhKNUN4/XjB4dXQVbV8XczAmbN c7NzQpTK0k4+45VNFcnk3UFZDW70yaFv4x9Ge4IF5t4v6a0hdkLQ7A1W1Ek/SX70BdRaeyR7wl0 GUQXB9bDX+HdDtQsyAUvm8e4d4QPdrYwHGZeeTeqR8nuR2xVzUfEmuJJgjzXBNlkEPZ3UwqN2Ap AXJx2gwBnRD1gXBooYI1GZlAYtfusTBuCMLwXRW5vk3iqJ9tQIwnTrvBWYvX5qw/Hxvpgwm0Ar4 8KGDbjsn/UR+aaGeB95dUmGAMu0joVtunFFX9IFS5SIuiadCAAydmxEunGu/gEiY/g+ewsSyVUI QN8IXv7nmhNBCFaM5rDqAgvFfqm/4m0864fNEjoZDpfWlNaDuQcy/TY4HMyZZK8GxGCXVyXI4g= = X-Received: by 2002:adf:8143:: with SMTP id 61mr6068742wrm.47.1550050845330; Wed, 13 Feb 2019 01:40:45 -0800 (PST) X-Received: by 2002:adf:8143:: with SMTP id 61mr6068691wrm.47.1550050844371; Wed, 13 Feb 2019 01:40:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550050844; cv=none; d=google.com; s=arc-20160816; b=P88oHdDUkG+rnM4bGx/FRiR7+I7Dfz4h4qRDnBP6jk01Jvfu4UWCfjxxaHqBXwv6pi rNXIhCA3diYV2+2lH1nP33PPB8n7w748ahxnpkEZJ6IxGO3g4tN4gi4OjoJj5wR5R1z+ WXeB5DOR3PFK6QPHhWcz0G6z+ZgmhDXDRH65QL+iSPZV1QOIRS7Me3c7CSKYRLvHRAPZ 8cBdwbn0WQl1sW2q/1R8HD3dwHZdfRNnY5WnuQ9iJRrXj4ClyvFiPyQ94znwKVeia/wW tc2a7tsI1mzzlKmCwkfHYGSvSygXLfQBy4Y0gESViSbCVsLschTCO0SInKbiRVF8zf63 kP+Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from; bh=KPQIvusfQffcbSiTMJqq6ntVvlDynZgSpryXWkwTGaM=; b=AJSswUxWfco1wQp8UNayprjji2bLFFGFAIr2SIlf3rLy6q1iouMY0h2EXzqyAOerTV HZTKWn8jvEK1ECOAaAI9KGnrZdLG171UMjnNliuxt+zk2LKuwwGYfEndA/4DVjwc/Ray dyViR39Zw21xyxiaj16X+UtylvfeagOSGtkD8bkbkClKYwxhSdA4mKEM0KSKdQ0fSkER J02Dacb7+C36jC3Wf6Qe+rg6pT1ZA+3E419hq4KJ598ime5o34p55sojtO1pC/uDlfLr PMIrJk/PBZ10rtDULwqRkPMHKtqp7qDYc3xbi2S/h4WaD90tHEOy38WjQEvVW1hDZhMX eK/g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of mstsxfx@gmail.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=mstsxfx@gmail.com; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id o18sor2550558wra.14.2019.02.13.01.40.44 for (Google Transport Security); Wed, 13 Feb 2019 01:40:44 -0800 (PST) Received-SPF: pass (google.com: domain of mstsxfx@gmail.com designates 209.85.220.65 as permitted sender) client-ip=209.85.220.65; Authentication-Results: mx.google.com; spf=pass (google.com: domain of mstsxfx@gmail.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=mstsxfx@gmail.com; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org X-Google-Smtp-Source: AHgI3IZuh4Vbs+i/l3tBIYxc0NPmfUP4uiVUoKfoZUsXIyJmFEXYRFSSKGguAs+YWrr2sqbfmcUeRQ== X-Received: by 2002:adf:de83:: with SMTP id w3mr6080776wrl.56.1550050843722; Wed, 13 Feb 2019 01:40:43 -0800 (PST) Received: from tiehlicka.suse.cz (ip-37-188-151-205.eurotel.cz. [37.188.151.205]) by smtp.gmail.com with ESMTPSA id i13sm20879739wrm.86.2019.02.13.01.40.41 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 13 Feb 2019 01:40:42 -0800 (PST) From: Michal Hocko To: Cc: Pingfan Liu , Dave Hansen , Peter Zijlstra , x86@kernel.org, Benjamin Herrenschmidt , Michael Ellerman , Tony Luck , linuxppc-dev@lists.ozlabs.org, linux-ia64@vger.kernel.org, LKML , Ingo Molnar , Michal Hocko Subject: [PATCH v2 2/2] mm: be more verbose about zonelist initialization Date: Wed, 13 Feb 2019 10:40:34 +0100 Message-Id: <20190213094034.1341-1-mhocko@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190212095343.23315-3-mhocko@kernel.org> References: <20190212095343.23315-3-mhocko@kernel.org> MIME-Version: 1.0 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: X-Virus-Scanned: ClamAV using ClamSMTP From: Michal Hocko We have seen several bugs where zonelists have not been initialized properly and it is not really straightforward to track those bugs down. One way to help a bit at least is to dump zonelists of each node when they are (re)initialized. Signed-off-by: Michal Hocko --- mm/page_alloc.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/mm/page_alloc.c b/mm/page_alloc.c index 2e097f336126..02c843f0db4f 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -5234,6 +5234,7 @@ static void build_zonelists(pg_data_t *pgdat) int node, load, nr_nodes = 0; nodemask_t used_mask; int local_node, prev_node; + struct zone *zone; /* NUMA-aware ordering of nodes */ local_node = pgdat->node_id; @@ -5259,6 +5260,11 @@ static void build_zonelists(pg_data_t *pgdat) build_zonelists_in_node_order(pgdat, node_order, nr_nodes); build_thisnode_zonelists(pgdat); + + pr_info("node[%d] zonelist: ", pgdat->node_id); + for_each_zone_zonelist(zone, z, &pgdat->node_zonelists[ZONELIST_FALLBACK], MAX_NR_ZONES-1) + pr_cont("%d:%s ", zone_to_nid(zone), zone->name); + pr_cont("\n"); } #ifdef CONFIG_HAVE_MEMORYLESS_NODES