Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 27af2544 authored by Will Deacon's avatar Will Deacon Committed by Mitchel Humpherys
Browse files

iommu/arm-smmu: really fix page table locking



Commit a44a9791e778 ("iommu/arm-smmu: use mutex instead of spinlock for
locking page tables") replaced the page table spinlock with a mutex, to
allow blocking allocations to satisfy lazy mapping requests.

Unfortunately, it turns out that IOMMU mappings are created from atomic
context (e.g. spinlock held during a dma_map), so this change doesn't
really help us in practice.

This patch is a partial revert of the offending commit, bringing back
the original spinlock but replacing our page table allocations for any
levels below the pgd (which is allocated during domain init) with
GFP_ATOMIC instead of GFP_KERNEL.

Change-Id: I5e9eda34d5f22175aa453329d29141e9ced3148d
Cc: <stable@vger.kernel.org>
Reported-by: default avatarAndreas Herrmann <andreas.herrmann@calxeda.com>
Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
Git-commit: c9d09e2748eaa55cac2af274574baa6368189bc1
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git


Signed-off-by: default avatarMitchel Humpherys <mitchelh@codeaurora.org>
parent 2f9692d3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment