Patch "drm/radeon/dpm: handle bapm on trinity" has been added to the 3.11-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    drm/radeon/dpm: handle bapm on trinity

to the 3.11-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     drm-radeon-dpm-handle-bapm-on-trinity.patch
and it can be found in the queue-3.11 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.


>From ef4e03658420bbf91365647615460668c2510e79 Mon Sep 17 00:00:00 2001
From: Alex Deucher <alexander.deucher@xxxxxxx>
Date: Mon, 9 Sep 2013 18:56:50 -0400
Subject: drm/radeon/dpm: handle bapm on trinity

From: Alex Deucher <alexander.deucher@xxxxxxx>

commit ef4e03658420bbf91365647615460668c2510e79 upstream.

bapm is a power management feature for handling the
power budget between the CPU and GPU on APUs.  This
patch adds support for enabling or disabling it.
For now disable it by default.  Enabling it properly
requires quite a bit more work and will be addressed
in a separate patch.

This patch fixes hangs on boot on certain trinity
laptops when the system is on battery power.

Signed-off-by: Alex Deucher <alexander.deucher@xxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>

---
 drivers/gpu/drm/radeon/ppsmc.h       |    2 ++
 drivers/gpu/drm/radeon/trinity_dpm.c |    2 ++
 drivers/gpu/drm/radeon/trinity_dpm.h |    1 +
 drivers/gpu/drm/radeon/trinity_smc.c |    8 ++++++++
 4 files changed, 13 insertions(+)

--- a/drivers/gpu/drm/radeon/ppsmc.h
+++ b/drivers/gpu/drm/radeon/ppsmc.h
@@ -106,6 +106,8 @@ typedef uint8_t PPSMC_Result;
 #define PPSMC_MSG_DPM_N_LevelsDisabled      ((uint32_t) 0x112)
 #define PPSMC_MSG_DCE_RemoveVoltageAdjustment   ((uint32_t) 0x11d)
 #define PPSMC_MSG_DCE_AllowVoltageAdjustment    ((uint32_t) 0x11e)
+#define PPSMC_MSG_EnableBAPM                ((uint32_t) 0x120)
+#define PPSMC_MSG_DisableBAPM               ((uint32_t) 0x121)
 #define PPSMC_MSG_UVD_DPM_Config            ((uint32_t) 0x124)
 
 
--- a/drivers/gpu/drm/radeon/trinity_dpm.c
+++ b/drivers/gpu/drm/radeon/trinity_dpm.c
@@ -1091,6 +1091,7 @@ int trinity_dpm_enable(struct radeon_dev
 	trinity_program_sclk_dpm(rdev);
 	trinity_start_dpm(rdev);
 	trinity_wait_for_dpm_enabled(rdev);
+	trinity_dpm_bapm_enable(rdev, false);
 	trinity_release_mutex(rdev);
 
 	if (rdev->irq.installed &&
@@ -1116,6 +1117,7 @@ void trinity_dpm_disable(struct radeon_d
 		trinity_release_mutex(rdev);
 		return;
 	}
+	trinity_dpm_bapm_enable(rdev, false);
 	trinity_disable_clock_power_gating(rdev);
 	sumo_clear_vc(rdev);
 	trinity_wait_for_level_0(rdev);
--- a/drivers/gpu/drm/radeon/trinity_dpm.h
+++ b/drivers/gpu/drm/radeon/trinity_dpm.h
@@ -118,6 +118,7 @@ struct trinity_power_info {
 #define TRINITY_AT_DFLT            30
 
 /* trinity_smc.c */
+int trinity_dpm_bapm_enable(struct radeon_device *rdev, bool enable);
 int trinity_dpm_config(struct radeon_device *rdev, bool enable);
 int trinity_uvd_dpm_config(struct radeon_device *rdev);
 int trinity_dpm_force_state(struct radeon_device *rdev, u32 n);
--- a/drivers/gpu/drm/radeon/trinity_smc.c
+++ b/drivers/gpu/drm/radeon/trinity_smc.c
@@ -56,6 +56,14 @@ static int trinity_notify_message_to_smu
 	return 0;
 }
 
+int trinity_dpm_bapm_enable(struct radeon_device *rdev, bool enable)
+{
+	if (enable)
+		return trinity_notify_message_to_smu(rdev, PPSMC_MSG_EnableBAPM);
+	else
+		return trinity_notify_message_to_smu(rdev, PPSMC_MSG_DisableBAPM);
+}
+
 int trinity_dpm_config(struct radeon_device *rdev, bool enable)
 {
 	if (enable)


Patches currently in stable-queue which might be from alexander.deucher@xxxxxxx are

queue-3.11/radeon-kms-fix-uninitialised-hotplug-work-usage-in-r100_irq_process.patch
queue-3.11/drm-radeon-avoid-uvd-corruptions-on-agp-cards.patch
queue-3.11/drm-radeon-dpm-rs780-don-t-enable-sclk-scaling-if-not-required.patch
queue-3.11/drm-radeon-fix-init-ordering-for-r600.patch
queue-3.11/drm-radeon-add-berlin-pci-ids.patch
queue-3.11/drm-radeon-enable-uvd-interrupts-on-cik.patch
queue-3.11/drm-radeon-fix-lcd-record-parsing.patch
queue-3.11/drm-radeon-fix-panel-scaling-with-edp-and-lvds-bridges.patch
queue-3.11/drm-radeon-fix-resume-on-some-rs4xx-boards-v2.patch
queue-3.11/drm-radeon-cik-update-gpu_init-for-an-additional-berlin-gpu.patch
queue-3.11/drm-radeon-update-line-buffer-allocation-for-dce8.patch
queue-3.11/drm-radeon-r6xx-add-a-stubbed-out-set_uvd_clocks-callback.patch
queue-3.11/drm-radeon-si-add-support-for-cp-dma-to-cs-checker-for-compute-v2.patch
queue-3.11/drm-radeon-atom-workaround-vbios-bug-in-transmitter-table-on-rs880-v2.patch
queue-3.11/drm-radeon-fix-endian-bugs-in-hw-i2c-atom-routines.patch
queue-3.11/drm-radeon-dpm-add-reclocking-quirk-for-asus-k70af.patch
queue-3.11/drm-radeon-update-line-buffer-allocation-for-dce6.patch
queue-3.11/drm-radeon-update-line-buffer-allocation-for-dce4.1-5.patch
queue-3.11/drm-radeon-add-some-additional-berlin-pci-ids.patch
queue-3.11/drm-radeon-dpm-handle-bapm-on-trinity.patch
queue-3.11/drm-radeon-dpm-fix-fallback-for-empty-uvd-clocks.patch
queue-3.11/drm-radeon-dpm-make-sure-dc-performance-level-limits-are-valid-btc-si-v2.patch
queue-3.11/drm-radeon-fix-handling-of-variable-sized-arrays-for-router-objects.patch
queue-3.11/drm-radeon-fill-in-gpu_init-for-berlin-gpu-cores.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]