Added get_cpu_freq function to read out the CPU frequency