Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'modules-6.2-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux

Pull module fix from Luis Chamberlain:
"Just one fix for modules by Nick"

* tag 'modules-6.2-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux:
kallsyms: Fix scheduling with interrupts disabled in self-test

+6 -15
+6 -15
kernel/kallsyms_selftest.c
··· 157 157 static int lookup_name(void *data, const char *name, struct module *mod, unsigned long addr) 158 158 { 159 159 u64 t0, t1, t; 160 - unsigned long flags; 161 160 struct test_stat *stat = (struct test_stat *)data; 162 161 163 - local_irq_save(flags); 164 - t0 = sched_clock(); 162 + t0 = ktime_get_ns(); 165 163 (void)kallsyms_lookup_name(name); 166 - t1 = sched_clock(); 167 - local_irq_restore(flags); 164 + t1 = ktime_get_ns(); 168 165 169 166 t = t1 - t0; 170 167 if (t < stat->min) ··· 231 234 static void test_perf_kallsyms_on_each_symbol(void) 232 235 { 233 236 u64 t0, t1; 234 - unsigned long flags; 235 237 struct test_stat stat; 236 238 237 239 memset(&stat, 0, sizeof(stat)); 238 240 stat.max = INT_MAX; 239 241 stat.name = stub_name; 240 242 stat.perf = 1; 241 - local_irq_save(flags); 242 - t0 = sched_clock(); 243 + t0 = ktime_get_ns(); 243 244 kallsyms_on_each_symbol(find_symbol, &stat); 244 - t1 = sched_clock(); 245 - local_irq_restore(flags); 245 + t1 = ktime_get_ns(); 246 246 pr_info("kallsyms_on_each_symbol() traverse all: %lld ns\n", t1 - t0); 247 247 } 248 248 ··· 264 270 static void test_perf_kallsyms_on_each_match_symbol(void) 265 271 { 266 272 u64 t0, t1; 267 - unsigned long flags; 268 273 struct test_stat stat; 269 274 270 275 memset(&stat, 0, sizeof(stat)); 271 276 stat.max = INT_MAX; 272 277 stat.name = stub_name; 273 - local_irq_save(flags); 274 - t0 = sched_clock(); 278 + t0 = ktime_get_ns(); 275 279 kallsyms_on_each_match_symbol(match_symbol, stat.name, &stat); 276 - t1 = sched_clock(); 277 - local_irq_restore(flags); 280 + t1 = ktime_get_ns(); 278 281 pr_info("kallsyms_on_each_match_symbol() traverse all: %lld ns\n", t1 - t0); 279 282 } 280 283