Xinqi Bao's Git

cpu_freq: Simplify with E-notation
authorAaron Marcher <[email protected]>
Sat, 7 Jul 2018 08:56:10 +0000 (10:56 +0200)
committerAaron Marcher <[email protected]>
Sat, 7 Jul 2018 08:56:10 +0000 (10:56 +0200)
Thanks to the FRIGN

components/cpu.c

index 2c5e4dc..14c8658 100644 (file)
@@ -68,7 +68,7 @@
                        return NULL;
                }
 
-               return fmt_human(freq * 1000 * 1000, 1000);
+               return fmt_human(freq * 1E6, 1000);
        }
 
        const char *