.. | .. |
---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only |
---|
1 | 2 | /* |
---|
2 | 3 | * itmt.c: Support Intel Turbo Boost Max Technology 3.0 |
---|
3 | 4 | * |
---|
4 | 5 | * (C) Copyright 2016 Intel Corporation |
---|
5 | 6 | * Author: Tim Chen <tim.c.chen@linux.intel.com> |
---|
6 | | - * |
---|
7 | | - * This program is free software; you can redistribute it and/or |
---|
8 | | - * modify it under the terms of the GNU General Public License |
---|
9 | | - * as published by the Free Software Foundation; version 2 |
---|
10 | | - * of the License. |
---|
11 | 7 | * |
---|
12 | 8 | * On platforms supporting Intel Turbo Boost Max Technology 3.0, (ITMT), |
---|
13 | 9 | * the maximum turbo frequencies of some cores in a CPU package may be |
---|
.. | .. |
---|
43 | 39 | unsigned int __read_mostly sysctl_sched_itmt_enabled; |
---|
44 | 40 | |
---|
45 | 41 | static int sched_itmt_update_handler(struct ctl_table *table, int write, |
---|
46 | | - void __user *buffer, size_t *lenp, |
---|
47 | | - loff_t *ppos) |
---|
| 42 | + void *buffer, size_t *lenp, loff_t *ppos) |
---|
48 | 43 | { |
---|
49 | 44 | unsigned int old_sysctl; |
---|
50 | 45 | int ret; |
---|
.. | .. |
---|
69 | 64 | return ret; |
---|
70 | 65 | } |
---|
71 | 66 | |
---|
72 | | -static unsigned int zero; |
---|
73 | | -static unsigned int one = 1; |
---|
74 | 67 | static struct ctl_table itmt_kern_table[] = { |
---|
75 | 68 | { |
---|
76 | 69 | .procname = "sched_itmt_enabled", |
---|
.. | .. |
---|
78 | 71 | .maxlen = sizeof(unsigned int), |
---|
79 | 72 | .mode = 0644, |
---|
80 | 73 | .proc_handler = sched_itmt_update_handler, |
---|
81 | | - .extra1 = &zero, |
---|
82 | | - .extra2 = &one, |
---|
| 74 | + .extra1 = SYSCTL_ZERO, |
---|
| 75 | + .extra2 = SYSCTL_ONE, |
---|
83 | 76 | }, |
---|
84 | 77 | {} |
---|
85 | 78 | }; |
---|