From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id AE7E5C19F4F for ; Tue, 7 May 2024 23:13:57 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id AC124112FF7; Tue, 7 May 2024 23:13:56 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=kernel.org header.i=@kernel.org header.b="Q3f7bK/+"; dkim-atps=neutral Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by gabe.freedesktop.org (Postfix) with ESMTPS id 782B9112FCA; Tue, 7 May 2024 23:13:55 +0000 (UTC) Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by dfw.source.kernel.org (Postfix) with ESMTP id DF88E61A01; Tue, 7 May 2024 23:13:54 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 628E4C3277B; Tue, 7 May 2024 23:13:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1715123634; bh=7XUdhYBuP3PUPxg1+fCt2aEcoCZ3e46AEM3flJ/HOJU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Q3f7bK/+YcEhTQauWzSdJhpq5cBRLZAiQEFZZ7XOV8lbU65UdJjklVq2wf63GgJwY HT5VhmwKeR6Ho0+wBDXSvYxoY4+SVKaoE4WZR3T1FHHThSVNb6rL+RLshy7Gw6gJHI 1KtVplMExwx4X7BRaERCDnfQH1npB4WcQBf85Mj61AsX8UxVF9Bh0PZTujxzYMHyJD bBgWfbVkzOWnLxsWRvEWqQmPtjkIzDY04wGxEpw07SEbFwMRwflk397reKa+d9wkFt CJyDHnBxJqUHYmgTnRBej5zorE6xHrE06fWp2ptmwV+yoSILKFtIAGg+3zNtO7DhsI b3DBA6HDab7ZA== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Gabe Teeger , Nicholas Kazlauskas , Aurabindo Pillai , Daniel Wheeler , Alex Deucher , Sasha Levin , harry.wentland@amd.com, sunpeng.li@amd.com, Rodrigo.Siqueira@amd.com, christian.koenig@amd.com, Xinhui.Pan@amd.com, airlied@gmail.com, daniel@ffwll.ch, wayne.lin@amd.com, alvin.lee2@amd.com, sohaib.nadeem@amd.com, charlene.liu@amd.com, sunran001@208suo.com, amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org Subject: [PATCH AUTOSEL 5.15 11/15] drm/amd/display: Atom Integrated System Info v2_2 for DCN35 Date: Tue, 7 May 2024 19:13:20 -0400 Message-ID: <20240507231333.394765-11-sashal@kernel.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240507231333.394765-1-sashal@kernel.org> References: <20240507231333.394765-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore X-stable-base: Linux 5.15.158 Content-Transfer-Encoding: 8bit X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Gabe Teeger [ Upstream commit 9a35d205f466501dcfe5625ca313d944d0ac2d60 ] New request from KMD/VBIOS in order to support new UMA carveout model. This fixes a null dereference from accessing Ctx->dc_bios->integrated_info while it was NULL. DAL parses through the BIOS and extracts the necessary integrated_info but was missing a case for the new BIOS version 2.3. Reviewed-by: Nicholas Kazlauskas Acked-by: Aurabindo Pillai Signed-off-by: Gabe Teeger Tested-by: Daniel Wheeler Signed-off-by: Alex Deucher Signed-off-by: Sasha Levin --- drivers/gpu/drm/amd/display/dc/bios/bios_parser2.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/display/dc/bios/bios_parser2.c b/drivers/gpu/drm/amd/display/dc/bios/bios_parser2.c index 228f098e5d88f..6bc8c6bee411e 100644 --- a/drivers/gpu/drm/amd/display/dc/bios/bios_parser2.c +++ b/drivers/gpu/drm/amd/display/dc/bios/bios_parser2.c @@ -2303,6 +2303,7 @@ static enum bp_result construct_integrated_info( result = get_integrated_info_v2_1(bp, info); break; case 2: + case 3: result = get_integrated_info_v2_2(bp, info); break; default: -- 2.43.0