summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/nouveau/nouveau_perf.c
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2012-01-24 06:59:07 +0100
committerBen Skeggs <bskeggs@redhat.com>2012-03-13 08:09:04 +0100
commit8d7bb400638906075c38cb07891993cf95076aa7 (patch)
tree53f6f6be77f239f3a46da76825eb8c484c31c068 /drivers/gpu/drm/nouveau/nouveau_perf.c
parentdrm/nouveau/pm: fix dll off -> dll on transitions (diff)
downloadlinux-8d7bb400638906075c38cb07891993cf95076aa7.tar.xz
linux-8d7bb400638906075c38cb07891993cf95076aa7.zip
drm/nouveau/pm: rework to allow selecting separate profiles for ac/battery
Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Signed-off-by: Martin Peres <martin.peres@labri.fr>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nouveau_perf.c')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_perf.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_perf.c b/drivers/gpu/drm/nouveau/nouveau_perf.c
index cc8beb8e2f06..e64901509f90 100644
--- a/drivers/gpu/drm/nouveau/nouveau_perf.c
+++ b/drivers/gpu/drm/nouveau/nouveau_perf.c
@@ -394,6 +394,13 @@ nouveau_perf_init(struct drm_device *dev)
snprintf(perflvl->name, sizeof(perflvl->name),
"performance_level_%d", i);
perflvl->id = i;
+
+ snprintf(perflvl->profile.name, sizeof(perflvl->profile.name),
+ "%d", perflvl->id);
+ perflvl->profile.func = &nouveau_pm_static_profile_func;
+ list_add_tail(&perflvl->profile.head, &pm->profiles);
+
+
pm->nr_perflvl++;
}
}