]> Pileus Git - ~andy/linux/blobdiff - arch/x86/kernel/amd_iommu_init.c
AMD IOMMU: free domain bitmap with its allocation order
[~andy/linux] / arch / x86 / kernel / amd_iommu_init.c
index 8c137598555737807a9bd1d1dd514b62a45ae01d..e60f4cd29eb25a7e717d236ccb08263eda72671a 100644 (file)
@@ -1144,7 +1144,8 @@ out:
        return ret;
 
 free:
-       free_pages((unsigned long)amd_iommu_pd_alloc_bitmap, 1);
+       free_pages((unsigned long)amd_iommu_pd_alloc_bitmap,
+                  get_order(MAX_DOMAIN_ID/8));
 
        free_pages((unsigned long)amd_iommu_pd_table,
                   get_order(rlookup_table_size));