diff options
author | Daniel Vetter <daniel.vetter@ffwll.ch> | 2017-10-03 12:09:16 +0300 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2017-10-03 12:09:16 +0300 |
commit | 0d3c24e936feefeca854073ccb40613cd6eba9a9 (patch) | |
tree | 1f675397b924846740b0931b066ddce6f3d7eb3d /drivers/gpu/drm/nouveau/nvkm/subdev/pmu/gp102.c | |
parent | 1af0838de60e723cb02253ecc9b555c30f8f6a6f (diff) | |
parent | ebec44a2456fbe5fe18aae88f6010f6878f0cb4a (diff) | |
download | linux-0d3c24e936feefeca854073ccb40613cd6eba9a9.tar.xz |
Merge airlied/drm-next into drm-misc-next
Just catching up with upstream.
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nvkm/subdev/pmu/gp102.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/subdev/pmu/gp102.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/pmu/gp102.c b/drivers/gpu/drm/nouveau/nvkm/subdev/pmu/gp102.c index f017352206c9..98c7a2a8afc4 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/pmu/gp102.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/pmu/gp102.c @@ -31,8 +31,15 @@ gp102_pmu_reset(struct nvkm_pmu *pmu) nvkm_mask(device, 0x10a3c0, 0x00000001, 0x00000000); } +static bool +gp102_pmu_enabled(struct nvkm_pmu *pmu) +{ + return !(nvkm_rd32(pmu->subdev.device, 0x10a3c0) & 0x00000001); +} + static const struct nvkm_pmu_func gp102_pmu = { + .enabled = gp102_pmu_enabled, .reset = gp102_pmu_reset, }; |