iommu/amd: Introduce protection_domain_init() function
authorJoerg Roedel <jroedel@suse.de>
Tue, 30 Jun 2015 06:56:11 +0000 (08:56 +0200)
committerJoerg Roedel <jroedel@suse.de>
Wed, 1 Jul 2015 06:43:07 +0000 (08:43 +0200)
This function contains the common parts between the
initialization of dma_ops_domains and usual protection
domains. This also fixes a long-standing bug which was
uncovered by recent changes, in which the api_lock was not
initialized for dma_ops_domains.

Reported-by: George Wang <xuw2015@gmail.com>
Tested-by: George Wang <xuw2015@gmail.com>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/amd_iommu.c

Simple merge