From patchwork Thu Sep 19 14:36:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nikita Zhandarovich X-Patchwork-Id: 13807795 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 A7727CF394D for ; Thu, 19 Sep 2024 14:36:17 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 6203710E713; Thu, 19 Sep 2024 14:36:15 +0000 (UTC) Received: from exchange.fintech.ru (exchange.fintech.ru [195.54.195.159]) by gabe.freedesktop.org (Postfix) with ESMTPS id 758F110E712; Thu, 19 Sep 2024 14:36:14 +0000 (UTC) Received: from Ex16-01.fintech.ru (10.0.10.18) by exchange.fintech.ru (195.54.195.159) with Microsoft SMTP Server (TLS) id 14.3.498.0; Thu, 19 Sep 2024 17:36:10 +0300 Received: from localhost (10.0.253.138) by Ex16-01.fintech.ru (10.0.10.18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.4; Thu, 19 Sep 2024 17:36:10 +0300 From: Nikita Zhandarovich To: , Greg Kroah-Hartman CC: Nikita Zhandarovich , Jani Nikula , Rodrigo Vivi , "Joonas Lahtinen" , Tvrtko Ursulin , David Airlie , , , , , Subject: [PATCH 5.10/5.15 0/1] drm/i915: Fix possible int overflow in skl_ddi_calculate_wrpll() Date: Thu, 19 Sep 2024 07:36:06 -0700 Message-ID: <20240919143607.14178-1-n.zhandarovich@fintech.ru> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-Originating-IP: [10.0.253.138] X-ClientProxiedBy: Ex16-02.fintech.ru (10.0.10.19) To Ex16-01.fintech.ru (10.0.10.18) X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" This patch addresses issues of integer overflow and possibly erroneous integer promotion in skl_ddi_calculate_wrpll() and skl_ddi_hdmi_pll_dividers() in kernel versions 5.10 and 5.15. The problem has been fixed in upstream and stable versions up to 6.1 with commit: 5b5115726601 ("drm/i915: Fix possible int overflow in skl_ddi_calculate_wrpll()") Due to changes to skl_ddi_calculate_wrpll() return value the patch had to be slightly modified during cherry-picking, leaving the original fix intact, and can now be cleanly applied to 5.10 and 5.15 kernels.