summaryrefslogtreecommitdiffstats
path: root/util/msrtool/geodegx2.c
diff options
context:
space:
mode:
authorAnton Kochkov <anton.kochkov@gmail.com>2012-07-21 07:29:48 +0400
committerPeter Stuge <peter@stuge.se>2012-07-21 17:35:46 +0200
commit59b36f1026090ea9b39ca2bc8386c8addf1b03d6 (patch)
tree544cf2d39f7bd51c7004aa0a8e133def13e52a0e /util/msrtool/geodegx2.c
parentc7fc4422a0039b6fd6c44bd98050ec648ee0312a (diff)
downloadcoreboot-59b36f1026090ea9b39ca2bc8386c8addf1b03d6.tar.gz
coreboot-59b36f1026090ea9b39ca2bc8386c8addf1b03d6.tar.bz2
coreboot-59b36f1026090ea9b39ca2bc8386c8addf1b03d6.zip
msrtool: Factor out cpuid() from target probe functions into main()
Almost all probe functions called cpuid(). Those calls are replaced by a single cpuid() call in main() and a new parameter to the target probe functions with the cpuid() result. The vendor_t and struct cpuid_t definitions are moved closer to the top of msrtool.h and the vendor_t enum is reformatted to simplify addition of further values. Change-Id: Icd615636207499cfa46b8b99bf819ef8ca2d97c0 Signed-off-by: Anton Kochkov <anton.kochkov@gmail.com> Signed-off-by: Peter Stuge <peter@stuge.se> Reviewed-on: http://review.coreboot.org/1259 Tested-by: build bot (Jenkins)
Diffstat (limited to 'util/msrtool/geodegx2.c')
-rw-r--r--util/msrtool/geodegx2.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/util/msrtool/geodegx2.c b/util/msrtool/geodegx2.c
index ae5d887c2d12..29d1a13c8fd0 100644
--- a/util/msrtool/geodegx2.c
+++ b/util/msrtool/geodegx2.c
@@ -20,8 +20,7 @@
#include "msrtool.h"
-int geodegx2_probe(const struct targetdef *target) {
- struct cpuid_t *id = cpuid();
+int geodegx2_probe(const struct targetdef *target, const struct cpuid_t *id) {
return 5 == id->family && 5 == id->model;
}