thermal: devfreq_cooling: refactor code and add get_voltage function

Move the code which gets the voltage for a given frequency.
This code will be resused in few places.

Acked-by: Javi Merino <[email protected]>
Signed-off-by: Lukasz Luba <[email protected]>
1 file changed