Skip to content

Commit f2b76a1

Browse files
Ben Skeggsairlied
authored andcommitted
drm/nouveau/therm/tu102-: prepare for GSP-RM
- disable THERM completely when GSP-RM detected Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Signed-off-by: Dave Airlie <airlied@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/20230918202149.4343-21-skeggsb@gmail.com
1 parent fd7d598 commit f2b76a1

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

  • drivers/gpu/drm/nouveau/nvkm/subdev/therm

drivers/gpu/drm/nouveau/nvkm/subdev/therm/gp100.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@
2323
*/
2424
#include "priv.h"
2525

26+
#include <subdev/gsp.h>
27+
2628
static int
2729
gp100_temp_get(struct nvkm_therm *therm)
2830
{
@@ -52,5 +54,8 @@ int
5254
gp100_therm_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst,
5355
struct nvkm_therm **ptherm)
5456
{
57+
if (nvkm_gsp_rm(device->gsp))
58+
return -ENODEV;
59+
5560
return nvkm_therm_new_(&gp100_therm, device, type, inst, ptherm);
5661
}

0 commit comments

Comments
 (0)