diff mbox series

ACPI: NUMA: Add CXL CFMWS 'nodes' to the possible nodes set

Message ID 166631003537.1167078.9373680312035292395.stgit@dwillia2-xfh.jf.intel.com
State Accepted
Commit 24f0692bfd41fd207d99c993a5785c3426762046
Headers show
Series ACPI: NUMA: Add CXL CFMWS 'nodes' to the possible nodes set | expand

Commit Message

Dan Williams Oct. 20, 2022, 11:54 p.m. UTC
The ACPI CEDT.CFMWS indicates a range of possible address where new CXL
regions can appear. Each range is associated with a QTG id (QoS
Throttling Group id). For each range + QTG pair that is not covered by a proximity
domain in the SRAT, Linux creates a new NUMA node. However, the commit
that added the new ranges missed updating the node_possible mask which
causes memory_group_register() to fail. Add the new nodes to the
nodes_possible mask.

Cc: <stable@vger.kernel.org>
Fixes: fd49f99c1809 ("ACPI: NUMA: Add a node and memblk for each CFMWS not in SRAT")
Cc: Alison Schofield <alison.schofield@intel.com>
Cc: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reported-by: Vishal Verma <vishal.l.verma@intel.com>
Tested-by: Vishal Verma <vishal.l.verma@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
---
Rafael, I can take this through the CXL tree with some other pending
fixes.

 drivers/acpi/numa/srat.c |    1 +
 1 file changed, 1 insertion(+)

Comments

Verma, Vishal L Oct. 21, 2022, 3:18 a.m. UTC | #1
On Thu, 2022-10-20 at 16:54 -0700, Dan Williams wrote:
> The ACPI CEDT.CFMWS indicates a range of possible address where new CXL
> regions can appear. Each range is associated with a QTG id (QoS
> Throttling Group id). For each range + QTG pair that is not covered by a proximity
> domain in the SRAT, Linux creates a new NUMA node. However, the commit
> that added the new ranges missed updating the node_possible mask which
> causes memory_group_register() to fail. Add the new nodes to the
> nodes_possible mask.
> 
> Cc: <stable@vger.kernel.org>
> Fixes: fd49f99c1809 ("ACPI: NUMA: Add a node and memblk for each CFMWS not in SRAT")
> Cc: Alison Schofield <alison.schofield@intel.com>
> Cc: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> Reported-by: Vishal Verma <vishal.l.verma@intel.com>
> Tested-by: Vishal Verma <vishal.l.verma@intel.com>
> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
> ---
> Rafael, I can take this through the CXL tree with some other pending
> fixes.
> 
>  drivers/acpi/numa/srat.c |    1 +
>  1 file changed, 1 insertion(+)

Looks good,

Reviewed-by: Vishal Verma <vishal.l.verma@intel.com>

> 
> diff --git a/drivers/acpi/numa/srat.c b/drivers/acpi/numa/srat.c
> index 3b818ab186be..1f4fc5f8a819 100644
> --- a/drivers/acpi/numa/srat.c
> +++ b/drivers/acpi/numa/srat.c
> @@ -327,6 +327,7 @@ static int __init acpi_parse_cfmws(union acpi_subtable_headers *header,
>                 pr_warn("ACPI NUMA: Failed to add memblk for CFMWS node %d [mem %#llx-%#llx]\n",
>                         node, start, end);
>         }
> +       node_set(node, numa_nodes_parsed);
>  
>         /* Set the next available fake_pxm value */
>         (*fake_pxm)++;
>
Rafael J. Wysocki Oct. 21, 2022, 5:56 p.m. UTC | #2
On Fri, Oct 21, 2022 at 1:55 AM Dan Williams <dan.j.williams@intel.com> wrote:
>
> The ACPI CEDT.CFMWS indicates a range of possible address where new CXL
> regions can appear. Each range is associated with a QTG id (QoS
> Throttling Group id). For each range + QTG pair that is not covered by a proximity
> domain in the SRAT, Linux creates a new NUMA node. However, the commit
> that added the new ranges missed updating the node_possible mask which
> causes memory_group_register() to fail. Add the new nodes to the
> nodes_possible mask.
>
> Cc: <stable@vger.kernel.org>
> Fixes: fd49f99c1809 ("ACPI: NUMA: Add a node and memblk for each CFMWS not in SRAT")
> Cc: Alison Schofield <alison.schofield@intel.com>
> Cc: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> Reported-by: Vishal Verma <vishal.l.verma@intel.com>
> Tested-by: Vishal Verma <vishal.l.verma@intel.com>
> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
> ---
> Rafael, I can take this through the CXL tree with some other pending
> fixes.

Sure.

Acked-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>

>  drivers/acpi/numa/srat.c |    1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/drivers/acpi/numa/srat.c b/drivers/acpi/numa/srat.c
> index 3b818ab186be..1f4fc5f8a819 100644
> --- a/drivers/acpi/numa/srat.c
> +++ b/drivers/acpi/numa/srat.c
> @@ -327,6 +327,7 @@ static int __init acpi_parse_cfmws(union acpi_subtable_headers *header,
>                 pr_warn("ACPI NUMA: Failed to add memblk for CFMWS node %d [mem %#llx-%#llx]\n",
>                         node, start, end);
>         }
> +       node_set(node, numa_nodes_parsed);
>
>         /* Set the next available fake_pxm value */
>         (*fake_pxm)++;
>
diff mbox series

Patch

diff --git a/drivers/acpi/numa/srat.c b/drivers/acpi/numa/srat.c
index 3b818ab186be..1f4fc5f8a819 100644
--- a/drivers/acpi/numa/srat.c
+++ b/drivers/acpi/numa/srat.c
@@ -327,6 +327,7 @@  static int __init acpi_parse_cfmws(union acpi_subtable_headers *header,
 		pr_warn("ACPI NUMA: Failed to add memblk for CFMWS node %d [mem %#llx-%#llx]\n",
 			node, start, end);
 	}
+	node_set(node, numa_nodes_parsed);
 
 	/* Set the next available fake_pxm value */
 	(*fake_pxm)++;