浏览代码

AMD IOMMU: allocate rlookup_table with __GFP_ZERO

Impact: fix bug which can lead to panic in prealloc_protection_domains()

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Joerg Roedel 16 年之前
父节点
当前提交
83fd5cc648
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      arch/x86/kernel/amd_iommu_init.c

+ 2 - 1
arch/x86/kernel/amd_iommu_init.c

@@ -1074,7 +1074,8 @@ int __init amd_iommu_init(void)
 		goto free;
 
 	/* IOMMU rlookup table - find the IOMMU for a specific device */
-	amd_iommu_rlookup_table = (void *)__get_free_pages(GFP_KERNEL,
+	amd_iommu_rlookup_table = (void *)__get_free_pages(
+			GFP_KERNEL | __GFP_ZERO,
 			get_order(rlookup_table_size));
 	if (amd_iommu_rlookup_table == NULL)
 		goto free;