Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp2483316pxj; Mon, 10 May 2021 04:11:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzQnqLH3JdQW//cmcV0QXBmt0HJ5NoVVN30NfZc3Aq0p+a/maPtj0AsWftoYW4v8UEWI3LZ X-Received: by 2002:a17:907:c13:: with SMTP id ga19mr24708352ejc.163.1620645074900; Mon, 10 May 2021 04:11:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620645074; cv=none; d=google.com; s=arc-20160816; b=UGkwZddAYd7+sTWm30ZVnCs7vh+SizGAko1drxrXQwtZAQeHX2JMTV6ayFflEmV5dw aLPFKiGseMlNb/QMnLVL/nAIcUbj4/+D1GUbhD12v4VygvgzDPCSvhUKxPnoahw8/3Ra u8CM3w37MydibWcs1dXegnxdN0vlWRCMjXE1jKL9UGTwB8kUxBx0PCu279uUPljf/NXp 3rA2hAxZx/OBXcHQ4vUUarORA5y1GySbBJQJ173enO/Mwdc5x/k7zpzWFrBirkuTRxea u+f5ft8n86pldMGrO+y+d0jUZL+A5tc1JKOA+B5cd5NEXkIT5Gnz+NFWgQHMooQRE9ee n+1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=BO+V9bVKl27mBWVx+dxRj5I7mQI4wfbZvOFP1ZCBmAg=; b=m9/Lfn8ckuqiFdkEnbYNl9fJPBPOH0LfIrR3jAdG97Ndczz4LAW02zTLIIPfZY5+Gd qMWMlZeUSD1ihZqGbGxcwzlkMLot+IpJ+xSQceNFuUcI4gXNm7LqvEgaQFrDfv/4ydyS WZNNWla7qsbaaKGQEXn4jFEF2EawM+xIr9nOR8cT3xcqUu58j5r/gK1IKLzwEwJM6glW 8qUUOXlqYSqftG83PN3qYNndYA0ICMswWQg6Nyr2GPZKQhxW5Gtn7SI9kjHLyBhMw91I c646RtGiubud5trR6RF52AP00PdwbnI+IfqJ4iHKYWbRrd2wX6cRJezeNp9UoFlnta9M VQIg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=lbj9hhoP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i22si13462977edc.52.2021.05.10.04.10.51; Mon, 10 May 2021 04:11:14 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=lbj9hhoP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235985AbhEJLHK (ORCPT + 99 others); Mon, 10 May 2021 07:07:10 -0400 Received: from mail.kernel.org ([198.145.29.99]:57348 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231527AbhEJKqA (ORCPT ); Mon, 10 May 2021 06:46:00 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 02B1C619B5; Mon, 10 May 2021 10:37:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1620643025; bh=bDM2BXsWVu4ZVNspegVRKj6qbKmdCaTTVNDThDY1VSE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=lbj9hhoPn+KRbH5SaCOcxIr80BDo9pq827P1fDzPypfmt7XAHd9q4+UnWI867420P xgGTN1xrMkxQeMPoofjToXZEchJbxiGxOcOO2PHf4xa1mvAp8UpMUWtHwnrS1xmmnY eLO+HSMe1szqh13SuziIomP0r5X+ezrsiNlzOAo8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Daniel Wheeler , Dmytro Laktyushkin , Eric Bernstein , Solomon Chiu , Alex Deucher , Sasha Levin Subject: [PATCH 5.10 147/299] drm/amd/display: fix dml prefetch validation Date: Mon, 10 May 2021 12:19:04 +0200 Message-Id: <20210510102009.818572493@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210510102004.821838356@linuxfoundation.org> References: <20210510102004.821838356@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Dmytro Laktyushkin [ Upstream commit 8ee0fea4baf90e43efe2275de208a7809f9985bc ] Incorrect variable used, missing initialization during validation. Tested-by: Daniel Wheeler Signed-off-by: Dmytro Laktyushkin Reviewed-by: Eric Bernstein Acked-by: Solomon Chiu Signed-off-by: Alex Deucher Signed-off-by: Sasha Levin --- drivers/gpu/drm/amd/display/dc/dml/dcn20/display_mode_vba_20.c | 1 + drivers/gpu/drm/amd/display/dc/dml/dcn20/display_mode_vba_20v2.c | 1 + 2 files changed, 2 insertions(+) diff --git a/drivers/gpu/drm/amd/display/dc/dml/dcn20/display_mode_vba_20.c b/drivers/gpu/drm/amd/display/dc/dml/dcn20/display_mode_vba_20.c index 45f028986a8d..b3f0476899d3 100644 --- a/drivers/gpu/drm/amd/display/dc/dml/dcn20/display_mode_vba_20.c +++ b/drivers/gpu/drm/amd/display/dc/dml/dcn20/display_mode_vba_20.c @@ -3437,6 +3437,7 @@ void dml20_ModeSupportAndSystemConfigurationFull(struct display_mode_lib *mode_l mode_lib->vba.DCCEnabledInAnyPlane = true; } } + mode_lib->vba.UrgentLatency = mode_lib->vba.UrgentLatencyPixelDataOnly; for (i = 0; i <= mode_lib->vba.soc.num_states; i++) { locals->FabricAndDRAMBandwidthPerState[i] = dml_min( mode_lib->vba.DRAMSpeedPerState[i] * mode_lib->vba.NumberOfChannels diff --git a/drivers/gpu/drm/amd/display/dc/dml/dcn20/display_mode_vba_20v2.c b/drivers/gpu/drm/amd/display/dc/dml/dcn20/display_mode_vba_20v2.c index 80170f9721ce..1bcda7eba4a6 100644 --- a/drivers/gpu/drm/amd/display/dc/dml/dcn20/display_mode_vba_20v2.c +++ b/drivers/gpu/drm/amd/display/dc/dml/dcn20/display_mode_vba_20v2.c @@ -3510,6 +3510,7 @@ void dml20v2_ModeSupportAndSystemConfigurationFull(struct display_mode_lib *mode mode_lib->vba.DCCEnabledInAnyPlane = true; } } + mode_lib->vba.UrgentLatency = mode_lib->vba.UrgentLatencyPixelDataOnly; for (i = 0; i <= mode_lib->vba.soc.num_states; i++) { locals->FabricAndDRAMBandwidthPerState[i] = dml_min( mode_lib->vba.DRAMSpeedPerState[i] * mode_lib->vba.NumberOfChannels -- 2.30.2