From nobody Fri Sep 12 07:19:28 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 59A73C636D4 for ; Sun, 12 Feb 2023 09:55:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229585AbjBLJzD (ORCPT ); Sun, 12 Feb 2023 04:55:03 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49542 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229449AbjBLJzB (ORCPT ); Sun, 12 Feb 2023 04:55:01 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BFEB51024C; Sun, 12 Feb 2023 01:55:00 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id E47D960B50; Sun, 12 Feb 2023 09:54:59 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 78F95C433EF; Sun, 12 Feb 2023 09:54:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1676195699; bh=VlJr4rZihpfcfqoU6zpWd33xnk4loe0lCeIMnSn8rvo=; h=From:To:Cc:Subject:Date:From; b=dfK5ZC7vMkNsPz+v77KRRdJ8E6ysa55bt2yVD1d5zP6J+QtDRXt47k6f59+HOUZKR fxKr3niqZzYzXQSByxqo6K7jnMJWyMbWVd0woLXmQdUIhXu6r5zmWadN1NOpNAr2P9 //5+wYaMMGHca8Hdsp717dUj/VnKnDd4wWBw1mtMSfVxPHwyQFdbKkPLVJeDextKO1 Cvb0tfqYmcFPuLgAIrgeWkN9wvdXaKRE9mwvTl6hPhqOpOUW8YoVKqETtp6qoaFv5+ uypxIUhJ1SnMK9xmRqtfmZ1S+a1vkQ5SJyc1PwlEycLTM1bwRfKkpYQzz3wbPQ9Jcg rn+N4y2MZ0tNA== From: Mike Rapoport To: Jonathan Corbet Cc: Andrew Morton , Bagas Sanjaya , David Hildenbrand , Johannes Weiner , Lorenzo Stoakes , "Matthew Wilcox (Oracle)" , Mel Gorman , Michal Hocko , Mike Rapoport , Vlastimil Babka , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: [PATCH v2] docs/mm: Physical Memory: add example of interleaving nodes Date: Sun, 12 Feb 2023 11:54:45 +0200 Message-Id: <20230212095445.1311627-1-rppt@kernel.org> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: "Mike Rapoport (IBM)" Add an example of memory layout with interleaving nodes where even memory banks belong to node 0 and odd memory banks belong to node 1 Suggested-by: Michal Hocko Signed-off-by: Mike Rapoport (IBM) --- v2: * Wording update (Bagas) * Add forgotten Suggested-by v1: https://lore.kernel.org/all/20230211102207.1267058-1-rppt@kernel.org Documentation/mm/physical_memory.rst | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/Documentation/mm/physical_memory.rst b/Documentation/mm/physic= al_memory.rst index 3f3c02aa6e6e..d14b785fd938 100644 --- a/Documentation/mm/physical_memory.rst +++ b/Documentation/mm/physical_memory.rst @@ -114,6 +114,25 @@ RAM equally split between two nodes, there will be ``Z= ONE_DMA32``, | DMA32 | NORMAL | MOVABLE | | NORMAL | MOVABLE | +---------+----------+-----------+ +------------+-------------+ =20 + +Note, that memory banks may belong to interleaving nodes. In the example +below an x86 machine has 16Gbytes or RAM in 4 memory banks, even banks +belong to node 0 and odd banks belong to node 1:: + + + 0 4G 8G 12G 16G + +-------------+ +-------------+ +-------------+ +-------------+ + | node 0 | | node 1 | | node 0 | | node 1 | + +-------------+ +-------------+ +-------------+ +-------------+ + + 0 16M 4G + +-----+-------+ +-------------+ +-------------+ +-------------+ + | DMA | DMA32 | | NORMAL | | NORMAL | | NORMAL | + +-----+-------+ +-------------+ +-------------+ +-------------+ + +In such case node 0 will span from 0 to 12 Gbytes and node 1 will span from +4 to 16 Gbytes. + .. _nodes: =20 Nodes base-commit: e076f253283c3e55a128fa9665c0e6cd8146948d --=20 2.35.1