diff mbox series

[5/7] mm/mm_init.c: remove the outdated code comment above deferred_grow_zone()

Message ID 20240326061134.1055295-6-bhe@redhat.com (mailing list archive)
State New
Headers show
Series mm/init: minor clean up and improvement | expand

Commit Message

Baoquan He March 26, 2024, 6:11 a.m. UTC
The noinline attribute has been taken off in commit 9420f89db2dd ("mm:
move most of core MM initialization to mm/mm_init.c"). So remove the
unneeded code comment above deferred_grow_zone().

And also remove the unneeded bracket in deferred_init_pages().

Signed-off-by: Baoquan He <bhe@redhat.com>
---
 mm/mm_init.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

Comments

Mike Rapoport April 2, 2024, 8:30 a.m. UTC | #1
On Tue, Mar 26, 2024 at 02:11:31PM +0800, Baoquan He wrote:
> The noinline attribute has been taken off in commit 9420f89db2dd ("mm:
> move most of core MM initialization to mm/mm_init.c"). So remove the
> unneeded code comment above deferred_grow_zone().
> 
> And also remove the unneeded bracket in deferred_init_pages().
> 
> Signed-off-by: Baoquan He <bhe@redhat.com>

Reviewed-by: Mike Rapoport (IBM) <rppt@kernel.org>

> ---
>  mm/mm_init.c | 6 +-----
>  1 file changed, 1 insertion(+), 5 deletions(-)
> 
> diff --git a/mm/mm_init.c b/mm/mm_init.c
> index cbdb49cdd2ce..cc24e7958c0c 100644
> --- a/mm/mm_init.c
> +++ b/mm/mm_init.c
> @@ -2006,7 +2006,7 @@ static unsigned long  __init deferred_init_pages(struct zone *zone,
>  		__init_single_page(page, pfn, zid, nid);
>  		nr_pages++;
>  	}
> -	return (nr_pages);
> +	return nr_pages;
>  }
>  
>  /*
> @@ -2208,10 +2208,6 @@ static int __init deferred_init_memmap(void *data)
>   * Return true when zone was grown, otherwise return false. We return true even
>   * when we grow less than requested, to let the caller decide if there are
>   * enough pages to satisfy the allocation.
> - *
> - * Note: We use noinline because this function is needed only during boot, and
> - * it is called from a __ref function _deferred_grow_zone. This way we are
> - * making sure that it is not inlined into permanent text section.
>   */
>  bool __init deferred_grow_zone(struct zone *zone, unsigned int order)
>  {
> -- 
> 2.41.0
>
diff mbox series

Patch

diff --git a/mm/mm_init.c b/mm/mm_init.c
index cbdb49cdd2ce..cc24e7958c0c 100644
--- a/mm/mm_init.c
+++ b/mm/mm_init.c
@@ -2006,7 +2006,7 @@  static unsigned long  __init deferred_init_pages(struct zone *zone,
 		__init_single_page(page, pfn, zid, nid);
 		nr_pages++;
 	}
-	return (nr_pages);
+	return nr_pages;
 }
 
 /*
@@ -2208,10 +2208,6 @@  static int __init deferred_init_memmap(void *data)
  * Return true when zone was grown, otherwise return false. We return true even
  * when we grow less than requested, to let the caller decide if there are
  * enough pages to satisfy the allocation.
- *
- * Note: We use noinline because this function is needed only during boot, and
- * it is called from a __ref function _deferred_grow_zone. This way we are
- * making sure that it is not inlined into permanent text section.
  */
 bool __init deferred_grow_zone(struct zone *zone, unsigned int order)
 {