From 02aaa54418071c4877ba0375f4102f97910a3d17 Mon Sep 17 00:00:00 2001 From: Felix Kuehling Date: Tue, 21 Mar 2017 11:25:30 -0400 Subject: [PATCH 1636/4131] drm/amdgpu: Use GFP_NOIO with reclaim-safe locks Locks that are held in reclaim-fs context (in MMU notifiers invoked under memory pressure) must not themselves cause memory reclaims while held to prevent deadlocks. Use GFP_NOIO to ensure this. Change-Id: I94d5ebf4b1247618701701e37dad6acdfdf9a46d Signed-off-by: Felix Kuehling --- drivers/gpu/drm/amd/amdgpu/amdgpu_mn.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_mn.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_mn.c index d961477..7076d08 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_mn.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_mn.c @@ -410,7 +410,7 @@ int amdgpu_mn_register(struct amdgpu_bo *bo, unsigned long addr) } if (!node) { - node = kmalloc(sizeof(struct amdgpu_mn_node), GFP_KERNEL); + node = kmalloc(sizeof(struct amdgpu_mn_node), GFP_NOIO); if (!node) { mutex_unlock(&rmn->lock); return -ENOMEM; -- 2.7.4