]> git.ozlabs.org Git - ccan/blobdiff - ccan/cpuid/_info
cpuid: fix example compilation
[ccan] / ccan / cpuid / _info
index 1603b4bec40ad9076d4ee6fe0ce52499e6c48609..79a98c0a236dfc2ad98010a01afb4bcb9726f74c 100644 (file)
@@ -8,12 +8,13 @@
  *
  * Example:
  * #include <ccan/cpuid/cpuid.h>
+ * #include <stdio.h>
  *
- * int main()
+ * int main(void)
  * {
- *     int highest;
- *     cpuid(CPU_HIGHEST_EXTENDED_FUNCTION_SUPPORTED, &highest);
- *     printf ("Highest extended function supported: %d\n", highest);
+ *     uint32_t highest;
+ *     cpuid(CPUID_HIGHEST_EXTENDED_FUNCTION_SUPPORTED, &highest);
+ *     printf("Highest extended function supported: %d\n", highest);
  *
  *      return 0;
  * }