diff mbox

x86/acpi: fix the comments in acpi_parse_lapic

Message ID 1528371302-29270-1-git-send-email-lirongqing@baidu.com (mailing list archive)
State Rejected, archived
Headers show

Commit Message

Li,Rongqing June 7, 2018, 11:35 a.m. UTC
This should be permit to preallocate memory for all NR_CPUS

Signed-off-by: Li RongQing <lirongqing@baidu.com>
---
 arch/x86/kernel/acpi/boot.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Thomas Gleixner June 7, 2018, 12:09 p.m. UTC | #1
On Thu, 7 Jun 2018, Li RongQing wrote:

> This should be permit to preallocate memory for all NR_CPUS

No. The comment is correct. The whole magic is there to size
num_possible_cpus correctly so that we can avoid allocating for NR_CPUS
which is most of the time larger than num_possible_cpus.

Thanks,

	tglx
diff mbox

Patch

diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c
index 3b20607d581b..8ae88605a5eb 100644
--- a/arch/x86/kernel/acpi/boot.c
+++ b/arch/x86/kernel/acpi/boot.c
@@ -223,7 +223,7 @@  acpi_parse_x2apic(struct acpi_subtable_header *header, const unsigned long end)
 	 * We need to register disabled CPU as well to permit
 	 * counting disabled CPUs. This allows us to size
 	 * cpus_possible_map more accurately, to permit
-	 * to not preallocating memory for all NR_CPUS
+	 * to preallocating memory for all NR_CPUS
 	 * when we use CPU hotplug.
 	 */
 	if (!apic->apic_id_valid(apic_id)) {
@@ -260,7 +260,7 @@  acpi_parse_lapic(struct acpi_subtable_header * header, const unsigned long end)
 	 * We need to register disabled CPU as well to permit
 	 * counting disabled CPUs. This allows us to size
 	 * cpus_possible_map more accurately, to permit
-	 * to not preallocating memory for all NR_CPUS
+	 * to preallocating memory for all NR_CPUS
 	 * when we use CPU hotplug.
 	 */
 	acpi_register_lapic(processor->id,	/* APIC ID */