diff mbox series

powerpc/ptdump: Fix DEBUG_WX since generic ptdump conversion

Message ID 20211203124112.2912562-1-mpe@ellerman.id.au (mailing list archive)
State Accepted
Headers show
Series powerpc/ptdump: Fix DEBUG_WX since generic ptdump conversion | expand

Checks

Context Check Description
snowpatch_ozlabs/github-powerpc_selftests success Successfully ran 8 jobs.
snowpatch_ozlabs/github-powerpc_ppctests success Successfully ran 8 jobs.
snowpatch_ozlabs/github-powerpc_clang success Successfully ran 7 jobs.
snowpatch_ozlabs/github-powerpc_sparse success Successfully ran 4 jobs.
snowpatch_ozlabs/github-powerpc_kernel_qemu success Successfully ran 24 jobs.

Commit Message

Michael Ellerman Dec. 3, 2021, 12:41 p.m. UTC
In note_prot_wx() we bail out without reporting anything if
CONFIG_PPC_DEBUG_WX is disabled.

But CONFIG_PPC_DEBUG_WX was removed in the conversion to generic ptdump,
we now need to use CONFIG_DEBUG_WX instead.

Fixes: e084728393a5 ("powerpc/ptdump: Convert powerpc to GENERIC_PTDUMP")
Cc: stable@vger.kernel.org # v5.15+
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
---
 arch/powerpc/mm/ptdump/ptdump.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Christophe Leroy Dec. 3, 2021, 12:55 p.m. UTC | #1
Le 03/12/2021 à 13:41, Michael Ellerman a écrit :
> In note_prot_wx() we bail out without reporting anything if
> CONFIG_PPC_DEBUG_WX is disabled.
> 
> But CONFIG_PPC_DEBUG_WX was removed in the conversion to generic ptdump,
> we now need to use CONFIG_DEBUG_WX instead.
> 
> Fixes: e084728393a5 ("powerpc/ptdump: Convert powerpc to GENERIC_PTDUMP")
> Cc: stable@vger.kernel.org # v5.15+
> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
> ---

Oops ... my mistake.

Reviewed-by: Christophe Leroy <christophe.leroy@csgroup.eu>

>   arch/powerpc/mm/ptdump/ptdump.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/powerpc/mm/ptdump/ptdump.c b/arch/powerpc/mm/ptdump/ptdump.c
> index 031956d0ee84..be120e09aa3e 100644
> --- a/arch/powerpc/mm/ptdump/ptdump.c
> +++ b/arch/powerpc/mm/ptdump/ptdump.c
> @@ -183,7 +183,7 @@ static void note_prot_wx(struct pg_state *st, unsigned long addr)
>   {
>   	pte_t pte = __pte(st->current_flags);
>   
> -	if (!IS_ENABLED(CONFIG_PPC_DEBUG_WX) || !st->check_wx)
> +	if (!IS_ENABLED(CONFIG_DEBUG_WX) || !st->check_wx)
>   		return;
>   
>   	if (!pte_write(pte) || !pte_exec(pte))
>
Michael Ellerman Dec. 26, 2021, 9:51 p.m. UTC | #2
On Fri, 3 Dec 2021 23:41:12 +1100, Michael Ellerman wrote:
> In note_prot_wx() we bail out without reporting anything if
> CONFIG_PPC_DEBUG_WX is disabled.
> 
> But CONFIG_PPC_DEBUG_WX was removed in the conversion to generic ptdump,
> we now need to use CONFIG_DEBUG_WX instead.
> 
> 
> [...]

Applied to powerpc/fixes.

[1/1] powerpc/ptdump: Fix DEBUG_WX since generic ptdump conversion
      https://git.kernel.org/powerpc/c/8d84fca4375e3c35dadc16b8c7eee6821b2a575c

cheers
diff mbox series

Patch

diff --git a/arch/powerpc/mm/ptdump/ptdump.c b/arch/powerpc/mm/ptdump/ptdump.c
index 031956d0ee84..be120e09aa3e 100644
--- a/arch/powerpc/mm/ptdump/ptdump.c
+++ b/arch/powerpc/mm/ptdump/ptdump.c
@@ -183,7 +183,7 @@  static void note_prot_wx(struct pg_state *st, unsigned long addr)
 {
 	pte_t pte = __pte(st->current_flags);
 
-	if (!IS_ENABLED(CONFIG_PPC_DEBUG_WX) || !st->check_wx)
+	if (!IS_ENABLED(CONFIG_DEBUG_WX) || !st->check_wx)
 		return;
 
 	if (!pte_write(pte) || !pte_exec(pte))