irqbalance/0001-optimize-getting-cpu-number.patch
Tao Liu 185ff9cc5d Release 1.9.2-1
Rebase to latest upstream commit (184c95029e)
Resolves:rhbz2166859
Resolves:rhbz2173858

Signed-off-by: Tao Liu <ltao@redhat.com>
2023-05-18 19:08:48 +08:00

27 lines
661 B
Diff

From 7c18ffc9d0187d4d1983a53bb166aacad2a87dcc Mon Sep 17 00:00:00 2001
From: qyu <chinyu0704@icloud.com>
Date: Mon, 7 Nov 2022 17:01:38 +0800
Subject: [PATCH 01/13] optimize getting cpu number
cpu number has already been parsed and saved in cpunr, remove redudant strtoul().
---
cputree.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/cputree.c b/cputree.c
index eb1981e..d66be55 100644
--- a/cputree.c
+++ b/cputree.c
@@ -315,7 +315,7 @@ static void do_one_cpu(char *path)
cpu->obj_type = OBJ_TYPE_CPU;
- cpu->number = strtoul(&path[27], NULL, 10);
+ cpu->number = cpunr;
cpu_set(cpu->number, cpu_online_map);
--
2.33.1