diff options
Diffstat (limited to 'arch/i386/kernel/msr.c')
-rw-r--r-- | arch/i386/kernel/msr.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/arch/i386/kernel/msr.c b/arch/i386/kernel/msr.c index a773f776c9ea..1d1a56cae340 100644 --- a/arch/i386/kernel/msr.c +++ b/arch/i386/kernel/msr.c | |||
@@ -195,7 +195,6 @@ static ssize_t msr_write(struct file *file, const char __user *buf, | |||
195 | { | 195 | { |
196 | const u32 __user *tmp = (const u32 __user *)buf; | 196 | const u32 __user *tmp = (const u32 __user *)buf; |
197 | u32 data[2]; | 197 | u32 data[2]; |
198 | size_t rv; | ||
199 | u32 reg = *ppos; | 198 | u32 reg = *ppos; |
200 | int cpu = iminor(file->f_dentry->d_inode); | 199 | int cpu = iminor(file->f_dentry->d_inode); |
201 | int err; | 200 | int err; |
@@ -203,7 +202,7 @@ static ssize_t msr_write(struct file *file, const char __user *buf, | |||
203 | if (count % 8) | 202 | if (count % 8) |
204 | return -EINVAL; /* Invalid chunk size */ | 203 | return -EINVAL; /* Invalid chunk size */ |
205 | 204 | ||
206 | for (rv = 0; count; count -= 8) { | 205 | for (; count; count -= 8) { |
207 | if (copy_from_user(&data, tmp, 8)) | 206 | if (copy_from_user(&data, tmp, 8)) |
208 | return -EFAULT; | 207 | return -EFAULT; |
209 | err = do_wrmsr(cpu, reg, data[0], data[1]); | 208 | err = do_wrmsr(cpu, reg, data[0], data[1]); |
@@ -250,7 +249,6 @@ static int msr_device_create(int i) | |||
250 | return err; | 249 | return err; |
251 | } | 250 | } |
252 | 251 | ||
253 | #ifdef CONFIG_HOTPLUG_CPU | ||
254 | static int msr_class_cpu_callback(struct notifier_block *nfb, | 252 | static int msr_class_cpu_callback(struct notifier_block *nfb, |
255 | unsigned long action, void *hcpu) | 253 | unsigned long action, void *hcpu) |
256 | { | 254 | { |
@@ -271,7 +269,6 @@ static struct notifier_block __cpuinitdata msr_class_cpu_notifier = | |||
271 | { | 269 | { |
272 | .notifier_call = msr_class_cpu_callback, | 270 | .notifier_call = msr_class_cpu_callback, |
273 | }; | 271 | }; |
274 | #endif | ||
275 | 272 | ||
276 | static int __init msr_init(void) | 273 | static int __init msr_init(void) |
277 | { | 274 | { |