Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp440752iog; Mon, 13 Jun 2022 06:04:26 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwFyz43srQM7hfJ/GEkGkeJHtN42Im/rV/90j6LTSxVmDpeLrOH9I4s6kwJ3ruVd7pvsWP4 X-Received: by 2002:a17:903:181:b0:167:97e3:f67e with SMTP id z1-20020a170903018100b0016797e3f67emr31814000plg.151.1655125376724; Mon, 13 Jun 2022 06:02:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655125376; cv=none; d=google.com; s=arc-20160816; b=ocyzvpbro3DDKjE2zxs8UOMCMfn6+W7T1dGBZ0psLtC+3K2kpRiySxEEl9Ce5M65eU x1USwJgoDdeao0aGsr2f847PxjqaMMgYZLg9sM1LMSvEl4PLAESckA4r8HaTO2ALd1Ea IKeWy39LVXuGAyWttdHhyvhDCplgXlcYiA6xRIZVlcYSuDB9u4Z5wa0bXU9aQr+E6Foi pL7FGrM5xMM2zCT56sfc5ExKTWeDSseAKeyFPcyxpRZAmFNzI2Ma3aXs7nazxC7toE2W VXPE1xLbA8o6PGL1q/d3guMxNZici+6dzTu+K26T4gaeTkP+bnatL0tRG24VqsfLDmJN Gh5A== 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=bZqtwTeWR0R11pEAmXRWY/3gwaFl52kayvWRSt6FbaY=; b=d/0krgO2zfz73dToFnWerF8RK3odOEdFWOPuqtXfHQWPdnz4PxkCmDqDLDU7QGekkJ 4ZH2QPs9Go3Zl0XziO4ltK33ypq5+Cs6YTucxSn1liIv/4A1U0+Y50GaY44t9ed2KsbI B8UVej72axCfWcyGPSR5wQHXRX/f04eNFJWmGXtzAzUz8hDQGeoaYuhuLAb96x6ViP4p uCdVZSN/dQ8/GHg4Rw+VVcx982eGEr4aFPpkXExArsgcxNMbBjCuh23GoHFzf6sMHPwQ cNN2OdAPbSd+eLbj7NeuDvCbnERFwk3PNYmfHX5huM+VpkrCStslBPoU8Yt2n87TszBW aQjQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=OHqsMym+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id kk12-20020a17090b4a0c00b001d5cd19a41esi10121190pjb.38.2022.06.13.06.02.40; Mon, 13 Jun 2022 06:02:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=OHqsMym+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 S1346748AbiFMKkN (ORCPT + 99 others); Mon, 13 Jun 2022 06:40:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51148 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346444AbiFMKiO (ORCPT ); Mon, 13 Jun 2022 06:38:14 -0400 Received: from sin.source.kernel.org (sin.source.kernel.org [IPv6:2604:1380:40e1:4800::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 12F6713E00; Mon, 13 Jun 2022 03:22:59 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sin.source.kernel.org (Postfix) with ESMTPS id D3F8DCE1161; Mon, 13 Jun 2022 10:22:57 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B9F9BC3411E; Mon, 13 Jun 2022 10:22:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1655115776; bh=262NN7HEnh2igmL4l1gAU+SUwZl24FoHE7oXfKo85Lc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=OHqsMym+6e6UMVvCCy04eMaV9WYLcvjqn97A1F1NFirzFy1mRf16X3LRi9W8PnmFW 0ZPIlWUPEfJq0bOPcOXwLnOSjMZISkcgqnOn4D/t3QC6aXMUlS9SNCm7eMHdbwIdDX Ab8+u1bdpf7KQ6qw60cZYYyS4dlm+AfNQTm/Ae8g= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Janusz Krzysztofik , Tony Lindgren , Arnd Bergmann , Sasha Levin Subject: [PATCH 4.14 037/218] ARM: OMAP1: clock: Fix UART rate reporting algorithm Date: Mon, 13 Jun 2022 12:08:15 +0200 Message-Id: <20220613094917.103514268@linuxfoundation.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220613094908.257446132@linuxfoundation.org> References: <20220613094908.257446132@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-8.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Janusz Krzysztofik [ Upstream commit 338d5d476cde853dfd97378d20496baabc2ce3c0 ] Since its introduction to the mainline kernel, omap1_uart_recalc() helper makes incorrect use of clk->enable_bit as a ready to use bitmap mask while it only provides the bit number. Fix it. Signed-off-by: Janusz Krzysztofik Acked-by: Tony Lindgren Signed-off-by: Arnd Bergmann Signed-off-by: Sasha Levin --- arch/arm/mach-omap1/clock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/mach-omap1/clock.c b/arch/arm/mach-omap1/clock.c index fa512413a471..b277409f303a 100644 --- a/arch/arm/mach-omap1/clock.c +++ b/arch/arm/mach-omap1/clock.c @@ -44,7 +44,7 @@ static DEFINE_SPINLOCK(clockfw_lock); unsigned long omap1_uart_recalc(struct clk *clk) { unsigned int val = __raw_readl(clk->enable_reg); - return val & clk->enable_bit ? 48000000 : 12000000; + return val & 1 << clk->enable_bit ? 48000000 : 12000000; } unsigned long omap1_sossi_recalc(struct clk *clk) -- 2.35.1