summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/radeon/rv6xx_dpm.c
Commit message (Collapse)AuthorAgeFilesLines
* drm/radeon: fix indentation.Jérome Glisse2016-03-161-9/+9
| | | | | | | | | | | I hate doing this but it hurts my eyes to go over code that does not comply with indentation rules. Only thing that is not only space change is in atom.c all other files are space indentation issues. Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Jérôme Glisse <jglisse@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/rv6xx: implement get_current_sclk/mclkAlex Deucher2015-03-191-0/+46
| | | | | | | Will be used for exposing current clocks via INFO ioctl. Tested-by: Marek Olšák <marek.olsak@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon: reduce sparse false positive warningsMichele Curti2014-10-161-0/+1
| | | | | | | | | | include radeon_asic.h header file in the various xxx_dpm.c files to reduce sparse false positive warnings. Not so great patch in itself, but reducing warning count from 391 to 258 may help to see real problems.. Signed-off-by: Michele Curti <michele.curti@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm: move platform caps fetching to a separate functionAlex Deucher2014-02-181-3/+4
| | | | | | | It's needed by by both the asic specific functions and the extended table parser. Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm: switch on new late_enable callbackAlex Deucher2013-12-241-10/+0
| | | | | | | | | | Right now it's called right after enable, but after reworking the dpm init order, it will get called later to accomodate loading the smc early, but enabling thermal interrupts and block powergating later after the ring tests are complete. Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm: cleanup a type issue with rv6xx_clocks_per_unit()Dan Carpenter2013-11-011-3/+3
| | | | | | | | | | The rv6xx_clocks_per_unit() function pretends it can set flags in a u64 bitfield but really because "1" is an int it doesn't work for more than 32 bits. The only caller truncates the high bits away anyway. I've just changed it to be a u32. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm: rework auto performance level enableAlex Deucher2013-09-151-2/+0
| | | | | | | | | | | | | Calling force_performance_level() from set_power_state() doesn't work on some asics because the current power state pointer has not been properly updated at that point. Move the calls to force_performance_level() out of the asic specific set_power_state() functions and into the main power state sequence. Fixes dpm resume on SI. Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon: gcc fixes for rv6xx dpmAlex Deucher2013-08-301-2/+3
| | | | | | | | | | | | | | Newer versions of gcc seem to wander off into the weeds when dealing with variable sizes arrays in structs. Rather than indexing the arrays, use pointer arithmetic. See bugs: https://bugs.freedesktop.org/show_bug.cgi?id=66932 https://bugs.freedesktop.org/show_bug.cgi?id=66972 https://bugs.freedesktop.org/show_bug.cgi?id=66945 Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm: disable sclk ss on rv6xxAlex Deucher2013-08-071-0/+3
| | | | | | | | | | Enabling spread spectrum on the engine clock leads to hangs on some asics. Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=66963 Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm: fix spread spectrum setup (v2)Alex Deucher2013-08-071-11/+8
| | | | | | | | | | | | | | | | | | Need to check for engine and memory clock ss separately and only enable dynamic ss if either of them are found. This should fix systems which have a ss table, but do not have entries for engine or memory. On those systems we may enable dynamic spread spectrum without enabling it on the engine or memory clocks which can lead to a hang in some cases. fixes some systems reported here: https://bugs.freedesktop.org/show_bug.cgi?id=66963 v2: fix typo Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm: implement force performance levels for rv6xxAlex Deucher2013-07-251-0/+35
| | | | | | Allows you to limit the selected power levels via sysfs. Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm: fix displaygap programming on rv6xxAlex Deucher2013-07-251-2/+2
| | | | | | | | Need to use the driver state rather than the register state since the displays may not be enabled when the power state is programmed. Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm: fix a typo in the rv6xx mclk setupAlex Deucher2013-07-251-1/+1
| | | | | | | Need to set high for the last two entries. Looks like a copy and paste typo. Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon: add a module parameter to disable aspmAlex Deucher2013-07-171-6/+8
| | | | | | | Can cause hangs when enabled in certain motherboards. Set radeon.aspm=0 to disable aspm. Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm: fix compilation with certain versions of gccMike Lothian2013-07-021-0/+1
| | | | | | Add #include <linux/seq_file.h> to *_dpm.c files Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm: add debugfs support for rv6xxAlex Deucher2013-07-011-0/+25
| | | | | | | This allows you to look at the current DPM state via debugfs. Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm: add support for setting UVD clock on rv6xxAlex Deucher2013-06-271-0/+38
| | | | Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm/r6xx: properly catch errors in dpm setupAlex Deucher2013-06-271-3/+10
| | | | | | | We weren't properly catching errors in dpm_enable() and dpm_set_power_state(). Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon: update radeon_atombios_get_default_voltages for mvddAlex Deucher2013-06-271-2/+2
| | | | | | Add a way to look up the bootup mvdd. Required for DPM on SI. Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon: update radeon_atom_is_voltage_gpio() for SIAlex Deucher2013-06-271-1/+1
| | | | | | SI uses a new atom table. Required for DPM on SI. Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/dpm/rv6xx: restructure codeAlex Deucher2013-06-271-46/+69
| | | | | | Needed to properly handle dynamic state adjustment. Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
* drm/radeon/kms: add dpm support for rv6xx (v3)Alex Deucher2013-06-271-0/+1991
This adds dpm support for rv6xx asics. This includes: - clockgating - dynamic engine clock scaling - dynamic memory clock scaling - dynamic voltage scaling - dynamic pcie gen1/gen2 switching Set radeon.dpm=1 to enable. v2: remove duplicate line v3: fix thermal interrupt check noticed by Jerome Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
OpenPOWER on IntegriCloud