Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp587068rwd; Tue, 16 May 2023 05:27:37 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5gLrWSdZalaje/DuFG/xBRqAlFmm+1mkYNIRbxK4RWARH6R6EGY2/dB0JgIwbEsxpjXEty X-Received: by 2002:a05:6a20:3d19:b0:105:23cf:747d with SMTP id y25-20020a056a203d1900b0010523cf747dmr14642065pzi.5.1684240057565; Tue, 16 May 2023 05:27:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684240057; cv=none; d=google.com; s=arc-20160816; b=K1svnmuaWUmGEZHs81Klgt3UEsBhYMNqXpjr1ZuHwhkjl8cmDMVaGUXR0vOLNBJloP keqVcgRk/hNxiU2Gn3M2fq0xaNCRA3exIW6HFfq373MIlkMyjpHC8yh0wHamfBkW8L7z ObYs33TIifA8QCEDfy1pWyFFy6Y4S1GCN3ToRCr9o8UniYvJ9IZvJdMWielWF2SJkLix IONNIDpZL4wSqjHYZJzoVr45t8uXC9QIz3hx+9JLNNhROtEIPc6XRko/8rGAW9NN6pIL geZxUb0fQeVf1nJBX3EDBuYO4g2IqTII5B3Xp/vjp1cpbdmzcjECg85w0Jb3FPGYRAOw G+fg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:in-reply-to:cc:to:subject:message-id :from:content-transfer-encoding:date:dkim-signature:mime-version; bh=jRV1ViOpzqxkVyiCLlSRC9tI06roYlefHztOsLPXL50=; b=r0aJZB9zySzOipnjE6O1Bd4ImIrlIB62ok8E0YIbjoQL19SHVXE7ZUvaPGRlrJbF+m MDh8qJ/WLpl4GxcbC4WWFNJD85dYOhoRDwnd8LWky8qADCSpOZMQP8rqFHDQmwi6NKq9 mGx42njVGl7EUQabJiYqJ4AWrE2s2M+fv08hXAT+3oYLti09liaHOwcwPpOjbCcmiq2W w76MKiZv7HFPFGmv6rIDviLrKjRg4GBnUUYqBDF5X3JwxPBdGwxjAJRzN0u+g5LLb3q2 LpiZWdQiYQsOlMDNM5aTaHDC0LAO3ADMydHGwHwqqvpzdNL0ROQS+NbkyqgNpzn3PWCp EG2g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=lrZ2Q30H; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g66-20020a636b45000000b0052c9e5561ebsi17780361pgc.821.2023.05.16.05.27.22; Tue, 16 May 2023 05:27:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=lrZ2Q30H; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232458AbjEPL7Q (ORCPT + 99 others); Tue, 16 May 2023 07:59:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54974 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231853AbjEPL7P (ORCPT ); Tue, 16 May 2023 07:59:15 -0400 Received: from out-60.mta1.migadu.com (out-60.mta1.migadu.com [95.215.58.60]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 201B846B6 for ; Tue, 16 May 2023 04:59:09 -0700 (PDT) MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1684238348; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=jRV1ViOpzqxkVyiCLlSRC9tI06roYlefHztOsLPXL50=; b=lrZ2Q30He1XnN3c3wOP5ouKIUfW81tFWwLMuvdvD0IfjzmhTbdLuErQQTe4LTJFkAVXzs9 MdLIS4U7V6e42RUbv+xh3LG7gUzRHdtJnBIW8PRpVAeifr53mB9dF20IpxXWlFFAchRV8m RAPtu89RPBkfSveMRcf05KB3osI0v/Q= Date: Tue, 16 May 2023 11:59:07 +0000 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: "Yajun Deng" Message-ID: <3509bcc597e37616cf45247e8f92d369@linux.dev> Subject: Re: [PATCH] EDAC: Expose node link in sysfs if CONFIG_NUMA To: "Borislav Petkov" Cc: tony.luck@intel.com, james.morse@arm.com, mchehab@kernel.org, rric@kernel.org, corbet@lwn.net, linux-kernel@vger.kernel.org, linux-edac@vger.kernel.org, linux-doc@vger.kernel.org In-Reply-To: <20230516111942.GCZGNmzu3Abd4KmZu3@fat_crate.local> References: <20230516111942.GCZGNmzu3Abd4KmZu3@fat_crate.local> <20230516103403.GBZGNcG7Q1sdtUpcHW@fat_crate.local> <20230516080748.3155788-1-yajun.deng@linux.dev> X-Migadu-Flow: FLOW_OUT X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org May 16, 2023 7:19 PM, "Borislav Petkov" wrote:=0A=0A> On T= ue, May 16, 2023 at 11:07:11AM +0000, Yajun Deng wrote:=0A> =0A>> It will= help users to confirm which MC belongs to which node if there=0A>> are m= ultiple MCs. Therefore, we can also know how many dimm on each=0A>> node.= =0A> =0A> There are physical nodes, logical nodes, NUMA nodes, interleavi= ng=0A> between nodes...=0A> =0A=0ANode is the NUMA node, We get the numa = id by calling dev_to_node().=0A=0A> Is there any practical use case and n= eed behind this?=0A>=0A=0ASome dimm may not be recognized when boot, we w= ant to find it.=0A=0AThe '/sys/devices/system/node/node0/meminfo' would s= how the memory on=0Anode0.=0A=0AIf we have '/sys/devices/system/node/node= 0/mc0', by comparing the number=0Aof dimm and MemTotal in meminfo. It is = easy to know that the dimm didn't =0Arecognized whether it belonged to th= is NUMA node or not.=0A=0A =0A> --=0A> Regards/Gruss,=0A> Boris.=0A> =0A>= https://people.kernel.org/tglx/notes-about-netiquette