mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-26 02:39:48 +00:00
drm/ttm: fix highuser vs dma32 confusion.
DMA32 and highmem are sort of exclusive. Noticed by AndrewR on #radeon. Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
parent
ea3c13bd8c
commit
b42db2b12d
1 changed files with 3 additions and 1 deletions
|
@ -137,13 +137,15 @@ static void ttm_tt_free_page_directory(struct ttm_tt *ttm)
|
|||
|
||||
static struct page *ttm_tt_alloc_page(unsigned page_flags)
|
||||
{
|
||||
gfp_t gfp_flags = GFP_HIGHUSER;
|
||||
gfp_t gfp_flags = GFP_USER;
|
||||
|
||||
if (page_flags & TTM_PAGE_FLAG_ZERO_ALLOC)
|
||||
gfp_flags |= __GFP_ZERO;
|
||||
|
||||
if (page_flags & TTM_PAGE_FLAG_DMA32)
|
||||
gfp_flags |= __GFP_DMA32;
|
||||
else
|
||||
gfp_flags |= __GFP_HIGHMEM;
|
||||
|
||||
return alloc_page(gfp_flags);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue