Message ID | 20171226111227.4526-3-net147@gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <dri-devel-bounces@lists.freedesktop.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 98A8A60388 for <patchwork-dri-devel@patchwork.kernel.org>; Wed, 27 Dec 2017 08:09:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 895162A70A for <patchwork-dri-devel@patchwork.kernel.org>; Wed, 27 Dec 2017 08:09:54 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7E5B82DB91; Wed, 27 Dec 2017 08:09:54 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 4E9662A70A for <patchwork-dri-devel@patchwork.kernel.org>; Wed, 27 Dec 2017 08:09:54 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 521AC896C4; Wed, 27 Dec 2017 08:09:14 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-pl0-x241.google.com (mail-pl0-x241.google.com [IPv6:2607:f8b0:400e:c01::241]) by gabe.freedesktop.org (Postfix) with ESMTPS id 7EA2A89904 for <dri-devel@lists.freedesktop.org>; Tue, 26 Dec 2017 11:10:10 +0000 (UTC) Received: by mail-pl0-x241.google.com with SMTP id i6so17719994plt.13 for <dri-devel@lists.freedesktop.org>; Tue, 26 Dec 2017 03:10:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=7DtfEbNlSU4KTpMfKGwNGmsaKKTeMrzSSQ7esz0ucYU=; b=mM7A6VlgoTwknYMV6uVyx1aTHtF/5hBhatCZXLnSMvFGXRtx7JESME26+MPZCMv8Hg J0l6Ad+ebK4thqVQyKFhbhuw93Mf9J24uMCaynj8gWkUo9J8Y0i1TbL++Uei/ZCq9vWf 5V0gRkp0vaqVXURyxBm0hGaJJERzoPbBjurelS7tpbT63Aol0FvRZhPkGUDVgKTksUJP TpqDYrlyXOWUWjsIFmcLKfg+6FJvRQMfD7ykSih1GcL5xmkwo+nosx74XDHetVCEptFz 3twWkMlS9MgCrjmbQQ9TyQ3ZWUNMz+VcmcGfSdfVxw9bOP64TrysnowdUB0LvZrOrKx9 tT4Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=7DtfEbNlSU4KTpMfKGwNGmsaKKTeMrzSSQ7esz0ucYU=; b=sTMomeVASENmPdSoDsHT/ZE/+er6EB6KanCbTAs2DhY+cGEi0omIjjmesrp4+/tFci Zh/a1m1NEDNTGTGaFXRikdmaSIce6nkuiIzNfsDpmxV8111HTMYMNmJTZ/hi+kInmf5d Drt2EoG1mcG3zTIsUYc92Vdd1n700RJ2Saix3sPGAJaOoasqXpDilgl4tp/Cc3IxGL1Z N3KYb0wCA/bJne+43jzwjQLsk3kUeXGf5J2ZnMKpQl3CHKEFEb1eMI0vaT9856KozNzj ghh6/17T4Roy5xdy/TEyrjclQYfPNSdnbrYokG9yI2nP+L9mL3cH3PXj8htfwqKF82MN K6tQ== X-Gm-Message-State: AKGB3mKteRVgaIVtZO6jD1TJ4YP20BSkVuX3YZuDenLQpI6bx6ISwuoc R06Z6+ltsffbi4FUoHiEI2M= X-Google-Smtp-Source: ACJfBosL3DoQkYDOuW86797x2h27g3oXadNHAUAxQURy8XHYXt5BoikvXP8t6EIQB0JJ9NIKzdwUXA== X-Received: by 10.84.242.134 with SMTP id d6mr24734802pll.98.1514286610042; Tue, 26 Dec 2017 03:10:10 -0800 (PST) Received: from 60-242-179-244.static.tpgi.com.au (60-242-179-244.static.tpgi.com.au. [60.242.179.244]) by smtp.gmail.com with ESMTPSA id u19sm54205444pfh.89.2017.12.26.03.10.08 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 26 Dec 2017 03:10:09 -0800 (PST) From: Jonathan Liu <net147@gmail.com> To: Maxime Ripard <maxime.ripard@free-electrons.com>, David Airlie <airlied@linux.ie>, Chen-Yu Tsai <wens@csie.org> Subject: [PATCH v2 2/3] drm/sun4i: hdmi: Fix incorrect assignment in sun4i_tmds_determine_rate Date: Tue, 26 Dec 2017 22:12:26 +1100 Message-Id: <20171226111227.4526-3-net147@gmail.com> X-Mailer: git-send-email 2.15.0 In-Reply-To: <20171226111227.4526-1-net147@gmail.com> References: <20171226111227.4526-1-net147@gmail.com> X-Mailman-Approved-At: Wed, 27 Dec 2017 08:09:10 +0000 Cc: linux-arm-kernel@lists.infradead.org, linux-sunxi@googlegroups.com, Jonathan Liu <net147@gmail.com>, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development <dri-devel.lists.freedesktop.org> List-Unsubscribe: <https://lists.freedesktop.org/mailman/options/dri-devel>, <mailto:dri-devel-request@lists.freedesktop.org?subject=unsubscribe> List-Archive: <https://lists.freedesktop.org/archives/dri-devel> List-Post: <mailto:dri-devel@lists.freedesktop.org> List-Help: <mailto:dri-devel-request@lists.freedesktop.org?subject=help> List-Subscribe: <https://lists.freedesktop.org/mailman/listinfo/dri-devel>, <mailto:dri-devel-request@lists.freedesktop.org?subject=subscribe> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" <dri-devel-bounces@lists.freedesktop.org> X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/drivers/gpu/drm/sun4i/sun4i_hdmi_tmds_clk.c b/drivers/gpu/drm/sun4i/sun4i_hdmi_tmds_clk.c index 4d235e5ea31c..88eeeaf34638 100644 --- a/drivers/gpu/drm/sun4i/sun4i_hdmi_tmds_clk.c +++ b/drivers/gpu/drm/sun4i/sun4i_hdmi_tmds_clk.c @@ -105,7 +105,7 @@ static int sun4i_tmds_determine_rate(struct clk_hw *hw, if (!best_parent || abs(rate - rounded / i) < abs(rate - best_parent / best_div)) { best_parent = rounded; - best_div = i; + best_div = j; } } }
best_div is set to i which corresponds to rate halving when it should be set to j which corresponds to the divider. Fixes: 9c5681011a0c ("drm/sun4i: Add HDMI support") Signed-off-by: Jonathan Liu <net147@gmail.com> --- drivers/gpu/drm/sun4i/sun4i_hdmi_tmds_clk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)