]>
Commit | Line | Data |
---|---|---|
59d5af67 | 1 | From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 |
321d628a FG |
2 | From: Kees Cook <keescook@chromium.org> |
3 | Date: Mon, 16 Oct 2017 16:22:31 -0700 | |
59d5af67 | 4 | Subject: [PATCH] x86/platform/UV: Convert timers to use timer_setup() |
321d628a FG |
5 | MIME-Version: 1.0 |
6 | Content-Type: text/plain; charset=UTF-8 | |
7 | Content-Transfer-Encoding: 8bit | |
8 | ||
9 | CVE-2017-5754 | |
10 | ||
11 | In preparation for unconditionally passing the struct timer_list pointer to | |
12 | all timer callbacks, switch to using the new timer_setup() and from_timer() | |
13 | to pass the timer pointer explicitly. | |
14 | ||
15 | Signed-off-by: Kees Cook <keescook@chromium.org> | |
16 | Signed-off-by: Thomas Gleixner <tglx@linutronix.de> | |
17 | Cc: Dimitri Sivanich <sivanich@hpe.com> | |
18 | Cc: Russ Anderson <rja@hpe.com> | |
19 | Cc: Mike Travis <mike.travis@hpe.com> | |
20 | Link: https://lkml.kernel.org/r/20171016232231.GA100493@beast | |
21 | ||
22 | (cherry picked from commit 376f3bcebdc999cc737d9052109cc33b573b3a8b) | |
23 | Signed-off-by: Andy Whitcroft <apw@canonical.com> | |
24 | Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com> | |
25 | (cherry picked from commit 869cbd2b31024e70d574527b8c6851bf2ebbe483) | |
26 | Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com> | |
27 | --- | |
28 | arch/x86/kernel/apic/x2apic_uv_x.c | 5 ++--- | |
29 | 1 file changed, 2 insertions(+), 3 deletions(-) | |
30 | ||
31 | diff --git a/arch/x86/kernel/apic/x2apic_uv_x.c b/arch/x86/kernel/apic/x2apic_uv_x.c | |
32 | index 0d57bb9079c9..c0b694810ff4 100644 | |
33 | --- a/arch/x86/kernel/apic/x2apic_uv_x.c | |
34 | +++ b/arch/x86/kernel/apic/x2apic_uv_x.c | |
35 | @@ -920,9 +920,8 @@ static __init void uv_rtc_init(void) | |
36 | /* | |
37 | * percpu heartbeat timer | |
38 | */ | |
39 | -static void uv_heartbeat(unsigned long ignored) | |
40 | +static void uv_heartbeat(struct timer_list *timer) | |
41 | { | |
42 | - struct timer_list *timer = &uv_scir_info->timer; | |
43 | unsigned char bits = uv_scir_info->state; | |
44 | ||
45 | /* Flip heartbeat bit: */ | |
46 | @@ -947,7 +946,7 @@ static int uv_heartbeat_enable(unsigned int cpu) | |
47 | struct timer_list *timer = &uv_cpu_scir_info(cpu)->timer; | |
48 | ||
49 | uv_set_cpu_scir_bits(cpu, SCIR_CPU_HEARTBEAT|SCIR_CPU_ACTIVITY); | |
50 | - setup_pinned_timer(timer, uv_heartbeat, cpu); | |
51 | + timer_setup(timer, uv_heartbeat, TIMER_PINNED); | |
52 | timer->expires = jiffies + SCIR_CPU_HB_INTERVAL; | |
53 | add_timer_on(timer, cpu); | |
54 | uv_cpu_scir_info(cpu)->enabled = 1; | |
55 | -- | |
56 | 2.14.2 | |
57 |