From: Ma Jun Date: Wed, 31 May 2023 05:30:51 +0000 (+0800) Subject: drm/ttm: Remove redundant code in ttm_tt_init_fields X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=2ce977df10c179138e2723b25c2d2c055a3e3cc6;p=linux.git drm/ttm: Remove redundant code in ttm_tt_init_fields Remove redundant assignment code for ttm->caching as it's overwritten just a few lines later. v2: - Update the commit message. Signed-off-by: Ma Jun Reviewed-by: Guchun Chen Reviewed-by: Christian König Signed-off-by: Christian König Link: https://patchwork.freedesktop.org/patch/msgid/20230531053051.3453509-1-Jun.Ma2@amd.com --- diff --git a/drivers/gpu/drm/ttm/ttm_tt.c b/drivers/gpu/drm/ttm/ttm_tt.c index ab725d9d14a69..1ce4b36ab33be 100644 --- a/drivers/gpu/drm/ttm/ttm_tt.c +++ b/drivers/gpu/drm/ttm/ttm_tt.c @@ -137,7 +137,6 @@ static void ttm_tt_init_fields(struct ttm_tt *ttm, unsigned long extra_pages) { ttm->num_pages = (PAGE_ALIGN(bo->base.size) >> PAGE_SHIFT) + extra_pages; - ttm->caching = ttm_cached; ttm->page_flags = page_flags; ttm->dma_address = NULL; ttm->swap_storage = NULL;