]> git.baikalelectronics.ru Git - kernel.git/commit
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)
commita36c76e5854ba896145ea74491d856eaa7a345de
treeb8abdc086bb801a3cb58b1389bff2a370a691c87
parentaaa9826d92ae68e7291cc09c2eb402f909fb5c4f
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