]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commit - drivers/iommu/arm-smmu.c
iommu/arm-smmu: fix s2cr and smr teardown on device detach from domain
authorWill Deacon <will.deacon@arm.com>
Tue, 15 Jul 2014 10:22:24 +0000 (11:22 +0100)
committerWill Deacon <will.deacon@arm.com>
Tue, 2 Sep 2014 09:04:33 +0000 (10:04 +0100)
commit43b412bedb782e27a8771b61870dd45a24975266
treeb8abdc086bb801a3cb58b1389bff2a370a691c87
parent93b14135cf24668b45eb57348312b627a8539bc4
iommu/arm-smmu: fix s2cr and smr teardown on device detach from domain

When we attach a device to a domain, we configure the SMRs (if we have
any) to match the Stream IDs for the corresponding SMMU master and
program the s2crs accordingly. However, on detach we tear down the s2crs
assuming stream-indexing (as opposed to stream-matching) and SMRs
assuming they are present.

This patch fixes the device detach code so that it operates as a
converse of the attach code.

Cc: <stable@vger.kernel.org>
Signed-off-by: Will Deacon <will.deacon@arm.com>
drivers/iommu/arm-smmu.c