Skip to contentSkip to conversation

libxl: fix typos in libxl_cpuid_parse_config

PATCH In review Olaf Hering 2 participants 2 messages May 31, 2012 – Jun 1, 2012

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 libxl: fix typos in libxl_cpuid_parse_config

# HG changeset patch
# User Olaf Hering <[email protected]>
# Date 1338501314 -7200
# Node ID a836c330fd736b751f5e26b5d9d816d8fa59d28b # Parent 4dad9647a0963a2665ccf055492e740c2b399517
libxl: fix typos in libxl_cpuid_parse_config

Fix typo in comment.
Fix cpuid_flags array init, use correct number of arguments for empty array entry.

tools/libxl/libxl_cpuid.c +2 -2
diff -r 4dad9647a096 -r a836c330fd73 tools/libxl/libxl_cpuid.c
@@ -185,7 +185,7 @@ int libxl_cpuid_parse_config(libxl_cpuid
         {"svm_decode",   0x8000000a, NA, CPUID_REG_EDX,  7,  1},
         {"svm_pausefilt",0x8000000a, NA, CPUID_REG_EDX, 10,  1},
 
-        {NULL, 0, CPUID_REG_INV, 0, 0}
+        {NULL, 0, NA, CPUID_REG_INV, 0, 0}
     };
 #undef NA
     char *sep, *val, *endptr;
@@ -216,7 +216,7 @@ int libxl_cpuid_parse_config(libxl_cpuid
     num = strtoull(val, &endptr, 0);
     flags[flag->length] = 0;
     if (endptr != val) {
-        /* is this was a valid number, write the binary form into the string */
+        /* if this was a valid number, write the binary form into the string */
         for (i = 0; i < flag->length; i++) {
             flags[flag->length - 1 - i] = "01"[!!(num & (1 << i))];
         }
#1 lore raw
Quoted 7 lines · Olaf Hering

# HG changeset patch
# User Olaf Hering <[email protected]>
# Date 1338501314 -7200
# Node ID a836c330fd736b751f5e26b5d9d816d8fa59d28b # Parent 4dad9647a0963a2665ccf055492e740c2b399517
libxl: fix typos in libxl_cpuid_parse_config

Quoted 5 lines

Fix typo in comment.
Fix cpuid_flags array init, use correct number of arguments for empty array entry.

Committed, thanks.