lkml.org 
[lkml]   [2019]   [Mar]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] sh: mm: make use of new memblocks_present() helper
On Tue, Mar 19, 2019 at 12:09:30PM -0600, Logan Gunthorpe wrote:
> Cleanup the open coded for_each_memblock() loop that is equivalent
> to the new memblocks_present() helper.
>
> Signed-off-by: Logan Gunthorpe <logang@deltatee.com>
> Reviewed-by: Christoph Hellwig <hch@lst.de>
> Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
> Cc: Rich Felker <dalias@libc.org>

Reviewed-by: Mike Rapoport <rppt@linux.ibm.com>

> ---
> arch/sh/mm/init.c | 7 +------
> 1 file changed, 1 insertion(+), 6 deletions(-)
>
> This is just a resend
>
> diff --git a/arch/sh/mm/init.c b/arch/sh/mm/init.c
> index a8e5c0e00fca..dc0ff41d602d 100644
> --- a/arch/sh/mm/init.c
> +++ b/arch/sh/mm/init.c
> @@ -234,12 +234,7 @@ static void __init do_init_bootmem(void)
>
> plat_mem_setup();
>
> - for_each_memblock(memory, reg) {
> - int nid = memblock_get_region_node(reg);
> -
> - memory_present(nid, memblock_region_memory_base_pfn(reg),
> - memblock_region_memory_end_pfn(reg));
> - }
> + memblocks_present();
> sparse_init();
> }
>
> --
> 2.19.0
>

--
Sincerely yours,
Mike.

\
 
 \ /
  Last update: 2019-03-19 21:39    [W:0.029 / U:1.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site