diff options
author | Alex Deucher <alexander.deucher@amd.com> | 2014-11-03 17:57:46 +0300 |
---|---|---|
committer | Jiri Slaby <jslaby@suse.cz> | 2014-11-19 20:38:18 +0300 |
commit | 30c45d8c1094fa14ef7180bbd5cf3af33b49f1c8 (patch) | |
tree | 165c6c46a90885071b485e881604c986446224b3 /drivers/gpu/drm/radeon/evergreen.c | |
parent | 37dc09565477b5beb644ceea44341fdc46ac4dbe (diff) | |
download | linux-30c45d8c1094fa14ef7180bbd5cf3af33b49f1c8.tar.xz |
drm/radeon: make sure mode init is complete in bandwidth_update
commit 8efe82ca908400785253c8f0dfcf301e6bd93488 upstream.
The power management code calls into the display code for
certain things. If certain power management sysfs attributes
are called before the driver has finished initializing all of
the hardware we can run into problems with uninitialized
modesetting state. Add a check to make sure modesetting
init has completed to the bandwidth update callbacks to
fix this. Can be triggered by the tlp and laptop start
up scripts depending on the timing.
bugs:
https://bugzilla.kernel.org/show_bug.cgi?id=83611
https://bugs.freedesktop.org/show_bug.cgi?id=85771
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Diffstat (limited to 'drivers/gpu/drm/radeon/evergreen.c')
-rw-r--r-- | drivers/gpu/drm/radeon/evergreen.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/evergreen.c b/drivers/gpu/drm/radeon/evergreen.c index 7ca58fc7a1c6..9e726f2d2e75 100644 --- a/drivers/gpu/drm/radeon/evergreen.c +++ b/drivers/gpu/drm/radeon/evergreen.c @@ -2312,6 +2312,9 @@ void evergreen_bandwidth_update(struct radeon_device *rdev) u32 num_heads = 0, lb_size; int i; + if (!rdev->mode_info.mode_config_initialized) + return; + radeon_update_display_priority(rdev); for (i = 0; i < rdev->num_crtc; i++) { |