diff options
author | dim <dim@FreeBSD.org> | 2011-12-31 12:37:07 +0000 |
---|---|---|
committer | dim <dim@FreeBSD.org> | 2011-12-31 12:37:07 +0000 |
commit | 21c9c8f9bc530abe04f437b584b590b8ad325671 (patch) | |
tree | f5242e41c099865d0f7902313276015fc80603cc | |
parent | f6346713079680d80245405ac41d4f6362f443ac (diff) | |
download | FreeBSD-src-21c9c8f9bc530abe04f437b584b590b8ad325671.zip FreeBSD-src-21c9c8f9bc530abe04f437b584b590b8ad325671.tar.gz |
In sys/dev/hwpmc/hwpmc_amd.c, fix a clang warning about invalid enum
conversions.
Reviewed by: jkoshy
MFC after: 1 week
-rw-r--r-- | sys/dev/hwpmc/hwpmc_amd.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/sys/dev/hwpmc/hwpmc_amd.c b/sys/dev/hwpmc/hwpmc_amd.c index 268904b..9ffa62f 100644 --- a/sys/dev/hwpmc/hwpmc_amd.c +++ b/sys/dev/hwpmc/hwpmc_amd.c @@ -889,7 +889,6 @@ pmc_amd_initialize(void) * field returned by CPUID for instruction family >= 6. */ - class = cputype = -1; name = NULL; switch (cpu_id & 0xF00) { #if defined(__i386__) @@ -906,9 +905,8 @@ pmc_amd_initialize(void) class = PMC_CLASS_K8; name = "K8"; break; - } - if ((int) cputype == -1) { + default: (void) printf("pmc: Unknown AMD CPU.\n"); return NULL; } |