Received: by 2002:a05:7412:a9a2:b0:e2:908c:2ebd with SMTP id o34csp2889133rdh; Mon, 30 Oct 2023 10:27:15 -0700 (PDT) X-Google-Smtp-Source: AGHT+IE40jvJD41BmImMC53RM/O+KHGHGp/smZjw2xW7K55OYgEboQmSuLlvEt92ZQU+ZQnynHwY X-Received: by 2002:a05:6870:d8c8:b0:1e9:c7cc:df9a with SMTP id of8-20020a056870d8c800b001e9c7ccdf9amr13750280oac.11.1698686834853; Mon, 30 Oct 2023 10:27:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698686834; cv=none; d=google.com; s=arc-20160816; b=v035NdX+FEZNa40UWLyq/5sKAICDD9UoCIdCcMCyshq2Z/GMtnyoC/lhkOcEEziQWn eS5WyeWIOvDKueDdN+u9fXLSGiyjphJUNwhIbOxX4OcSKc53lSQODDwCYLQ6uxw86pex 5UgshcA2tiSdXbV8ij8QujYva8pzteNrqP4R+YHO/JoSE1WADVggY5uc4seA3Dzkq6f8 OwLzjlgsuvfPKb4CFGKOjc87DzguFTb3x/U7UmRnz4BkD7u7JB/zrKytNowmVStjc3hk wORcNzb3Jba2HzUfWLQNifiKUDz5/NroXr3e4EZlvS2eQW7acYj5PZ2QtaTLd9SKf14z Y5RA== 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 :message-id:date:subject:cc:to:from; bh=HZocxCYfJSBzreeLR5g4DEVj2KaC8aYwylwMb8tF77w=; fh=BGNdP+6MizM0sv+//PEHSTERgJ9N4ZEpHnflWdzb8CY=; b=noNtkkXzSw6azVpBbDYPocO5hPvx/vINJnW84edA23UrECGKtYKP/SSKMfj4dTnMMF yo6AtztlTZf9xxYOyem4mRab9MY67kXUKPmK6QscrGhl46CkV0Mh6WX8uN0EaqLgLwl9 JZjkmU5+3v+YKwAyR/4qFEOe/78VVHxnuJcfy0xrawqDLuo+fMxPZ2ospFan7/CziEoR AzGP1m2dH3i3h8MnDOTJD3PKmEFzh7I0MHOG0DAoE92Gdwm69q1hQd4Z9jZ3SQur1nd8 7DE409/xnQBMa9YwdeC9TQejKljxBmMf8yUaHSBTSkP7IpNksQwGE4oh66gW2H5+DFo0 ISxQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from howler.vger.email (howler.vger.email. [2620:137:e000::3:4]) by mx.google.com with ESMTPS id c12-20020a63d14c000000b005aee0914b6csi5269146pgj.8.2023.10.30.10.27.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Oct 2023 10:27:14 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) client-ip=2620:137:e000::3:4; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id 3DFA080934A0; Mon, 30 Oct 2023 10:27:12 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232579AbjJ3R1D (ORCPT + 99 others); Mon, 30 Oct 2023 13:27:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55544 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231949AbjJ3R1B (ORCPT ); Mon, 30 Oct 2023 13:27:01 -0400 Received: from 1.mo560.mail-out.ovh.net (1.mo560.mail-out.ovh.net [46.105.63.121]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6415699 for ; Mon, 30 Oct 2023 10:26:58 -0700 (PDT) Received: from director1.ghost.mail-out.ovh.net (unknown [10.109.143.210]) by mo560.mail-out.ovh.net (Postfix) with ESMTP id DD6102477F for ; Mon, 30 Oct 2023 17:17:53 +0000 (UTC) Received: from ghost-submission-6684bf9d7b-7pdj5 (unknown [10.110.115.40]) by director1.ghost.mail-out.ovh.net (Postfix) with ESMTPS id A3AD81FE93; Mon, 30 Oct 2023 17:17:52 +0000 (UTC) Received: from foxhound.fi ([37.59.142.108]) by ghost-submission-6684bf9d7b-7pdj5 with ESMTPSA id ciZaJEDlP2V+SAEAhpL/bw (envelope-from ); Mon, 30 Oct 2023 17:17:52 +0000 Authentication-Results: garm.ovh; auth=pass (GARM-108S002f7264df6-502a-4d3d-8901-f89f427d1744, 1521F8BC68C4446D6F30831D87711B1BDC7B9471) smtp.auth=jose.pekkarinen@foxhound.fi X-OVh-ClientIp: 91.157.109.247 From: =?UTF-8?q?Jos=C3=A9=20Pekkarinen?= To: harry.wentland@amd.com, sunpeng.li@amd.com, Rodrigo.Siqueira@amd.com, skhan@linuxfoundation.org Cc: =?UTF-8?q?Jos=C3=A9=20Pekkarinen?= , alexander.deucher@amd.com, christian.koenig@amd.com, Xinhui.Pan@amd.com, airlied@gmail.com, daniel@ffwll.ch, dillon.varone@amd.com, Jun.Lei@amd.com, aurabindo.pillai@amd.com, george.shen@amd.com, samson.tam@amd.com, SyedSaaem.Rizvi@amd.com, stable@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, linux-kernel-mentees@lists.linuxfoundation.org Subject: [PATCH] drm/amd/display: remove redundant check Date: Mon, 30 Oct 2023 19:17:48 +0200 Message-Id: <20231030171748.35482-1-jose.pekkarinen@foxhound.fi> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Ovh-Tracer-Id: 16519484912439764646 X-VR-SPAMSTATE: OK X-VR-SPAMSCORE: 0 X-VR-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedvkedruddttddgleejucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuqfggjfdpvefjgfevmfevgfenuceurghilhhouhhtmecuhedttdenucenucfjughrpefhvfevufffkffogggtgfesthekredtredtjeenucfhrhhomheplfhoshorucfrvghkkhgrrhhinhgvnhcuoehjohhsvgdrphgvkhhkrghrihhnvghnsehfohighhhouhhnugdrfhhiqeenucggtffrrghtthgvrhhnpeeftdelueetieetvdettdetueeivedujeefffdvteefkeelhefhleelfeetteejjeenucfkphepuddvjedrtddrtddruddpledurdduheejrddutdelrddvgeejpdefjedrheelrddugedvrddutdeknecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehinhgvthepuddvjedrtddrtddruddpmhgrihhlfhhrohhmpeeojhhoshgvrdhpvghkkhgrrhhinhgvnhesfhhogihhohhunhgurdhfiheqpdhnsggprhgtphhtthhopedupdhrtghpthhtoheplhhinhhugidqkhgvrhhnvghlsehvghgvrhdrkhgvrhhnvghlrdhorhhgpdfovfetjfhoshhtpehmohehiedtpdhmohguvgepshhmthhpohhuth X-Spam-Status: No, score=-0.8 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on howler.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Mon, 30 Oct 2023 10:27:12 -0700 (PDT) This patch addresses the following warning spotted by using coccinelle where the case checked does the same than the else case. drivers/gpu/drm/amd/display/dc/dml/dcn32/display_mode_vba_util_32.c:4664:8-10: WARNING: possible condition with no effect (if == else) Fixes: 974ce181 ("drm/amd/display: Add check for PState change in DCN32") Cc: stable@vger.kernel.org Signed-off-by: José Pekkarinen --- .../drm/amd/display/dc/dml/dcn32/display_mode_vba_util_32.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/drivers/gpu/drm/amd/display/dc/dml/dcn32/display_mode_vba_util_32.c b/drivers/gpu/drm/amd/display/dc/dml/dcn32/display_mode_vba_util_32.c index ecea008f19d3..d940dfa5ae43 100644 --- a/drivers/gpu/drm/amd/display/dc/dml/dcn32/display_mode_vba_util_32.c +++ b/drivers/gpu/drm/amd/display/dc/dml/dcn32/display_mode_vba_util_32.c @@ -4661,10 +4661,6 @@ void dml32_CalculateMinAndMaxPrefetchMode( } else if (AllowForPStateChangeOrStutterInVBlankFinal == dm_prefetch_support_uclk_fclk_and_stutter) { *MinPrefetchMode = 0; *MaxPrefetchMode = 0; - } else if (AllowForPStateChangeOrStutterInVBlankFinal == - dm_prefetch_support_uclk_fclk_and_stutter_if_possible) { - *MinPrefetchMode = 0; - *MaxPrefetchMode = 3; } else { *MinPrefetchMode = 0; *MaxPrefetchMode = 3; -- 2.39.2