diff options
author | Christophe Leroy <christophe.leroy@c-s.fr> | 2019-05-09 15:59:38 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-05-22 08:39:58 +0300 |
commit | fda49aec25150dfb62aff5d2cb520e79bb471d64 (patch) | |
tree | 0d314f46a972c84036f6264dfa12f0d341d2e309 /arch | |
parent | 4d9ec1625ac5895fd5555ae16d7a5793848a39fe (diff) | |
download | linux-fda49aec25150dfb62aff5d2cb520e79bb471d64.tar.xz |
powerpc/32s: fix flush_hash_pages() on SMP
commit 397d2300b08cdee052053e362018cdb6dd65eea2 upstream.
flush_hash_pages() runs with data translation off, so current
task_struct has to be accesssed using physical address.
Fixes: f7354ccac844 ("powerpc/32: Remove CURRENT_THREAD_INFO and rename TI_CPU")
Cc: stable@vger.kernel.org # v5.1+
Reported-by: Erhard F. <erhard_f@mailbox.org>
Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/powerpc/mm/hash_low_32.S | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/powerpc/mm/hash_low_32.S b/arch/powerpc/mm/hash_low_32.S index a6c491f18a04..5842cfa0394d 100644 --- a/arch/powerpc/mm/hash_low_32.S +++ b/arch/powerpc/mm/hash_low_32.S @@ -539,7 +539,8 @@ _GLOBAL(flush_hash_pages) #ifdef CONFIG_SMP lis r9, (mmu_hash_lock - PAGE_OFFSET)@ha addi r9, r9, (mmu_hash_lock - PAGE_OFFSET)@l - lwz r8,TASK_CPU(r2) + tophys (r8, r2) + lwz r8, TASK_CPU(r8) oris r8,r8,9 10: lwarx r0,0,r9 cmpi 0,r0,0 |