* [PATCH -next] arm64/mm/dump: fix a compilation error
@ 2020-01-10 14:51 Qian Cai
2020-01-10 15:34 ` Steven Price
0 siblings, 1 reply; 3+ messages in thread
From: Qian Cai @ 2020-01-10 14:51 UTC (permalink / raw)
To: akpm
Cc: steven.price, catalin.marinas, will, linux-arm-kernel, linux-mm,
linux-kernel, sfr, Qian Cai
The linux-next commit "x86: mm: avoid allocating struct mm_struct on the
stack" [1] introduced a compilation error with "arm64: mm: convert
mm/dump.c to use walk_page_range()" [2]. Fixed it by using the new API.
arch/arm64/mm/dump.c:326:38: error: too few arguments to function call,
expected 3, have 2
ptdump_walk_pgd(&st.ptdump, info->mm);
~~~~~~~~~~~~~~~ ^
./include/linux/ptdump.h:20:1: note: 'ptdump_walk_pgd' declared here
void ptdump_walk_pgd(struct ptdump_state *st, struct mm_struct *mm,
pgd_t *pgd);
^
arch/arm64/mm/dump.c:364:38: error: too few arguments to function call,
expected 3, have 2
ptdump_walk_pgd(&st.ptdump, &init_mm);
~~~~~~~~~~~~~~~ ^
./include/linux/ptdump.h:20:1: note: 'ptdump_walk_pgd' declared here
void ptdump_walk_pgd(struct ptdump_state *st, struct mm_struct *mm,
pgd_t *pgd);
^
2 errors generated.
[1] http://lkml.kernel.org/r/20200108145710.34314-1-steven.price@arm.com
[2] http://lkml.kernel.org/r/20191218162402.45610-22-steven.price@arm.com
Signed-off-by: Qian Cai <cai@lca.pw>
---
arch/arm64/mm/dump.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/arm64/mm/dump.c b/arch/arm64/mm/dump.c
index ef4b3ca1e058..860c00ec8bd3 100644
--- a/arch/arm64/mm/dump.c
+++ b/arch/arm64/mm/dump.c
@@ -323,7 +323,7 @@ void ptdump_walk(struct seq_file *s, struct ptdump_info *info)
}
};
- ptdump_walk_pgd(&st.ptdump, info->mm);
+ ptdump_walk_pgd(&st.ptdump, info->mm, NULL);
}
static void ptdump_initialize(void)
@@ -361,7 +361,7 @@ void ptdump_check_wx(void)
}
};
- ptdump_walk_pgd(&st.ptdump, &init_mm);
+ ptdump_walk_pgd(&st.ptdump, &init_mm, NULL);
if (st.wx_pages || st.uxn_pages)
pr_warn("Checked W+X mappings: FAILED, %lu W+X pages found, %lu non-UXN pages found\n",
--
2.21.0 (Apple Git-122.2)
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH -next] arm64/mm/dump: fix a compilation error
2020-01-10 14:51 [PATCH -next] arm64/mm/dump: fix a compilation error Qian Cai
@ 2020-01-10 15:34 ` Steven Price
2020-01-10 16:07 ` Will Deacon
0 siblings, 1 reply; 3+ messages in thread
From: Steven Price @ 2020-01-10 15:34 UTC (permalink / raw)
To: Qian Cai
Cc: akpm, Catalin Marinas, will, linux-arm-kernel, linux-mm,
linux-kernel, sfr
On Fri, Jan 10, 2020 at 02:51:12PM +0000, Qian Cai wrote:
> The linux-next commit "x86: mm: avoid allocating struct mm_struct on the
> stack" [1] introduced a compilation error with "arm64: mm: convert
> mm/dump.c to use walk_page_range()" [2]. Fixed it by using the new API.
>
> arch/arm64/mm/dump.c:326:38: error: too few arguments to function call,
> expected 3, have 2
> ptdump_walk_pgd(&st.ptdump, info->mm);
> ~~~~~~~~~~~~~~~ ^
> ./include/linux/ptdump.h:20:1: note: 'ptdump_walk_pgd' declared here
> void ptdump_walk_pgd(struct ptdump_state *st, struct mm_struct *mm,
> pgd_t *pgd);
> ^
> arch/arm64/mm/dump.c:364:38: error: too few arguments to function call,
> expected 3, have 2
> ptdump_walk_pgd(&st.ptdump, &init_mm);
> ~~~~~~~~~~~~~~~ ^
> ./include/linux/ptdump.h:20:1: note: 'ptdump_walk_pgd' declared here
> void ptdump_walk_pgd(struct ptdump_state *st, struct mm_struct *mm,
> pgd_t *pgd);
> ^
> 2 errors generated.
>
> [1] http://lkml.kernel.org/r/20200108145710.34314-1-steven.price@arm.com
Actually this was in the patch I originally posted - somehow it got
lost when Andrew picked it up.
> [2] http://lkml.kernel.org/r/20191218162402.45610-22-steven.price@arm.com
>
> Signed-off-by: Qian Cai <cai@lca.pw>
Since this matches what I originally wrote... ;)
Reviewed-by: Steven Price <steven.price@arm.com>
Steve
> ---
> arch/arm64/mm/dump.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/arch/arm64/mm/dump.c b/arch/arm64/mm/dump.c
> index ef4b3ca1e058..860c00ec8bd3 100644
> --- a/arch/arm64/mm/dump.c
> +++ b/arch/arm64/mm/dump.c
> @@ -323,7 +323,7 @@ void ptdump_walk(struct seq_file *s, struct ptdump_info *info)
> }
> };
>
> - ptdump_walk_pgd(&st.ptdump, info->mm);
> + ptdump_walk_pgd(&st.ptdump, info->mm, NULL);
> }
>
> static void ptdump_initialize(void)
> @@ -361,7 +361,7 @@ void ptdump_check_wx(void)
> }
> };
>
> - ptdump_walk_pgd(&st.ptdump, &init_mm);
> + ptdump_walk_pgd(&st.ptdump, &init_mm, NULL);
>
> if (st.wx_pages || st.uxn_pages)
> pr_warn("Checked W+X mappings: FAILED, %lu W+X pages found, %lu non-UXN pages found\n",
> --
> 2.21.0 (Apple Git-122.2)
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH -next] arm64/mm/dump: fix a compilation error
2020-01-10 15:34 ` Steven Price
@ 2020-01-10 16:07 ` Will Deacon
0 siblings, 0 replies; 3+ messages in thread
From: Will Deacon @ 2020-01-10 16:07 UTC (permalink / raw)
To: Steven Price
Cc: Qian Cai, akpm, Catalin Marinas, linux-arm-kernel, linux-mm,
linux-kernel, sfr
On Fri, Jan 10, 2020 at 03:34:48PM +0000, Steven Price wrote:
> On Fri, Jan 10, 2020 at 02:51:12PM +0000, Qian Cai wrote:
> > The linux-next commit "x86: mm: avoid allocating struct mm_struct on the
> > stack" [1] introduced a compilation error with "arm64: mm: convert
> > mm/dump.c to use walk_page_range()" [2]. Fixed it by using the new API.
> >
> > arch/arm64/mm/dump.c:326:38: error: too few arguments to function call,
> > expected 3, have 2
> > ptdump_walk_pgd(&st.ptdump, info->mm);
> > ~~~~~~~~~~~~~~~ ^
> > ./include/linux/ptdump.h:20:1: note: 'ptdump_walk_pgd' declared here
> > void ptdump_walk_pgd(struct ptdump_state *st, struct mm_struct *mm,
> > pgd_t *pgd);
> > ^
> > arch/arm64/mm/dump.c:364:38: error: too few arguments to function call,
> > expected 3, have 2
> > ptdump_walk_pgd(&st.ptdump, &init_mm);
> > ~~~~~~~~~~~~~~~ ^
> > ./include/linux/ptdump.h:20:1: note: 'ptdump_walk_pgd' declared here
> > void ptdump_walk_pgd(struct ptdump_state *st, struct mm_struct *mm,
> > pgd_t *pgd);
> > ^
> > 2 errors generated.
> >
> > [1] http://lkml.kernel.org/r/20200108145710.34314-1-steven.price@arm.com
>
> Actually this was in the patch I originally posted - somehow it got
> lost when Andrew picked it up.
>
> > [2] http://lkml.kernel.org/r/20191218162402.45610-22-steven.price@arm.com
> >
> > Signed-off-by: Qian Cai <cai@lca.pw>
>
> Since this matches what I originally wrote... ;)
>
> Reviewed-by: Steven Price <steven.price@arm.com>
Acked-by: Will Deacon <will@kernel.org>
I'm assuming Andrew will queue this alongside the others.
Thanks,
Will
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-01-10 16:07 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-10 14:51 [PATCH -next] arm64/mm/dump: fix a compilation error Qian Cai
2020-01-10 15:34 ` Steven Price
2020-01-10 16:07 ` Will Deacon
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).