diff options
author | Christian König <christian.koenig@amd.com> | 2021-02-05 16:17:07 +0100 |
---|---|---|
committer | Christian König <christian.koenig@amd.com> | 2021-04-23 16:23:02 +0200 |
commit | c777dc9e793342ecdfc95045d2127a3ea32791a0 (patch) | |
tree | 19374d31192d8143db67d3576dd389974f6dd306 /drivers/gpu/drm/ttm/ttm_bo.c | |
parent | 65747ded86b4608387d5618d14f0fe9dc88e17ea (diff) | |
download | linux-c777dc9e793342ecdfc95045d2127a3ea32791a0.tar.bz2 |
drm/ttm: move the page_alignment into the BO v2
The alignment is a constant property and shouldn't change.
v2: move documentation as well as suggested by Matthew.
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20210413135248.1266-4-christian.koenig@amd.com
Diffstat (limited to 'drivers/gpu/drm/ttm/ttm_bo.c')
-rw-r--r-- | drivers/gpu/drm/ttm/ttm_bo.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c index 5b332206c1ac..df63a07a70de 100644 --- a/drivers/gpu/drm/ttm/ttm_bo.c +++ b/drivers/gpu/drm/ttm/ttm_bo.c @@ -903,7 +903,6 @@ static int ttm_bo_move_buffer(struct ttm_buffer_object *bo, memset(&hop, 0, sizeof(hop)); mem.num_pages = PAGE_ALIGN(bo->base.size) >> PAGE_SHIFT; - mem.page_alignment = bo->mem.page_alignment; mem.bus.offset = 0; mem.bus.addr = NULL; mem.mm_node = NULL; @@ -1038,10 +1037,10 @@ int ttm_bo_init_reserved(struct ttm_device *bdev, INIT_LIST_HEAD(&bo->ddestroy); bo->bdev = bdev; bo->type = type; + bo->page_alignment = page_alignment; bo->mem.mem_type = TTM_PL_SYSTEM; bo->mem.num_pages = PAGE_ALIGN(size) >> PAGE_SHIFT; bo->mem.mm_node = NULL; - bo->mem.page_alignment = page_alignment; bo->mem.bus.offset = 0; bo->mem.bus.addr = NULL; bo->moving = NULL; |