From patchwork Tue Mar 11 23:30:43 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gavin Shan X-Patchwork-Id: 14012746 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id F36F6C282EC for ; Tue, 11 Mar 2025 23:31:18 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id DE54C280003; Tue, 11 Mar 2025 19:31:17 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id D953B280001; Tue, 11 Mar 2025 19:31:17 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id C5E6A280003; Tue, 11 Mar 2025 19:31:17 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id A63C6280001 for ; Tue, 11 Mar 2025 19:31:17 -0400 (EDT) Received: from smtpin20.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id D6CF41604F1 for ; Tue, 11 Mar 2025 23:31:17 +0000 (UTC) X-FDA: 83210868594.20.CE4085B Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by imf12.hostedemail.com (Postfix) with ESMTP id 14E254000B for ; Tue, 11 Mar 2025 23:31:15 +0000 (UTC) Authentication-Results: imf12.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=Hz5+5vZz; spf=pass (imf12.hostedemail.com: domain of gshan@redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=gshan@redhat.com; dmarc=pass (policy=none) header.from=redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1741735876; h=from:from:sender: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:dkim-signature; bh=JFRXYsV6OcgqgN+/5AlzPbliPGGUfcZP8+g1uf56q6A=; b=FuL948zJdsPiVddkPpgRFVSgD6mjKL3k4bynxFLPfYm8pL5jd7TFhd2jt69T4LUdYx5ZZj SKJMiRH5AH/28Z5JugswXLCmy0Cfja5DTXDkt3k+0r8CMCtpdGK0J5lT3c1covhgCY7UdR eIdFKJn3rbMEwQ7vvfXSm0b4LF8pbAk= ARC-Authentication-Results: i=1; imf12.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=Hz5+5vZz; spf=pass (imf12.hostedemail.com: domain of gshan@redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=gshan@redhat.com; dmarc=pass (policy=none) header.from=redhat.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1741735876; a=rsa-sha256; cv=none; b=2yCBNXa/3+W2oW9njtZPAheQFe+4W/avcgmvSEiDlsGUtmATnMJ5gfq5lQUfKR0vOusibL pQ5qVkFLG/t2QJbPA66HJRznvxQRsRe9ok/PiIsN7exuQURgQ0A+MGtuo4N4FCfgiJ+8jI A62/EI+qnzylqJpxouemR5STa56GY6s= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1741735874; 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=JFRXYsV6OcgqgN+/5AlzPbliPGGUfcZP8+g1uf56q6A=; b=Hz5+5vZzrV4wG5STWd5XQsT3Bj5lxPkrDGveY8Em2xEbgEkTpMXPaJG2WjYiSaTHFAv2sz vXf/oy3P/ln7YViCZ9td+5vSBMBZLjDfY5/m40UKlr+i1xhFIY9E+fHaNjQJMj8jSciWZg 2H7Ge4/6O6ndt4Q7BVYj0OC6zHt+R5c= Received: from mx-prod-mc-05.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-210-2i3KdKclNQ2phTZIy6UYCQ-1; Tue, 11 Mar 2025 19:31:11 -0400 X-MC-Unique: 2i3KdKclNQ2phTZIy6UYCQ-1 X-Mimecast-MFC-AGG-ID: 2i3KdKclNQ2phTZIy6UYCQ_1741735869 Received: from mx-prod-int-06.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-06.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.93]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-05.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id EC52A195608A; Tue, 11 Mar 2025 23:31:08 +0000 (UTC) Received: from gshan-thinkpadx1nanogen2.remote.csb (unknown [10.64.136.79]) by mx-prod-int-06.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 76BAF1828A98; Tue, 11 Mar 2025 23:31:03 +0000 (UTC) From: Gavin Shan To: linux-mm@kvack.org Cc: linux-kernel@vger.kernel.org, david@redhat.com, osalvador@suse.de, gregkh@linuxfoundation.org, rafael@kernel.org, dakr@kernel.org, akpm@linux-foundation.org, shan.gavin@gmail.com Subject: [PATCH v3 1/2] drivers/base/memory: Improve add_boot_memory_block() Date: Wed, 12 Mar 2025 09:30:43 +1000 Message-ID: <20250311233045.148943-2-gshan@redhat.com> In-Reply-To: <20250311233045.148943-1-gshan@redhat.com> References: <20250311233045.148943-1-gshan@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.30.177.93 X-Rspam-User: X-Rspamd-Server: rspam10 X-Rspamd-Queue-Id: 14E254000B X-Stat-Signature: bywakk5xoxsma336gd6skn187kq9z88g X-HE-Tag: 1741735875-483498 X-HE-Meta: U2FsdGVkX184+vuO8RSwbl2EeiBGv8CSELvyDen+FRKedKpwYzc/E5o8suP3WFbvD1qEAMHGUMj6nhqibViHn5Pqtpg+WtsGDhsWfrGjwSkNg5QLI1sgyR9IKJvzddPCiXI7gh2IwP7fsgQUt4mZKiTo8jak1TVj+b0GO7a47bppVVesYowOPlOiAx+Ap/4LIiwBwiiA5xJLf3cdJp+YPDhTKaVRoUebBxpA9yGIlljYxA7R8DAPJLXjv1lfTR6AYRIHmJUfQnAjk1lNYCylM3lWitHYp9RClNylUWCQ5HyiP5hltwO3wb0vsuAl4REGYeLTLHyqVCEqmTnH9HJsVrHyYsWw5CdKv+4nsqoHBv6MfcDKCRUaSrPKBDbpUiAVOMIrA3i7SIVy9PQw6Pln5rnsY4koBDNoUhGpHTD50DF5hPPeAAjjORm7exayQ6go9/sxYZJwjPDCpkPv1rTGO8KFBUSIwE3r1S65Y3eFi7kb+k+MLMAKIsMuYtnuaMlMWU2A5OF9lgFWqUjFaLpLNJw3SFJ97qRElaqLDpAhRM+zcVdx3BJlzAvSb/F4OlIbsinXO1PHwNLxrVXKYaiWRMfdNIEfwOmtTtpF3H6OsDNwCtysHvPapQTDQkyUmkjWin+y2psM13uJ7vfUNWsRxuR+R1DnbKe0q3wUIiSI/xXJjBGl/1cUzolUzsJFxnE70By4uFXrkWy7FuboNkFrmd2R87E0h6e+p1LGCRr7kdvLWoT1BIIYZgVaQubZGy1+o1mbzN6Ui7xLTGCy/+qsAGgjOjuWWvlRncGyaTdqHoqB8XXadOfQyUCozl5GBmqp6ftNaopisJMPZ5KDJdSuOJghKnHwk+PLXfMRAwiBphMgsGXaYwi+JbY4uNejo9q1kDLHeOG/js4xAvagVdKUNzhVZMTpQc4rXoDI2hmqplPG+11fuJTH0OfOr3PyTlhoGd9uOLRb6t0/G0JEWmw xt6Ez+w5 /KlJZb3Co8Ic+8mClIf/3uSMd+5X8DO/dBvt7pMr4w9H7dInvnfNKlOmbLkKZLfWq3WtSxf+HSXyUse0C12Jy55OK+v38KdNk677PKWdyiCZBld8vI7pU0nNHHegPhSvE+itDjBZteFEzSA9E6LIkzrIzHh7vcMcp0mpy6f1vGInrFhxJlttN510hb1Bv6injVNe7JB+I5Q2iJCa87zZVTpb3hDSLYOUynDgJo3kBbapSqi7aWZI95fyQ65dHsiSuAsfOAV3y6dTpHt0Em0rRAiqkdfNFwX4vbckC9Mbmdq23Mk8rG5e+stg2aASGJbknCFDjNOp7eN2tYtHZPrNnFBK5bQnRy9rYaPSP5acpinFgRlVHEV7M6cGEs4rxv/EKZU1TehY24uVtWx94m7f1SHBHRJyWe7WvuhVZVVp/7lQqUaCgMwPVhBGe6PRdB2ABP1bs6TkN9CERZNZTQTK2peuLgsONCCZ1OsIR+X4uzexpMT3oNg8RDkh4JU9Y1axEjFyOxGKEPdjcslk= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: It's unnecessary to count the present sections for the specified block since the block will be added if any section in the block is present. Besides, for_each_present_section_nr() can be reused as Andrew Morton suggested. Improve by using for_each_present_section_nr() and dropping the unnecessary @section_count. No functional changes intended. Signed-off-by: Gavin Shan Acked-by: David Hildenbrand Acked-by: Oscar Salvador --- drivers/base/memory.c | 17 ++++++++--------- include/linux/mmzone.h | 5 +++++ mm/sparse.c | 5 ----- 3 files changed, 13 insertions(+), 14 deletions(-) diff --git a/drivers/base/memory.c b/drivers/base/memory.c index 348c5dbbfa68..f66e9d537c12 100644 --- a/drivers/base/memory.c +++ b/drivers/base/memory.c @@ -822,18 +822,17 @@ static int add_memory_block(unsigned long block_id, unsigned long state, static int __init add_boot_memory_block(unsigned long base_section_nr) { - int section_count = 0; unsigned long nr; - for (nr = base_section_nr; nr < base_section_nr + sections_per_block; - nr++) - if (present_section_nr(nr)) - section_count++; + for_each_present_section_nr(base_section_nr, nr) { + if (nr >= (base_section_nr + sections_per_block)) + break; - if (section_count == 0) - return 0; - return add_memory_block(memory_block_id(base_section_nr), - MEM_ONLINE, NULL, NULL); + return add_memory_block(memory_block_id(base_section_nr), + MEM_ONLINE, NULL, NULL); + } + + return 0; } static int add_hotplug_memory_block(unsigned long block_id, diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index 9540b41894da..0f6646da34d7 100644 --- a/include/linux/mmzone.h +++ b/include/linux/mmzone.h @@ -2097,6 +2097,11 @@ static inline unsigned long next_present_section_nr(unsigned long section_nr) return -1; } +#define for_each_present_section_nr(start, section_nr) \ + for (section_nr = next_present_section_nr(start - 1); \ + section_nr != -1; \ + section_nr = next_present_section_nr(section_nr)) + /* * These are _only_ used during initialisation, therefore they * can use __initdata ... They could have names to indicate diff --git a/mm/sparse.c b/mm/sparse.c index 133b033d0cba..fe77d523ab8d 100644 --- a/mm/sparse.c +++ b/mm/sparse.c @@ -170,11 +170,6 @@ static void __section_mark_present(struct mem_section *ms, ms->section_mem_map |= SECTION_MARKED_PRESENT; } -#define for_each_present_section_nr(start, section_nr) \ - for (section_nr = next_present_section_nr(start-1); \ - section_nr != -1; \ - section_nr = next_present_section_nr(section_nr)) - static inline unsigned long first_present_section_nr(void) { return next_present_section_nr(-1); From patchwork Tue Mar 11 23:30:44 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gavin Shan X-Patchwork-Id: 14012747 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id AEB72C282EC for ; Tue, 11 Mar 2025 23:33:01 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 1C68C280004; Tue, 11 Mar 2025 19:33:00 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 176A9280001; Tue, 11 Mar 2025 19:33:00 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 0161D280004; Tue, 11 Mar 2025 19:32:59 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id D7DB5280001 for ; Tue, 11 Mar 2025 19:32:59 -0400 (EDT) Received: from smtpin11.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id 3225B160779 for ; Tue, 11 Mar 2025 23:33:00 +0000 (UTC) X-FDA: 83210872920.11.30C52C3 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by imf24.hostedemail.com (Postfix) with ESMTP id 31D57180008 for ; Tue, 11 Mar 2025 23:32:58 +0000 (UTC) Authentication-Results: imf24.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=ZfSCryLG; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf24.hostedemail.com: domain of gshan@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=gshan@redhat.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1741735978; a=rsa-sha256; cv=none; b=2SiuMw71LrCea2EUfZy0GWJH8HQ6ZxeQ6ipGHIdGCgScXCiTKQ9ob0cQ2IWBUqxClUwd+T SofQe1LvVPCRL53ADTVUjLZsf2rizFYwpmGTvApTLegFcKzSnM81JY3jAhEK60dF6wCOWu +PVl3r8FiX1zlDaOqfSnLHu1Q+A0JCE= ARC-Authentication-Results: i=1; imf24.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=ZfSCryLG; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf24.hostedemail.com: domain of gshan@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=gshan@redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1741735978; h=from:from:sender: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:dkim-signature; bh=8INPd9WvtcPC9yCOdy3J5xeTgC7shZeUYjpA84y5sNU=; b=HjovjpMshIPcPUBbdHM3Ml+SHMmLkorKpl55Mka9RDfURkETcVeNjL5aP2zvmPn/4e16mD 9Br56dDZnSX1ZB6cHPpxSY/fpCvvtL2KMF1lmJAQaX4K5oJxQ0GnRZhvz8YpTrrJBBJc+D r3UrkYwD516Ddcp5CSHlz2EPnANf4I0= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1741735977; 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=8INPd9WvtcPC9yCOdy3J5xeTgC7shZeUYjpA84y5sNU=; b=ZfSCryLGhYL99DjTBIt9O+ULNWSAUzpO2goja/Z2TAbwzBzbLsgWVWqQXnsFq2vzQ0dztD 8F+xMmj7HOQkskz+fzjnT4gjPgvf155mXTARrZaV9ir2CGxkb1Q0uxvayJiMa/TjKXtAeW c6eWtdX+fOLmXAKtXUPSQkGNaM8Tr/M= Received: from mx-prod-mc-01.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-661-ABJnKkzSOTuhZSaNGXI1aA-1; Tue, 11 Mar 2025 19:31:16 -0400 X-MC-Unique: ABJnKkzSOTuhZSaNGXI1aA-1 X-Mimecast-MFC-AGG-ID: ABJnKkzSOTuhZSaNGXI1aA_1741735875 Received: from mx-prod-int-06.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-06.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.93]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-01.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 3983419560B0; Tue, 11 Mar 2025 23:31:15 +0000 (UTC) Received: from gshan-thinkpadx1nanogen2.remote.csb (unknown [10.64.136.79]) by mx-prod-int-06.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id F41F61828A93; Tue, 11 Mar 2025 23:31:09 +0000 (UTC) From: Gavin Shan To: linux-mm@kvack.org Cc: linux-kernel@vger.kernel.org, david@redhat.com, osalvador@suse.de, gregkh@linuxfoundation.org, rafael@kernel.org, dakr@kernel.org, akpm@linux-foundation.org, shan.gavin@gmail.com Subject: [PATCH v3 2/2] drivers/base/memory: Correct the field name in the header Date: Wed, 12 Mar 2025 09:30:44 +1000 Message-ID: <20250311233045.148943-3-gshan@redhat.com> In-Reply-To: <20250311233045.148943-1-gshan@redhat.com> References: <20250311233045.148943-1-gshan@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.30.177.93 X-Rspam-User: X-Rspamd-Queue-Id: 31D57180008 X-Stat-Signature: xtwfiossjxs8rsb3fs13rh1kd6h746wt X-Rspamd-Server: rspam06 X-HE-Tag: 1741735978-638420 X-HE-Meta: U2FsdGVkX18aBnF5P+ILaR7xI33fPlPBIce+bafrnZ/hIQj2NxVx4p+0EohTdPDsUh9m9YcZYUEI32CqY/KeyLiC/GGpLSAyb9QGbiRajeGK+JiO9nG8Bg4tTh354joQ8lzKZdJ48rT4v/2by2EN7+Fr7yOVU2HyOmrLNwChxE8Ivl7KctmOcOUeVhY5/sy7pwSTaSyJawXcYSWlagEOsHdn7tGux1SDCW5ybJJJNv5QQtwTp/ZxSGDCjBW+NF+bfTRfwTmuEE5rImZhVCvGQ88EcfuCtJ+7tMKL6ZT4ejogcF6XNmVC81D8sg/+no8GsB7ZMhlw8OjY2Mnd/pQ8qzDB729zShSf0s8yn2tJniesrpvuYlNO/+GGiL1/vBBlYfWNJTPrV6O4+xvDQ5OletdI+CzbKcJdGvuWUdFnydPp2jrOTOoKCq3jbLbVsw9Yt1LHC/MZ1ZWOikCjKyIZ6sI5UXuUy/SBHFXeKrdvaQ08UDFHAPE6GsCezZtJihU8/UmwYb16KfoYmdHopAfjuiLlTgG9Ch4ItaMiPBtf5OP2XLFkZUwWzlvTXWcV5LKGB9gsgK8B3kIiyP9fH+VvyGZKqnx8QkIyX7CF0sLvJt9IoHkC6+eLMMaY+MS9FhxRBXMjD9elgtTly39yRC+iCwYbeI+ND6oiW4a0alrTbnKtfwRpdpSIs7PutT8TLXVIkay20SF+gourunqtI4dgydCFW0qzP9mOdPDC0BGxAAEXBBOS1StybWq1G/ndSbVzODZNh3gZeQMtlXqJyOWVmjXuN4q5WeroP0lpJlifrt0syH1vzqPWovmgpwXmyb4SYnf+/4XezyGyGaH6OxZw6D1toaLyikKVEEtVMUVUdVPtnFL7mKI3raWyk4o26Mry/ds/MTYwnSJ3v8gknqoc7FWKBUDPsYHq5tPCMUtHF8H4M6ZxKT464ojVZ2fMV/MUMJQeR4D5rM3ZITl1QCq wTUcg8ls xQcJpuV7JiuOAyRvUT4aLANiLLnKN8ZDfjyafy+BBtOAD8eawp1jNl9GIMbAUNaFetfsM6bo7+wDklLlLSSWPzP87Vf6AxwRLMjXCmR3BA7hrd+fFDBcm4BdAQ2An093moOPUeLiTSWOzVXmuS/+jMxURaT2USzFxaCwt3yGtIs+Zao85AJlDOLZYQH57XYyEUrZ9xTgnnGUlpxIxPQ38qX7L1NE//63y6NFViDmWwbN4N6QjMCA67COjZiddUzr+EbcgCOpioSXA4tr6yUI7a4qeiBePod2iH5cTU14oNrCjlQSSa0LN5GgOyNCUIT18zJiPOB78RNCHRZC81PHPaW24VmLATvx3dGWGX22xOnOvbc/lCOOTP2bzSIGYa4B7ZbdVVC3fMOwf8b+HcKphjaucvg== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Replace @blocks with @memory_blocks to match with the definition of struct memory_group. Signed-off-by: Gavin Shan Acked-by: David Hildenbrand Acked-by: Oscar Salvador --- include/linux/memory.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/memory.h b/include/linux/memory.h index c0afee5d126e..12daa6ec7d09 100644 --- a/include/linux/memory.h +++ b/include/linux/memory.h @@ -25,7 +25,7 @@ /** * struct memory_group - a logical group of memory blocks * @nid: The node id for all memory blocks inside the memory group. - * @blocks: List of all memory blocks belonging to this memory group. + * @memory_blocks: List of all memory blocks belonging to this memory group. * @present_kernel_pages: Present (online) memory outside ZONE_MOVABLE of this * memory group. * @present_movable_pages: Present (online) memory in ZONE_MOVABLE of this