summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/nouveau/nouveau_ttm.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2021-03-18 19:14:24 +0300
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>2021-03-19 07:58:25 +0300
commit2cbc2776efe4faed0e17c48ae076aa03a0fcc61f (patch)
tree9f3fbd9abc1e971ad0807dcd2e0645b9aafd8634 /drivers/gpu/drm/nouveau/nouveau_ttm.c
parent2d29960af0bee8cc6731b9bd3964850c9e7a6840 (diff)
downloadlinux-2cbc2776efe4faed0e17c48ae076aa03a0fcc61f.tar.xz
swiotlb: remove swiotlb_nr_tbl
All callers just use it to check if swiotlb is active at all, for which they can just use is_swiotlb_active. In the longer run drivers need to stop using is_swiotlb_active as well, but let's do the simple step first. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nouveau_ttm.c')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_ttm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_ttm.c b/drivers/gpu/drm/nouveau/nouveau_ttm.c
index a37bc3d7b38b..9662522aa066 100644
--- a/drivers/gpu/drm/nouveau/nouveau_ttm.c
+++ b/drivers/gpu/drm/nouveau/nouveau_ttm.c
@@ -321,7 +321,7 @@ nouveau_ttm_init(struct nouveau_drm *drm)
}
#if IS_ENABLED(CONFIG_SWIOTLB) && IS_ENABLED(CONFIG_X86)
- need_swiotlb = !!swiotlb_nr_tbl();
+ need_swiotlb = is_swiotlb_active();
#endif
ret = ttm_bo_device_init(&drm->ttm.bdev, &nouveau_bo_driver,