Browse Source

msm: iommu: Use the correct memory allocation flag

Change msm_iommu_map to use GFP_ATOMIC instead of
GFP_KERNEL due to the fact that the call occurs within
a spinlock-protected region.

Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Stepan Moskovchenko 14 năm trước cách đây
mục cha
commit
294b2dea83
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      arch/arm/mach-msm/iommu.c

+ 1 - 1
arch/arm/mach-msm/iommu.c

@@ -386,7 +386,7 @@ static int msm_iommu_map(struct iommu_domain *domain, unsigned long va,
 	/* Need a 2nd level table */
 	if ((len == SZ_4K || len == SZ_64K) && (*fl_pte) == 0) {
 		unsigned long *sl;
-		sl = (unsigned long *) __get_free_pages(GFP_KERNEL,
+		sl = (unsigned long *) __get_free_pages(GFP_ATOMIC,
 							get_order(SZ_4K));
 
 		if (!sl) {