mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH for-next] drm/ttm: make ttm_swap_ops static
@ 2024-09-07  3:36 Min-Hua Chen
  2024-09-07 17:34 ` Matthew Brost
  0 siblings, 1 reply; 2+ messages in thread
From: Min-Hua Chen @ 2024-09-07  3:36 UTC (permalink / raw)
  To: Christian Koenig, Huang Rui, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, David Airlie, Simona Vetter,
	Thomas Hellström, Matthew Brost
  Cc: Min-Hua Chen, dri-devel, linux-kernel

make ttm_swap_ops static to fix the following sparse warning:

drivers/gpu/drm/ttm/ttm_bo.c:1142:31: sparse: warning: symbol
'ttm_swap_ops' was not declared. Should it be static?

Fixes: 10efe34dae79 ("drm/ttm: Use the LRU walker helper for swapping")
Signed-off-by: Min-Hua Chen <minhuadotchen@gmail.com>
---
 drivers/gpu/drm/ttm/ttm_bo.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c
index 320592435252..1aab30767e41 100644
--- a/drivers/gpu/drm/ttm/ttm_bo.c
+++ b/drivers/gpu/drm/ttm/ttm_bo.c
@@ -1139,7 +1139,7 @@ ttm_bo_swapout_cb(struct ttm_lru_walk *walk, struct ttm_buffer_object *bo)
 	return ret;
 }
 
-const struct ttm_lru_walk_ops ttm_swap_ops = {
+static const struct ttm_lru_walk_ops ttm_swap_ops = {
 	.process_bo = ttm_bo_swapout_cb,
 };
 
-- 
2.43.0


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-09-07 17:36 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-09-07  3:36 [PATCH for-next] drm/ttm: make ttm_swap_ops static Min-Hua Chen
2024-09-07 17:34 ` Matthew Brost

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®