drm/nouveau/hwmon: return EINVAL if the GPU is powered down for sensors reads
authorKarol Herbst <kherbst@redhat.com>
Tue, 18 Jun 2019 11:01:33 +0000 (13:01 +0200)
committerBen Skeggs <bskeggs@redhat.com>
Fri, 19 Jul 2019 06:26:51 +0000 (16:26 +1000)
commit68bf8b577977a2804af82ffe03ce25d952f82fd2
tree3d2d9863b5fcb0a2f11556f007e18878c26ec600
parentb0f84a84fff180718995b1269da2988e5b28be42
drm/nouveau/hwmon: return EINVAL if the GPU is powered down for sensors reads

fixes bogus values userspace gets from hwmon while the GPU is powered down

Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Rhys Kidd <rhyskidd@gmail.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
drivers/gpu/drm/nouveau/nouveau_hwmon.c