Re: [PATCH 2/3] powerpc/mm/slb: Move comment next to the code it's referring to

2017-08-02 Thread Aneesh Kumar K.V
Michael Ellerman  writes:

> There is a comment in slb_allocate() referring to the load of
> paca->vmalloc_sllp, but it's several lines prior in the assembly.
> We're about to change this code, and we want to add another comment,
> so move the comment immediately prior to the instruction it's talking
> about.
>

Reviewed-by: Aneesh Kumar K.V 

> Signed-off-by: Michael Ellerman 
> ---
>  arch/powerpc/mm/slb_low.S | 7 ---
>  1 file changed, 4 insertions(+), 3 deletions(-)
>
> diff --git a/arch/powerpc/mm/slb_low.S b/arch/powerpc/mm/slb_low.S
> index bde378559d01..2eb1b92a68ff 100644
> --- a/arch/powerpc/mm/slb_low.S
> +++ b/arch/powerpc/mm/slb_low.S
> @@ -121,12 +121,13 @@ slb_miss_kernel_load_vmemmap:
>  1:
>  #endif /* CONFIG_SPARSEMEM_VMEMMAP */
>
> - /* vmalloc mapping gets the encoding from the PACA as the mapping
> -  * can be demoted from 64K -> 4K dynamically on some machines
> -  */
>   clrldi  r11,r10,48
>   cmpldi  r11,(H_VMALLOC_SIZE >> 28) - 1
>   bgt 5f
> + /*
> +  * vmalloc mapping gets the encoding from the PACA as the mapping
> +  * can be demoted from 64K -> 4K dynamically on some machines.
> +  */
>   lhz r11,PACAVMALLOCSLLP(r13)
>   b   6f
>  5:
> -- 
> 2.7.4



[PATCH 2/3] powerpc/mm/slb: Move comment next to the code it's referring to

2017-08-01 Thread Michael Ellerman
There is a comment in slb_allocate() referring to the load of
paca->vmalloc_sllp, but it's several lines prior in the assembly.
We're about to change this code, and we want to add another comment,
so move the comment immediately prior to the instruction it's talking
about.

Signed-off-by: Michael Ellerman 
---
 arch/powerpc/mm/slb_low.S | 7 ---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/arch/powerpc/mm/slb_low.S b/arch/powerpc/mm/slb_low.S
index bde378559d01..2eb1b92a68ff 100644
--- a/arch/powerpc/mm/slb_low.S
+++ b/arch/powerpc/mm/slb_low.S
@@ -121,12 +121,13 @@ slb_miss_kernel_load_vmemmap:
 1:
 #endif /* CONFIG_SPARSEMEM_VMEMMAP */
 
-   /* vmalloc mapping gets the encoding from the PACA as the mapping
-* can be demoted from 64K -> 4K dynamically on some machines
-*/
clrldi  r11,r10,48
cmpldi  r11,(H_VMALLOC_SIZE >> 28) - 1
bgt 5f
+   /*
+* vmalloc mapping gets the encoding from the PACA as the mapping
+* can be demoted from 64K -> 4K dynamically on some machines.
+*/
lhz r11,PACAVMALLOCSLLP(r13)
b   6f
 5:
-- 
2.7.4