From patchwork Mon Apr 10 02:04:04 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rashmica Gupta X-Patchwork-Id: 748808 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3w1YSG13cDz9s65 for ; Mon, 10 Apr 2017 12:05:50 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="vXTFLplf"; dkim-atps=neutral Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 3w1YSF6ybfzDq88 for ; Mon, 10 Apr 2017 12:05:49 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="vXTFLplf"; dkim-atps=neutral X-Original-To: linuxppc-dev@lists.ozlabs.org Delivered-To: linuxppc-dev@lists.ozlabs.org Received: from mail-pg0-x242.google.com (mail-pg0-x242.google.com [IPv6:2607:f8b0:400e:c05::242]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 3w1YQW6YNXzDq7Z for ; Mon, 10 Apr 2017 12:04:19 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="vXTFLplf"; dkim-atps=neutral Received: by mail-pg0-x242.google.com with SMTP id 79so23819584pgf.0 for ; Sun, 09 Apr 2017 19:04:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=xVZsUmJ4Kj+Y2OBqbT2muIF7EnAOuXk0XEQhQF5Zx3U=; b=vXTFLplf6vMh0pZXhx+QVZngrH0qbISWGpWKhQdaRFc/+sReXmrE8M+uK7n+hXA/Wj hiSo/Fd+/j1xWYNSQOcM0WAcwHBVP6EGeS7WrcXuX5BcbCMlt86OPqM/j9oSCPP9pVPZ Y0+SmrEeSXIWQ4lK0PlGMmG5ytKyQWvQ9tohsR7k35F4VR4hYxPCKjhP/9NrQ3PYw4C9 wIW4Pm0QEhQDLxBA8mBnIPjfgsCfti+XalpfkS3K3tNmtpkgBkgB7WO0karQLeyfMYMA mAdHzeR5RJ2gMKTz/XX/TjVH1ug95JDuGOeNAU7jDX/ilj0MDzPKsUnLPJxUJ7CEpExF v7Lw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=xVZsUmJ4Kj+Y2OBqbT2muIF7EnAOuXk0XEQhQF5Zx3U=; b=VFKuk+NYzBumPr5ragVdBSWuYiMfaegQeW4754sfg6/yi/SMUrcq2nC/CK+xH2tp69 47k+T26K8Cqu0LARz47+JKox0w+9drTxmrOrONVSdZMCyi8PGlzc4Cspierm/En6PF/o yYKynuLmJF0VkZxMquojP6nTqMS4GNa/0nA3nM9goCN51zEPl5KrhUJDlYI9cbLzS43i fhT3S949QFGSVgugA8z7gX0l5rvak0ctzwebM2bsYtlypfy/nP30tkk7dCGdb1i5cX5m 6B8T6F8fUpCflzQHJQbJxLSXewipG38zQ3MM7K4KbX/abz2D+CI7EQ2OGiBWJucyOvPC g5hA== X-Gm-Message-State: AFeK/H2dBAM9vjEG76dQjTC8hck/ondm9bfDML2FCeQaybpsAH1DlpNeiII+rWmbAo1Y1A== X-Received: by 10.84.229.10 with SMTP id b10mr65179552plk.148.1491789858247; Sun, 09 Apr 2017 19:04:18 -0700 (PDT) Received: from rashmica.ozlabs.ibm.com ([122.99.82.10]) by smtp.gmail.com with ESMTPSA id z185sm20944101pfb.6.2017.04.09.19.04.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Apr 2017 19:04:17 -0700 (PDT) From: Rashmica Gupta To: linuxppc-dev@lists.ozlabs.org, mpe@ellerman.id.au Subject: [PATCH] powerpc/mm: Dump hash table Date: Mon, 10 Apr 2017 12:04:04 +1000 Message-Id: <20170410020404.11375-1-rashmica.g@gmail.com> X-Mailer: git-send-email 2.9.3 X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Rashmica Gupta Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" Current behaviour assumes that memory in RAM is contiguous and iterates from the start of RAM to (start + size of memory). When the memory isn't physically contiguous, this approach doesn't work. If memory exists at 0-5 GB and 6-10 GB then the current approach will check if entries exist in the hash table from 0GB to 9GB. This patch changes the behaviour to iterate up to the end of RAM. Signed-off-by: Rashmica Gupta --- arch/powerpc/mm/dump_hashpagetable.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/mm/dump_hashpagetable.c b/arch/powerpc/mm/dump_hashpagetable.c index d979709..ee07398 100644 --- a/arch/powerpc/mm/dump_hashpagetable.c +++ b/arch/powerpc/mm/dump_hashpagetable.c @@ -468,7 +468,7 @@ static void walk_linearmapping(struct pg_state *st) unsigned long psize = 1 << mmu_psize_defs[mmu_linear_psize].shift; for (addr = PAGE_OFFSET; addr < PAGE_OFFSET + - memblock_phys_mem_size(); addr += psize) + memblock_end_of_DRAM(); addr += psize) hpte_find(st, addr, mmu_linear_psize); }