drm/nouveau/volt: Add temperature parameter to nvkm_volt_map
authorKarol Herbst <karolherbst@gmail.com>
Tue, 12 Jul 2016 19:36:08 +0000 (21:36 +0200)
committerBen Skeggs <bskeggs@redhat.com>
Wed, 12 Oct 2016 07:29:23 +0000 (17:29 +1000)
commit8d08c264d2b26c7b9c10790f95464b21e28dc30d
tree5095cd2be936a2d23ad820f25d5420fc03c5e76d
parent61a8b84f1cff6051f51b30ad96417dd948dc72da
drm/nouveau/volt: Add temperature parameter to nvkm_volt_map

The voltage entries actually may map to a different voltage depending on
the current temperature.

v2: Only read the temperature when actually needed.
v5: Be smarter about using max().
    Don't read the temperature anymore.

Signed-off-by: Karol Herbst <karolherbst@gmail.com>
Reviewed-by: Martin Peres <martin.peres@free.fr>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
drivers/gpu/drm/nouveau/include/nvkm/subdev/volt.h
drivers/gpu/drm/nouveau/nvkm/subdev/clk/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/volt/base.c