[PATCH] drm/radeon/kms: fix fans after resume
Michel Dänzer
michel at daenzer.net
Thu Mar 29 23:08:45 PDT 2012
On Don, 2012-03-29 at 19:04 -0400, alexdeucher at gmail.com wrote:
> From: Alex Deucher <alexander.deucher at amd.com>
>
> On pre-R600 asics, the SpeedFanControl table is not
> executed as part of ASIC_Init as it is on newer asics.
>
> Fixes:
> https://bugzilla.kernel.org/show_bug.cgi?id=29412
>
> Signed-off-by: Alex Deucher <alexander.deucher at amd.com>
> Cc: stable at vger.kernel.org
> ---
> drivers/gpu/drm/radeon/atom.c | 15 ++++++++++++++-
> drivers/gpu/drm/radeon/atom.h | 1 +
> 2 files changed, 15 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/gpu/drm/radeon/atom.c b/drivers/gpu/drm/radeon/atom.c
> index d1bd239..5ce9bf5 100644
> --- a/drivers/gpu/drm/radeon/atom.c
> +++ b/drivers/gpu/drm/radeon/atom.c
> [...]
> @@ -1317,7 +1320,17 @@ int atom_asic_init(struct atom_context *ctx)
>
> if (!CU16(ctx->cmd_table + 4 + 2 * ATOM_CMD_INIT))
> return 1;
> - return atom_execute_table(ctx, ATOM_CMD_INIT, ps);
> + ret = atom_execute_table(ctx, ATOM_CMD_INIT, ps);
> + if (ret)
> + return ret;
> +
> + memset(ps, 0, 64);
> +
> + if (rdev->family < CHIP_R600) {
> + if (CU16(ctx->cmd_table + 4 + 2 * ATOM_CMD_SPDFANCNTL))
> + atom_execute_table(ctx, ATOM_CMD_SPDFANCNTL, ps);
Should the return value of atom_execute_table() be assigned to ret here
as well? Either way,
Reviewed-by: Michel Dänzer <michel.daenzer at amd.com>
--
Earthling Michel Dänzer | http://www.amd.com
Libre software enthusiast | Debian, X and DRI developer
More information about the dri-devel
mailing list