From 9dfbed6fa33dfcd69afa3383f20c3973215e8000 Mon Sep 17 00:00:00 2001 From: Mr NeilBrown Date: Wed, 10 Jun 2020 17:40:00 -0400 Subject: [PATCH] LU-9859 libcfs: remove cfs_trace_refill_stack() The function cfs_trace_refill_stack() is not used anywhere so remove it. Test-Parameters: trivial Change-Id: Iade031c15a9bde091320c2fd2c66c1cd2951f649 Signed-off-by: Mr NeilBrown Reviewed-on: https://review.whamcloud.com/38913 Tested-by: jenkins Tested-by: Maloo Reviewed-by: Jian Yu Reviewed-by: Andreas Dilger --- libcfs/libcfs/tracefile.c | 21 --------------------- libcfs/libcfs/tracefile.h | 4 ---- 2 files changed, 25 deletions(-) diff --git a/libcfs/libcfs/tracefile.c b/libcfs/libcfs/tracefile.c index 06b925a..1a3a4e5 100644 --- a/libcfs/libcfs/tracefile.c +++ b/libcfs/libcfs/tracefile.c @@ -263,27 +263,6 @@ static void cfs_tage_to_tail(struct cfs_trace_page *tage, list_move_tail(&tage->linkage, queue); } -int cfs_trace_refill_stock(struct cfs_trace_cpu_data *tcd, gfp_t gfp, - struct list_head *stock) -{ - int i; - - /* - * XXX nikita: do NOT call portals_debug_msg() (CDEBUG/ENTRY/EXIT) - * from here: this will lead to infinite recursion. - */ - - for (i = 0; i + tcd->tcd_cur_stock_pages < TCD_STOCK_PAGES ; ++ i) { - struct cfs_trace_page *tage; - - tage = cfs_tage_alloc(gfp); - if (tage == NULL) - break; - list_add_tail(&tage->linkage, stock); - } - return i; -} - /* return a page that has 'len' bytes left at the end */ static struct cfs_trace_page * cfs_trace_get_tage_try(struct cfs_trace_cpu_data *tcd, unsigned long len) diff --git a/libcfs/libcfs/tracefile.h b/libcfs/libcfs/tracefile.h index fe51212..3d838cf 100644 --- a/libcfs/libcfs/tracefile.h +++ b/libcfs/libcfs/tracefile.h @@ -245,10 +245,6 @@ static inline char *cfs_trace_get_console_buffer(void) return cfs_trace_console_buffers[i][j]; } -int cfs_trace_refill_stock(struct cfs_trace_cpu_data *tcd, gfp_t gfp, - struct list_head *stock); - - int cfs_tcd_owns_tage(struct cfs_trace_cpu_data *tcd, struct cfs_trace_page *tage); -- 1.8.3.1