Module Name: src
Committed By: maxv
Date: Wed Mar 28 19:47:54 UTC 2018
Modified Files:
src/sys/arch/x86/x86: cpu_ucode.c
Log Message:
Add 'break', otherwise we're not gonna go very far. While here use a less
error-prone syntax.
To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/x86/x86/cpu_ucode.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/x86/x86/cpu_ucode.c
diff -u src/sys/arch/x86/x86/cpu_ucode.c:1.8 src/sys/arch/x86/x86/cpu_ucode.c:1.9
--- src/sys/arch/x86/x86/cpu_ucode.c:1.8 Sun Mar 18 00:17:18 2018
+++ src/sys/arch/x86/x86/cpu_ucode.c Wed Mar 28 19:47:54 2018
@@ -1,4 +1,4 @@
-/* $NetBSD: cpu_ucode.c,v 1.8 2018/03/18 00:17:18 christos Exp $ */
+/* $NetBSD: cpu_ucode.c,v 1.9 2018/03/28 19:47:54 maxv Exp $ */
/*
* Copyright (c) 2012 The NetBSD Foundation, Inc.
* All rights reserved.
@@ -29,7 +29,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cpu_ucode.c,v 1.8 2018/03/18 00:17:18 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cpu_ucode.c,v 1.9 2018/03/28 19:47:54 maxv Exp $");
#include "opt_cpu_ucode.h"
#include "opt_xen.h"
@@ -67,9 +67,13 @@ cpu_ucode_get_version(struct cpu_ucode_v
switch (cpu_vendor) {
case CPUVENDOR_AMD:
- error = cpu_ucode_amd_get_version(data, &v, l = sizeof(v.a));
+ l = sizeof(v.a);
+ error = cpu_ucode_amd_get_version(data, &v, l);
+ break;
case CPUVENDOR_INTEL:
- error = cpu_ucode_intel_get_version(data, &v, l = sizeof(v.i));
+ l = sizeof(v.i);
+ error = cpu_ucode_intel_get_version(data, &v, l);
+ break;
default:
return EOPNOTSUPP;
}