[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20241012042828.471614-2-visitorckw@gmail.com>
Date: Sat, 12 Oct 2024 12:28:26 +0800
From: Kuan-Wei Chiu <visitorckw@...il.com>
To: akpm@...ux-foundation.org,
acme@...nel.org
Cc: peterz@...radead.org,
mingo@...hat.com,
namhyung@...nel.org,
mark.rutland@....com,
alexander.shishkin@...ux.intel.com,
jolsa@...nel.org,
irogers@...gle.com,
adrian.hunter@...el.com,
kan.liang@...ux.intel.com,
jserv@...s.ncku.edu.tw,
linux-kernel@...r.kernel.org,
linux-perf-users@...r.kernel.org,
Kuan-Wei Chiu <visitorckw@...il.com>
Subject: [PATCH 1/3] lib/list_sort: Remove unnecessary header includes
After commit 043b3f7b6388 ("lib/list_sort: simplify and remove
MAX_LIST_LENGTH_BITS"), list_sort.c no longer uses ARRAY_SIZE() (which
required kernel.h and bug.h for BUILD_BUG_ON_ZERO via __must_be_array)
or memset() (which required string.h). As these headers are no longer
needed, removes them.
There are no changes to the generated code, as confirmed by
'objdump -d'. Additionally, 'wc -l' shows that the size of
lib/.list_sort.o.cmd is reduced from 259 lines to 101 lines.
Signed-off-by: Kuan-Wei Chiu <visitorckw@...il.com>
---
lib/list_sort.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/lib/list_sort.c b/lib/list_sort.c
index 0fb59e92ca2d..8d3f623536fe 100644
--- a/lib/list_sort.c
+++ b/lib/list_sort.c
@@ -1,9 +1,6 @@
// SPDX-License-Identifier: GPL-2.0
-#include <linux/kernel.h>
-#include <linux/bug.h>
#include <linux/compiler.h>
#include <linux/export.h>
-#include <linux/string.h>
#include <linux/list_sort.h>
#include <linux/list.h>
--
2.34.1
Powered by blists - more mailing lists