File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ config XTENSA
11
11
select VIRT_TO_BUS
12
12
select GENERIC_IRQ_SHOW
13
13
select GENERIC_CPU_DEVICES
14
+ select GENERIC_SCHED_CLOCK
14
15
select MODULES_USE_ELF_RELA
15
16
select GENERIC_PCI_IOMAP
16
17
select ARCH_WANT_IPC_PARSE_VERSION
Original file line number Diff line number Diff line change 24
24
#include <linux/profile.h>
25
25
#include <linux/delay.h>
26
26
#include <linux/irqdomain.h>
27
+ #include <linux/sched_clock.h>
27
28
28
29
#include <asm/timex.h>
29
30
#include <asm/platform.h>
@@ -37,6 +38,11 @@ static cycle_t ccount_read(struct clocksource *cs)
37
38
return (cycle_t )get_ccount ();
38
39
}
39
40
41
+ static u32 notrace ccount_sched_clock_read (void )
42
+ {
43
+ return get_ccount ();
44
+ }
45
+
40
46
static struct clocksource ccount_clocksource = {
41
47
.name = "ccount" ,
42
48
.rating = 200 ,
@@ -134,6 +140,8 @@ void __init time_init(void)
134
140
0xffffffff );
135
141
setup_irq (ccount_timer .evt .irq , & timer_irqaction );
136
142
ccount_timer .irq_enabled = 1 ;
143
+
144
+ setup_sched_clock (ccount_sched_clock_read , 32 , ccount_freq );
137
145
}
138
146
139
147
/*
You can’t perform that action at this time.
0 commit comments