From patchwork Fri May 19 00:04:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alison Schofield X-Patchwork-Id: 9544 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp881695vqo; Thu, 18 May 2023 17:07:59 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6tNzv44/iBnAjABDqhfwlif62pU4yqk5hxDJssT/YVfUi6o5BMw8GjltlyV22uKT8dQwuJ X-Received: by 2002:a05:6a00:1594:b0:641:558:8e2e with SMTP id u20-20020a056a00159400b0064105588e2emr905870pfk.15.1684454879073; Thu, 18 May 2023 17:07:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684454879; cv=none; d=google.com; s=arc-20160816; b=Pgz5rERUpuH3KyzqkoG4thjLkjQxT12ZEXndqF+bydN1BCH7l7zYKa+oB7A7l8Xur3 +bzZxZw/FtukTg7IiDnGIM34PKha5U35+wB/Uxf2c+z+/3+dgghHDTpsCuls5rfQ0UWL yczhiJfmV4UiY1X5WexwDoXx1K+rWFcvllQiTfeRzt6ppZ6dbSk//Pfz6Xi1AOif8TiZ otVbrJpldG5pAqI9Yg6F75CPhvJ/9lzz5SMw9DdHwlP5pPL/67XW/jZ+Z3zb4DZfRaLF ZsDprISjjqTdkL/9RzWH2gM3Ve1q1NkGucSVF4AQQvmK9wh5U8T9TTddSbmQtcF5UXQd yoPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=MpleNBCp3eUMzjYPR3lKk/3ZN+5kgXLUNxZ0ieaGcrs=; b=FvZ5AKyTnHl1GFkDrdQw/VS7/liuJ0tUBHKG639y0jCzJxa3FjqY7s1sG5GtPA2IHM Pzswf06jAamN8yGGZ6hl2O1WTXMHmqkuYjkOX1IZ24XzIf9TZ5So+FAifdzrBJBo6B31 aeEri1OHTmzWq0tnC5B020dosXfKmHNqIrW8nGJPOrabjHcs9VL3aKNwVA2IJFmyj8zc Ia1ksH4RZoAUYymTcNefl81ZcxB8XO4BXquwWZkbZnLpq4H9wa1d1dTw+qfQWyVj2BEf yOgQizru7bOKWf/efViNaL5y1AGcnd4pbuUeWWOmCyhE3ZKUnTmYM0RjmfdUPwhWDMoK sEeQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=M3+JKSlV; 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=intel.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r11-20020aa7988b000000b00643a0d26156si2831614pfl.241.2023.05.18.17.07.45; Thu, 18 May 2023 17:07:59 -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=@intel.com header.s=Intel header.b=M3+JKSlV; 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=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230154AbjESAFE (ORCPT + 99 others); Thu, 18 May 2023 20:05:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49808 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229512AbjESAFC (ORCPT ); Thu, 18 May 2023 20:05:02 -0400 Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6BC9F10C3; Thu, 18 May 2023 17:05:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1684454700; x=1715990700; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=NxrdO54ygL7upV2uL2eTTGfGI0A4vPAHukw5zXs+2vU=; b=M3+JKSlV+3QzKkxlljXzxBQZXyIWgsqB28dkaOJ/16CkKQ7zTjB5z1Xj bOOZzWOAC5tdRlKtzRYlXhmcPY5qEwUXmiIHCg/NjHqb0s9cyeK7KJ+YR PjpDK5W/xxO4dlOKSOsTxXf15Llk3whnRfjNrKF7I4DrkxScC35P2GV2q BRJ42Go9Iu4Co2ZHmNCeoSz8X561wu5J3B9uYJwbxPDLlTfgCNiry9OIE CHq110lXp3UgMlIKAcEYvjugpU8oYaXeanZ6ehrR75UX9INn0+/JRXUJr +u7ag8IYfCmddOJ3xLPeTRZyFfRPqJBFJn9y5PQ3fa/woN05ky9kN+aYR w==; X-IronPort-AV: E=McAfee;i="6600,9927,10714"; a="355446205" X-IronPort-AV: E=Sophos;i="6.00,175,1681196400"; d="scan'208";a="355446205" Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 May 2023 17:04:59 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10714"; a="876634912" X-IronPort-AV: E=Sophos;i="6.00,175,1681196400"; d="scan'208";a="876634912" Received: from aschofie-mobl2.amr.corp.intel.com (HELO localhost) ([10.251.20.44]) by orsmga005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 May 2023 17:04:59 -0700 From: alison.schofield@intel.com To: "Rafael J. Wysocki" , Len Brown , Dan Williams , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , "H. Peter Anvin" , Andy Lutomirski , Peter Zijlstra , Andrew Morton , Jonathan Cameron , Dave Jiang Cc: Alison Schofield , x86@kernel.org, linux-cxl@vger.kernel.org, linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 0/2] CXL: Apply SRAT defined PXM to entire CFMWS window Date: Thu, 18 May 2023 17:04:54 -0700 Message-Id: X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_NONE,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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1766278959071570679?= X-GMAIL-MSGID: =?utf-8?q?1766278959071570679?= From: Alison Schofield The CXL subsystem requires the creation of NUMA nodes for CFMWS Windows not described in the SRAT. The existing implementation only addresses windows that the SRAT describes completely or not at all. This work addresses the case of partially described CFMWS Windows by extending proximity domains in a portion of a CFMWS window to the entire window. Introduce a NUMA helper, numa_fill_memblks(), to fill gaps in a numa_meminfo memblk address range. Update the CFMWS parsing in the ACPI driver to use numa_fill_memblks() to extend SRAT defined proximity domains to entire CXL windows. An RFC of this patchset was previously posted for CXL folks review.[1] The RFC feedback led to the implementation here, extending existing memblks (Dan). Also, both Jonathan and Dan influenced the changelog comments in the ACPI patch, with regards to setting expectations on this evolving heuristic. Repeating here to set reviewer expectations: *Note that this heuristic will evolve when CFMWS Windows present a wider range of characteristics. The extension of the proximity domain, implemented here, is likely a step in developing a more sophisticated performance profile in the future. [1] https://lore.kernel.org/linux-cxl/cover.1683742429.git.alison.schofield@intel.com/ Alison Schofield (2): x86/numa: Introduce numa_fill_memblks() ACPI: NUMA: Apply SRAT proximity domain to entire CFMWS window arch/x86/include/asm/sparsemem.h | 2 + arch/x86/mm/numa.c | 82 ++++++++++++++++++++++++++++++++ drivers/acpi/numa/srat.c | 11 +++-- include/linux/numa.h | 7 +++ 4 files changed, 99 insertions(+), 3 deletions(-) base-commit: f81d8f759e7f80c643027e631c586369836aac90