[PATCH 3/3] ACPI: NUMA: Remove the useless 'node >= MAX_NUMNODES' check

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



acpi_map_pxm_to_node() will never return numa node greater
than MAX_NUMNODES, so 'node >= MAX_NUMNODES' is not needed,
remove it.

Signed-off-by: Hanjun Guo <guohanjun@xxxxxxxxxx>
---
 drivers/acpi/numa/srat.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/acpi/numa/srat.c b/drivers/acpi/numa/srat.c
index 3d430b0..15bbaab 100644
--- a/drivers/acpi/numa/srat.c
+++ b/drivers/acpi/numa/srat.c
@@ -230,7 +230,7 @@ void __init acpi_numa_slit_init(struct acpi_table_slit *slit)
 		pxm &= 0xff;
 
 	node = acpi_map_pxm_to_node(pxm);
-	if (node == NUMA_NO_NODE || node >= MAX_NUMNODES) {
+	if (node == NUMA_NO_NODE) {
 		pr_err("SRAT: Too many proximity domains.\n");
 		goto out_err_bad_srat;
 	}
-- 
1.7.12.4




[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux