]> git.baikalelectronics.ru Git - kernel.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)
committerMichael Ellerman <mpe@ellerman.id.au>
Thu, 25 May 2017 13:07:44 +0000 (23:07 +1000)
commit7e6ab3d6b73b2f193bda6a7c03153b263255ef63
tree4b9247e309d5b48246b0c94532ca9c81da23b2b3
parentee54e096332f6b480ce85a596eb20e194e964d2d
powerpc/spufs: Fix hash faults for kernel regions

Commit d71a3fc76796 ("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: d71a3fc76796 ("powerpc/mm: Replace _PAGE_USER with _PAGE_PRIVILEGED")
Cc: stable@vger.kernel.org # v4.7+
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>
arch/powerpc/platforms/cell/spu_base.c