diff mbox

powerpc/mm: Simplify _PAGE_RO handling in page table dump

Message ID 20170509141626.F30E767954@pc13941vm.idsi0.si.c-s.fr (mailing list archive)
State Superseded
Headers show

Commit Message

Christophe Leroy May 9, 2017, 2:16 p.m. UTC
Commit fd893fe56a130 ("powerpc/mm: Fix missing page attributes in
page table dump") added support of _PAGE_RO attribute.

This patch makes it more simple

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
---
 arch/powerpc/mm/dump_linuxpagetables.c | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

Comments

Christophe Leroy Dec. 22, 2017, 12:11 p.m. UTC | #1
Ping ?

Le 09/05/2017 à 16:16, Christophe Leroy a écrit :
> Commit fd893fe56a130 ("powerpc/mm: Fix missing page attributes in
> page table dump") added support of _PAGE_RO attribute.
> 
> This patch makes it more simple
> 
> Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
> ---
>   arch/powerpc/mm/dump_linuxpagetables.c | 7 +------
>   1 file changed, 1 insertion(+), 6 deletions(-)
> 
> diff --git a/arch/powerpc/mm/dump_linuxpagetables.c b/arch/powerpc/mm/dump_linuxpagetables.c
> index d659345a98d6..eeef51107cff 100644
> --- a/arch/powerpc/mm/dump_linuxpagetables.c
> +++ b/arch/powerpc/mm/dump_linuxpagetables.c
> @@ -121,13 +121,8 @@ static const struct flag_info flag_array[] = {
>   		.set	= "user",
>   		.clear	= "    ",
>   	}, {
> -#if _PAGE_RO == 0
> -		.mask	= _PAGE_RW,
> +		.mask	= _PAGE_RW | _PAGE_RO,
>   		.val	= _PAGE_RW,
> -#else
> -		.mask	= _PAGE_RO,
> -		.val	= 0,
> -#endif
>   		.set	= "rw",
>   		.clear	= "ro",
>   	}, {
>
Christophe Leroy Jan. 12, 2018, 7:33 p.m. UTC | #2
Le 09/05/2017 à 16:16, Christophe Leroy a écrit :
> Commit fd893fe56a130 ("powerpc/mm: Fix missing page attributes in
> page table dump") added support of _PAGE_RO attribute.
> 
> This patch makes it more simple

Superseeded by https://patchwork.ozlabs.org/patch/859896/

Christophe

> 
> Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
> ---
>   arch/powerpc/mm/dump_linuxpagetables.c | 7 +------
>   1 file changed, 1 insertion(+), 6 deletions(-)
> 
> diff --git a/arch/powerpc/mm/dump_linuxpagetables.c b/arch/powerpc/mm/dump_linuxpagetables.c
> index d659345a98d6..eeef51107cff 100644
> --- a/arch/powerpc/mm/dump_linuxpagetables.c
> +++ b/arch/powerpc/mm/dump_linuxpagetables.c
> @@ -121,13 +121,8 @@ static const struct flag_info flag_array[] = {
>   		.set	= "user",
>   		.clear	= "    ",
>   	}, {
> -#if _PAGE_RO == 0
> -		.mask	= _PAGE_RW,
> +		.mask	= _PAGE_RW | _PAGE_RO,
>   		.val	= _PAGE_RW,
> -#else
> -		.mask	= _PAGE_RO,
> -		.val	= 0,
> -#endif
>   		.set	= "rw",
>   		.clear	= "ro",
>   	}, {
> 

---
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast.
https://www.avast.com/antivirus
diff mbox

Patch

diff --git a/arch/powerpc/mm/dump_linuxpagetables.c b/arch/powerpc/mm/dump_linuxpagetables.c
index d659345a98d6..eeef51107cff 100644
--- a/arch/powerpc/mm/dump_linuxpagetables.c
+++ b/arch/powerpc/mm/dump_linuxpagetables.c
@@ -121,13 +121,8 @@  static const struct flag_info flag_array[] = {
 		.set	= "user",
 		.clear	= "    ",
 	}, {
-#if _PAGE_RO == 0
-		.mask	= _PAGE_RW,
+		.mask	= _PAGE_RW | _PAGE_RO,
 		.val	= _PAGE_RW,
-#else
-		.mask	= _PAGE_RO,
-		.val	= 0,
-#endif
 		.set	= "rw",
 		.clear	= "ro",
 	}, {