Donald Dutile 94a91b5051 intel-iommu: iommu init error path bug fixes
The kcalloc() failure path in iommu_init_domains() calls
free_dmar_iommu(), which assumes that ->domains, ->domain_ids,
and ->lock have been properly initialized.

Add checks in free_[dmar]_iommu to not use ->domains,->domain_ids
if not alloced. Move the lock init to prior to the kcalloc()'s,
so it is valid in free_context_table() when free_dmar_iommu() invokes
it at the end.

Patch based on iommu-2.6,
commit 132032274a594ee9ffb6b9c9e2e9698149a09ea9

Signed-off-by: Donald Dutile <ddutile@redhat.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2009-08-24 08:56:26 +01:00
..
2009-07-28 21:07:09 -04:00
2009-07-12 12:22:34 -07:00
2009-06-16 19:50:13 -07:00
2009-06-17 09:35:24 -07:00
2009-07-12 12:22:34 -07:00
2009-07-03 15:45:29 +01:00
2009-08-04 20:31:32 +02:00
2009-08-03 14:25:00 +01:00
2009-06-18 13:04:04 -07:00
2009-07-29 19:10:35 -07:00
2009-07-12 12:22:34 -07:00
2009-07-30 16:03:45 +09:30
2009-07-01 11:19:47 +02:00
2009-06-18 13:04:04 -07:00
2009-06-18 13:04:04 -07:00