diff mbox series

[2/2] drm/ttm: drop evicted from ttm_bo.

Message ID 20200917064132.148521-3-airlied@gmail.com (mailing list archive)
State New, archived
Headers show
Series ttm follow-on cleanups | expand

Commit Message

Dave Airlie Sept. 17, 2020, 6:41 a.m. UTC
From: Dave Airlie <airlied@redhat.com>

This was unused.

Signed-off-by: Dave Airlie <airlied@redhat.com>
---
 drivers/gpu/drm/ttm/ttm_bo.c | 4 ----
 include/drm/ttm/ttm_bo_api.h | 1 -
 2 files changed, 5 deletions(-)

Comments

Christian König Sept. 17, 2020, 8:02 a.m. UTC | #1
Am 17.09.20 um 08:41 schrieb Dave Airlie:
> From: Dave Airlie <airlied@redhat.com>
>
> This was unused.
>
> Signed-off-by: Dave Airlie <airlied@redhat.com>

Reviewed-by: Christian König <christian.koenig@amd.com>

> ---
>   drivers/gpu/drm/ttm/ttm_bo.c | 4 ----
>   include/drm/ttm/ttm_bo_api.h | 1 -
>   2 files changed, 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c
> index 279a0e44a5ed..7562b0844c75 100644
> --- a/drivers/gpu/drm/ttm/ttm_bo.c
> +++ b/drivers/gpu/drm/ttm/ttm_bo.c
> @@ -298,8 +298,6 @@ static int ttm_bo_handle_move_mem(struct ttm_buffer_object *bo,
>   	}
>   
>   moved:
> -	bo->evicted = false;
> -
>   	ctx->bytes_moved += bo->num_pages << PAGE_SHIFT;
>   	return 0;
>   
> @@ -638,9 +636,7 @@ static int ttm_bo_evict(struct ttm_buffer_object *bo,
>   		if (ret != -ERESTARTSYS)
>   			pr_err("Buffer eviction failed\n");
>   		ttm_resource_free(bo, &evict_mem);
> -		goto out;
>   	}
> -	bo->evicted = true;
>   out:
>   	return ret;
>   }
> diff --git a/include/drm/ttm/ttm_bo_api.h b/include/drm/ttm/ttm_bo_api.h
> index 36ff64e2736c..03b4761a3ea3 100644
> --- a/include/drm/ttm/ttm_bo_api.h
> +++ b/include/drm/ttm/ttm_bo_api.h
> @@ -141,7 +141,6 @@ struct ttm_buffer_object {
>   	struct ttm_resource mem;
>   	struct file *persistent_swap_storage;
>   	struct ttm_tt *ttm;
> -	bool evicted;
>   	bool deleted;
>   
>   	/**
diff mbox series

Patch

diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c
index 279a0e44a5ed..7562b0844c75 100644
--- a/drivers/gpu/drm/ttm/ttm_bo.c
+++ b/drivers/gpu/drm/ttm/ttm_bo.c
@@ -298,8 +298,6 @@  static int ttm_bo_handle_move_mem(struct ttm_buffer_object *bo,
 	}
 
 moved:
-	bo->evicted = false;
-
 	ctx->bytes_moved += bo->num_pages << PAGE_SHIFT;
 	return 0;
 
@@ -638,9 +636,7 @@  static int ttm_bo_evict(struct ttm_buffer_object *bo,
 		if (ret != -ERESTARTSYS)
 			pr_err("Buffer eviction failed\n");
 		ttm_resource_free(bo, &evict_mem);
-		goto out;
 	}
-	bo->evicted = true;
 out:
 	return ret;
 }
diff --git a/include/drm/ttm/ttm_bo_api.h b/include/drm/ttm/ttm_bo_api.h
index 36ff64e2736c..03b4761a3ea3 100644
--- a/include/drm/ttm/ttm_bo_api.h
+++ b/include/drm/ttm/ttm_bo_api.h
@@ -141,7 +141,6 @@  struct ttm_buffer_object {
 	struct ttm_resource mem;
 	struct file *persistent_swap_storage;
 	struct ttm_tt *ttm;
-	bool evicted;
 	bool deleted;
 
 	/**