diff mbox series

drm/ttm: remove superflous extern attribute from funcs

Message ID 20200917094837.2787-1-christian.koenig@amd.com (mailing list archive)
State New, archived
Headers show
Series drm/ttm: remove superflous extern attribute from funcs | expand

Commit Message

Christian König Sept. 17, 2020, 9:48 a.m. UTC
Extern is the default attribute for functions anyway.

Signed-off-by: Christian König <christian.koenig@amd.com>
---
 include/drm/ttm/ttm_execbuf_util.h | 19 ++++++++-----------
 include/drm/ttm/ttm_memory.h       | 25 ++++++++++++-------------
 2 files changed, 20 insertions(+), 24 deletions(-)

Comments

Daniel Vetter Sept. 17, 2020, 11:42 a.m. UTC | #1
On Thu, Sep 17, 2020 at 11:48:37AM +0200, Christian König wrote:
> Extern is the default attribute for functions anyway.
> 
> Signed-off-by: Christian König <christian.koenig@amd.com>

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>

> ---
>  include/drm/ttm/ttm_execbuf_util.h | 19 ++++++++-----------
>  include/drm/ttm/ttm_memory.h       | 25 ++++++++++++-------------
>  2 files changed, 20 insertions(+), 24 deletions(-)
> 
> diff --git a/include/drm/ttm/ttm_execbuf_util.h b/include/drm/ttm/ttm_execbuf_util.h
> index 5a19843bb80d..a99d7fdf2964 100644
> --- a/include/drm/ttm/ttm_execbuf_util.h
> +++ b/include/drm/ttm/ttm_execbuf_util.h
> @@ -58,9 +58,8 @@ struct ttm_validate_buffer {
>   * Undoes all buffer validation reservations for bos pointed to by
>   * the list entries.
>   */
> -
> -extern void ttm_eu_backoff_reservation(struct ww_acquire_ctx *ticket,
> -				       struct list_head *list);
> +void ttm_eu_backoff_reservation(struct ww_acquire_ctx *ticket,
> +				struct list_head *list);
>  
>  /**
>   * function ttm_eu_reserve_buffers
> @@ -96,10 +95,9 @@ extern void ttm_eu_backoff_reservation(struct ww_acquire_ctx *ticket,
>   * ttm_eu_fence_buffer_objects() when command submission is complete or
>   * has failed.
>   */
> -
> -extern int ttm_eu_reserve_buffers(struct ww_acquire_ctx *ticket,
> -				  struct list_head *list, bool intr,
> -				  struct list_head *dups);
> +int ttm_eu_reserve_buffers(struct ww_acquire_ctx *ticket,
> +			   struct list_head *list, bool intr,
> +			   struct list_head *dups);
>  
>  /**
>   * function ttm_eu_fence_buffer_objects.
> @@ -113,9 +111,8 @@ extern int ttm_eu_reserve_buffers(struct ww_acquire_ctx *ticket,
>   * It also unreserves all buffers, putting them on lru lists.
>   *
>   */
> -
> -extern void ttm_eu_fence_buffer_objects(struct ww_acquire_ctx *ticket,
> -					struct list_head *list,
> -					struct dma_fence *fence);
> +void ttm_eu_fence_buffer_objects(struct ww_acquire_ctx *ticket,
> +				 struct list_head *list,
> +				 struct dma_fence *fence);
>  
>  #endif
> diff --git a/include/drm/ttm/ttm_memory.h b/include/drm/ttm/ttm_memory.h
> index 2d468d7c94e6..c1f167881e33 100644
> --- a/include/drm/ttm/ttm_memory.h
> +++ b/include/drm/ttm/ttm_memory.h
> @@ -79,18 +79,17 @@ extern struct ttm_mem_global {
>  #endif
>  } ttm_mem_glob;
>  
> -extern int ttm_mem_global_init(struct ttm_mem_global *glob);
> -extern void ttm_mem_global_release(struct ttm_mem_global *glob);
> -extern int ttm_mem_global_alloc(struct ttm_mem_global *glob, uint64_t memory,
> +int ttm_mem_global_init(struct ttm_mem_global *glob);
> +void ttm_mem_global_release(struct ttm_mem_global *glob);
> +int ttm_mem_global_alloc(struct ttm_mem_global *glob, uint64_t memory,
> +			 struct ttm_operation_ctx *ctx);
> +void ttm_mem_global_free(struct ttm_mem_global *glob, uint64_t amount);
> +int ttm_mem_global_alloc_page(struct ttm_mem_global *glob,
> +			      struct page *page, uint64_t size,
> +			      struct ttm_operation_ctx *ctx);
> +void ttm_mem_global_free_page(struct ttm_mem_global *glob,
> +			      struct page *page, uint64_t size);
> +size_t ttm_round_pot(size_t size);
> +bool ttm_check_under_lowerlimit(struct ttm_mem_global *glob, uint64_t num_pages,
>  				struct ttm_operation_ctx *ctx);
> -extern void ttm_mem_global_free(struct ttm_mem_global *glob,
> -				uint64_t amount);
> -extern int ttm_mem_global_alloc_page(struct ttm_mem_global *glob,
> -				     struct page *page, uint64_t size,
> -				     struct ttm_operation_ctx *ctx);
> -extern void ttm_mem_global_free_page(struct ttm_mem_global *glob,
> -				     struct page *page, uint64_t size);
> -extern size_t ttm_round_pot(size_t size);
> -extern bool ttm_check_under_lowerlimit(struct ttm_mem_global *glob,
> -			uint64_t num_pages, struct ttm_operation_ctx *ctx);
>  #endif
> -- 
> 2.17.1
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
diff mbox series

Patch

diff --git a/include/drm/ttm/ttm_execbuf_util.h b/include/drm/ttm/ttm_execbuf_util.h
index 5a19843bb80d..a99d7fdf2964 100644
--- a/include/drm/ttm/ttm_execbuf_util.h
+++ b/include/drm/ttm/ttm_execbuf_util.h
@@ -58,9 +58,8 @@  struct ttm_validate_buffer {
  * Undoes all buffer validation reservations for bos pointed to by
  * the list entries.
  */
-
-extern void ttm_eu_backoff_reservation(struct ww_acquire_ctx *ticket,
-				       struct list_head *list);
+void ttm_eu_backoff_reservation(struct ww_acquire_ctx *ticket,
+				struct list_head *list);
 
 /**
  * function ttm_eu_reserve_buffers
@@ -96,10 +95,9 @@  extern void ttm_eu_backoff_reservation(struct ww_acquire_ctx *ticket,
  * ttm_eu_fence_buffer_objects() when command submission is complete or
  * has failed.
  */
-
-extern int ttm_eu_reserve_buffers(struct ww_acquire_ctx *ticket,
-				  struct list_head *list, bool intr,
-				  struct list_head *dups);
+int ttm_eu_reserve_buffers(struct ww_acquire_ctx *ticket,
+			   struct list_head *list, bool intr,
+			   struct list_head *dups);
 
 /**
  * function ttm_eu_fence_buffer_objects.
@@ -113,9 +111,8 @@  extern int ttm_eu_reserve_buffers(struct ww_acquire_ctx *ticket,
  * It also unreserves all buffers, putting them on lru lists.
  *
  */
-
-extern void ttm_eu_fence_buffer_objects(struct ww_acquire_ctx *ticket,
-					struct list_head *list,
-					struct dma_fence *fence);
+void ttm_eu_fence_buffer_objects(struct ww_acquire_ctx *ticket,
+				 struct list_head *list,
+				 struct dma_fence *fence);
 
 #endif
diff --git a/include/drm/ttm/ttm_memory.h b/include/drm/ttm/ttm_memory.h
index 2d468d7c94e6..c1f167881e33 100644
--- a/include/drm/ttm/ttm_memory.h
+++ b/include/drm/ttm/ttm_memory.h
@@ -79,18 +79,17 @@  extern struct ttm_mem_global {
 #endif
 } ttm_mem_glob;
 
-extern int ttm_mem_global_init(struct ttm_mem_global *glob);
-extern void ttm_mem_global_release(struct ttm_mem_global *glob);
-extern int ttm_mem_global_alloc(struct ttm_mem_global *glob, uint64_t memory,
+int ttm_mem_global_init(struct ttm_mem_global *glob);
+void ttm_mem_global_release(struct ttm_mem_global *glob);
+int ttm_mem_global_alloc(struct ttm_mem_global *glob, uint64_t memory,
+			 struct ttm_operation_ctx *ctx);
+void ttm_mem_global_free(struct ttm_mem_global *glob, uint64_t amount);
+int ttm_mem_global_alloc_page(struct ttm_mem_global *glob,
+			      struct page *page, uint64_t size,
+			      struct ttm_operation_ctx *ctx);
+void ttm_mem_global_free_page(struct ttm_mem_global *glob,
+			      struct page *page, uint64_t size);
+size_t ttm_round_pot(size_t size);
+bool ttm_check_under_lowerlimit(struct ttm_mem_global *glob, uint64_t num_pages,
 				struct ttm_operation_ctx *ctx);
-extern void ttm_mem_global_free(struct ttm_mem_global *glob,
-				uint64_t amount);
-extern int ttm_mem_global_alloc_page(struct ttm_mem_global *glob,
-				     struct page *page, uint64_t size,
-				     struct ttm_operation_ctx *ctx);
-extern void ttm_mem_global_free_page(struct ttm_mem_global *glob,
-				     struct page *page, uint64_t size);
-extern size_t ttm_round_pot(size_t size);
-extern bool ttm_check_under_lowerlimit(struct ttm_mem_global *glob,
-			uint64_t num_pages, struct ttm_operation_ctx *ctx);
 #endif