Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp4083245ybi; Mon, 29 Jul 2019 18:54:11 -0700 (PDT) X-Google-Smtp-Source: APXvYqyYYXmp64k5jhX+csbqPK4FX3Lo+cEgZtK1qCYYUMZIgwI50IN6ntT8QWDbWTuwDfxQ44Be X-Received: by 2002:a17:902:b909:: with SMTP id bf9mr19130031plb.309.1564451651830; Mon, 29 Jul 2019 18:54:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564451651; cv=none; d=google.com; s=arc-20160816; b=I68J6mJMGjfhQ+FoQM3NIjFp2vi00IuuRGOyRjBvi5SgINcfoDTQSlhJiqWOytWfc9 5B9+2Jlso0Ol1nfCGcYhODnUAxJ4QrNmSkBqX+CqjKsUX9Ly6HHaB915gIfx3ga7pMwQ FHsG3kNpTXmYfDN73Fx5brJ4Ytms1x3bDFrPdUATsZ/PeXylOTRlAu3nOr/oF/4hHxF+ aQjVzhzSa53V9D+KLQDsDf68fK32GbObcYQ4VpJ4Rfxi6etfnj2LAhFRhUDciyc477pv tS4vS65Biu8PCcrIDDC4rNDqJD9Z6DEAAjPjmky/pNgy8MsmaWKZbG8C+nR6798rF/Ta ElAQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=44BDtQR+TPQZ74tVjqTCwiWJOiiLqxAmK0uXj+9kmFQ=; b=YTpUIvPW1K/n/44oz3bD32LGZ9P05bDnTk22n4+c2S0Bk+3lA62HuKFuKYpcqniq8v vMmurOP4W93VH8rsM2VmlrrzJbpopcdqic/n61NgmwTQfmJUgc+ootNzpOO5elHLmp5+ qUKcQuhneglk6ESrcy0itAysk83JyWmfmAhs43HeWMsFsRtAMQg9zCZNWB3aUtaOuEYE MdP01vatgDbEicc0HDtQ2cepegHJlEtr2niJsEZhKQqCULE/vPjhtoQ4IdAnotDIFQbl zw+iBdZICgWjTedgIIFGWTlYwF4D+ahcoNfmNWtDBK/l6T0yylhAp6kjQ9ZKIdY/bWEX vGug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=DAXNGuMi; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x3si7852773plb.164.2019.07.29.18.53.56; Mon, 29 Jul 2019 18:54:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=DAXNGuMi; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390277AbfG2TtA (ORCPT + 99 others); Mon, 29 Jul 2019 15:49:00 -0400 Received: from mail.kernel.org ([198.145.29.99]:39306 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2390457AbfG2Ts5 (ORCPT ); Mon, 29 Jul 2019 15:48:57 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 823B22054F; Mon, 29 Jul 2019 19:48:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1564429736; bh=HJFjq2UfmQyHbylLZ3M1AcIZTVsvoJQTNcts5rruxQo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=DAXNGuMi0/IxlomFGa+nlc3J0VKxkkmXHL6vnzdOYF5JEhl6JMO9Pj8auRZI8zEF8 Iw/uVNWC4jKubB1u3wKeDalKwib4FUfqo1LppH/o2ijFbjagEN1Ar0TFIb1OwNleHO k/8Tfb9X88VKW/qU+47xRZoWK4UOThmJTCyqEOA8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Eryk Brol , Jun Lei , Leo Li , Alex Deucher , Sasha Levin Subject: [PATCH 5.2 039/215] drm/amd/display: Increase Backlight Gain Step Size Date: Mon, 29 Jul 2019 21:20:35 +0200 Message-Id: <20190729190747.272234360@linuxfoundation.org> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190729190739.971253303@linuxfoundation.org> References: <20190729190739.971253303@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [ Upstream commit e25228b02e4833e5b0fdd262801a2ae6cc72b39d ] [Why] Some backlight tests fail due to backlight settling taking too long. This happens because the step size used to change backlight levels is too small. [How] 1. Change the size of the backlight gain step size 2. Change how DMCU firmware gets the step size value so that it is passed in by driver during DMCU initn Signed-off-by: Eryk Brol Reviewed-by: Jun Lei Acked-by: Leo Li Signed-off-by: Alex Deucher Signed-off-by: Sasha Levin --- drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c | 3 +++ drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.h | 2 ++ 2 files changed, 5 insertions(+) diff --git a/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c b/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c index 818536eea00a..c6a607cd0e4b 100644 --- a/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c +++ b/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c @@ -388,6 +388,9 @@ static bool dcn10_dmcu_init(struct dmcu *dmcu) /* Set initialized ramping boundary value */ REG_WRITE(MASTER_COMM_DATA_REG1, 0xFFFF); + /* Set backlight ramping stepsize */ + REG_WRITE(MASTER_COMM_DATA_REG2, abm_gain_stepsize); + /* Set command to initialize microcontroller */ REG_UPDATE(MASTER_COMM_CMD_REG, MASTER_COMM_CMD_REG_BYTE0, MCP_INIT_DMCU); diff --git a/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.h b/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.h index 60ce56f60ae3..5bd0df55aa5d 100644 --- a/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.h +++ b/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.h @@ -263,4 +263,6 @@ struct dmcu *dcn10_dmcu_create( void dce_dmcu_destroy(struct dmcu **dmcu); +static const uint32_t abm_gain_stepsize = 0x0060; + #endif /* _DCE_ABM_H_ */ -- 2.20.1