Commit df1b4b91 authored by Max Filippov's avatar Max Filippov Committed by Ben Skeggs

drm/nouveau: only call ttm_agp_tt_create when __OS_HAS_AGP

ttm_agp_tt_create is itself defined under CONFIG_AGP, so there's no
point calling it otherwise.
Signed-off-by: default avatarMax Filippov <jcmvbkbc@gmail.com>
Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
parent 5db4c6c5
...@@ -456,6 +456,7 @@ static struct ttm_tt * ...@@ -456,6 +456,7 @@ static struct ttm_tt *
nouveau_ttm_tt_create(struct ttm_bo_device *bdev, unsigned long size, nouveau_ttm_tt_create(struct ttm_bo_device *bdev, unsigned long size,
uint32_t page_flags, struct page *dummy_read) uint32_t page_flags, struct page *dummy_read)
{ {
#if __OS_HAS_AGP
struct nouveau_drm *drm = nouveau_bdev(bdev); struct nouveau_drm *drm = nouveau_bdev(bdev);
struct drm_device *dev = drm->dev; struct drm_device *dev = drm->dev;
...@@ -463,6 +464,7 @@ nouveau_ttm_tt_create(struct ttm_bo_device *bdev, unsigned long size, ...@@ -463,6 +464,7 @@ nouveau_ttm_tt_create(struct ttm_bo_device *bdev, unsigned long size,
return ttm_agp_tt_create(bdev, dev->agp->bridge, size, return ttm_agp_tt_create(bdev, dev->agp->bridge, size,
page_flags, dummy_read); page_flags, dummy_read);
} }
#endif
return nouveau_sgdma_create_ttm(bdev, size, page_flags, dummy_read); return nouveau_sgdma_create_ttm(bdev, size, page_flags, dummy_read);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment