cpufreq: filter thermald

thermald clobbers the maximum frequency, so filter the values it reads
and writes to keep it behaving properly.