]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
powerpc/spufs: Fix hash faults for kernel regions
authorJeremy Kerr <jk@ozlabs.org>
Wed, 24 May 2017 06:49:59 +0000 (16:49 +1000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 7 Jun 2017 10:10:06 +0000 (12:10 +0200)
commitbaa4d4112e6f8f449056b7e32d55a30102976b54
tree3345f9ccc549bff89216e92c01615aabcb080cf9
parent919c7173e08ac070794873decb8ce1335219503f
powerpc/spufs: Fix hash faults for kernel regions

commit d75e4919cc0b6fbcbc8d6654ef66d87a9dbf1526 upstream.

Commit ac29c64089b7 ("powerpc/mm: Replace _PAGE_USER with
_PAGE_PRIVILEGED") swapped _PAGE_USER for _PAGE_PRIVILEGED, and
introduced check_pte_access() which denied kernel access to
non-_PAGE_PRIVILEGED pages.

However, it didn't add _PAGE_PRIVILEGED to the hash fault handler
for spufs' kernel accesses, so the DMAs required to establish SPE
memory no longer work.

This change adds _PAGE_PRIVILEGED to the hash fault handler for
kernel accesses.

Fixes: ac29c64089b7 ("powerpc/mm: Replace _PAGE_USER with _PAGE_PRIVILEGED")
Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Reported-by: Sombat Tragolgosol <sombat3960@gmail.com>
Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/powerpc/platforms/cell/spu_base.c