diff options
author | Will Deacon <will.deacon@arm.com> | 2016-02-17 17:41:57 +0000 |
---|---|---|
committer | Will Deacon <will.deacon@arm.com> | 2016-02-18 15:02:44 +0000 |
commit | bc7f2ce0a7b54ba7703f81995fe434f0926424d2 (patch) | |
tree | 1e27c323f9c3becd069a36abb54ff2fb2ca7d93b /drivers/iommu/intel-iommu.c | |
parent | 25a1c96cd22c949b50d6f0269c23e1c5cb55e5a5 (diff) |
iommu/arm-smmu: Don't fail device attach if already attached to a domain
The ARM SMMU attach_dev implementations returns -EEXIST if the device
being attached is already attached to a domain. This doesn't play nicely
with the default domain, resulting in splats such as:
WARNING: at drivers/iommu/iommu.c:1257
Modules linked in:
CPU: 3 PID: 1939 Comm: virtio-net-tx Tainted: G S 4.5.0-rc4+ #1
Hardware name: FVP Base (DT)
task: ffffffc87a9d0000 ti: ffffffc07a278000 task.ti: ffffffc07a278000
PC is at __iommu_detach_group+0x68/0xe8
LR is at __iommu_detach_group+0x48/0xe8
This patch fixes the problem by forcefully detaching the device from
its old domain, if present, when attaching to a new one. The unused
->detach_dev callback is also removed the iommu_ops structures.
Signed-off-by: Will Deacon <will.deacon@arm.com>
Diffstat (limited to 'drivers/iommu/intel-iommu.c')
0 files changed, 0 insertions, 0 deletions