drm/radeon/kms: add trivial debugging for voltage
authorRafał Miłecki <zajec5@gmail.com>
Mon, 7 Jun 2010 22:25:21 +0000 (18:25 -0400)
committerDave Airlie <airlied@redhat.com>
Mon, 7 Jun 2010 23:36:09 +0000 (09:36 +1000)
agd5f: rebased

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/radeon/evergreen.c
drivers/gpu/drm/radeon/r600.c
drivers/gpu/drm/radeon/radeon_pm.c
drivers/gpu/drm/radeon/rv770.c

index b2b7c11e447f0c96e954538355cabe9027383ba5..4b6623df3b964fde76723aa8fb0f69bbdaef30a6 100644 (file)
@@ -50,6 +50,7 @@ void evergreen_pm_misc(struct radeon_device *rdev)
                if (voltage->voltage != rdev->pm.current_vddc) {
                        radeon_atom_set_voltage(rdev, voltage->voltage);
                        rdev->pm.current_vddc = voltage->voltage;
+                       DRM_DEBUG("Setting: v: %d\n", voltage->voltage);
                }
        }
 }
index 7b5539100114ca3523533cbfdf18666e2122b394..0e91871f45be0a213a9a67ff25c18fd0244088e8 100644 (file)
@@ -566,6 +566,7 @@ void r600_pm_misc(struct radeon_device *rdev)
                if (voltage->voltage != rdev->pm.current_vddc) {
                        radeon_atom_set_voltage(rdev, voltage->voltage);
                        rdev->pm.current_vddc = voltage->voltage;
+                       DRM_DEBUG("Setting: v: %d\n", voltage->voltage);
                }
        }
 }
index f2e1c60afda5cbdf9683a6aa8b5a5d23449850e5..19fb3652c7bd1d7db204351fa3aecd9a097c0758 100644 (file)
@@ -699,6 +699,8 @@ static int radeon_debugfs_pm_info(struct seq_file *m, void *data)
        seq_printf(m, "default memory clock: %u0 kHz\n", rdev->clock.default_mclk);
        if (rdev->asic->get_memory_clock)
                seq_printf(m, "current memory clock: %u0 kHz\n", radeon_get_memory_clock(rdev));
+       if (rdev->pm.current_vddc)
+               seq_printf(m, "voltage: %u mV\n", rdev->pm.current_vddc);
        if (rdev->asic->get_pcie_lanes)
                seq_printf(m, "PCIE lanes: %d\n", radeon_get_pcie_lanes(rdev));
 
index e8fb8b66e00225579fa342497842729690641908..cec536c222c5314e696b1ca3acb6789dfdc8924e 100644 (file)
@@ -53,6 +53,7 @@ void rv770_pm_misc(struct radeon_device *rdev)
                if (voltage->voltage != rdev->pm.current_vddc) {
                        radeon_atom_set_voltage(rdev, voltage->voltage);
                        rdev->pm.current_vddc = voltage->voltage;
+                       DRM_DEBUG("Setting: v: %d\n", voltage->voltage);
                }
        }
 }