Received: by 2002:a5d:9c59:0:0:0:0:0 with SMTP id 25csp2124529iof; Tue, 7 Jun 2022 20:32:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzvZY5mraPT0HUCbmpJu1WvfKR/YCCJ7QFVXePLv8aTdWEIwtu6EfF7ifgkw0HrX4B/rkVF X-Received: by 2002:aa7:9e9c:0:b0:51b:e1b8:271c with SMTP id p28-20020aa79e9c000000b0051be1b8271cmr25369799pfq.73.1654659167987; Tue, 07 Jun 2022 20:32:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654659167; cv=none; d=google.com; s=arc-20160816; b=nXJWWkSF3IDKdaddnzBkD3wLTRy8aaM29ujc2R2uHuXLPj/zlpKvZ/0QRg9Y0Y1n2b 5SvUR8flJyc0nYZpXNFIzQLgJYpKeAxiOhCskOlKIG28iVkLPXTjp06/E8Wlq891LwW9 lybUfbCnl5lVoq3xbuUTnHCiGbzMl2xeB17IIDBfUqZCGaHaGOFBCZ8YJXHFvQoRxZ6e BNOoqqVVAM3Aq1JECCZFZnj+sCNuDF2JEAlKxAhzB8TOpX4Vm08xOsDzioBXG9HFwaj6 LQCrPXWjoGsbua+wFN2fzz+i50OU/vPMDSqnssY3InUVaDoyJtkGJ2QKmQJ+USoX1rkM 1lNw== 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=gTJ+oMXNpOUsxe27mPao7VQNTP3Ih2sXjgicyg33UnU=; b=iFo3YvbY0qexvNWzAgJr5KcZo7rWScbjtrp0SSpCY15HjgTMeCUYgnLJFbXLXOWX2l ECDVJPUZV1sjvj+CkMa5Rp1ruT5wwAMewpqMYyG+10RhISm93vcu0BXpY9UsoobROCBY EXEYBegHB3WSUYS3mV+Ix8DjwA5ebEwoMolQ0GP0P32fe+sDDfc7eDvTvH66nybhJfuC QqQSqUyOZW2xluH0/Sfzyzz3pm4vIKM7Zqh1/n8L3I/79rVlZIalXpYz8IU4kUCPQ0Yi jJ8apP/9Xz+wET55S8i/AGCu9RgBOqgiQEX50B40hdChNIYSwHbA+CD0RUcwpWdgIW2J 4BWg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=kta9bq+M; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 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 lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id a8-20020a170902900800b00163e1c910dbsi25108090plp.13.2022.06.07.20.32.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 20:32:47 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=kta9bq+M; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 1AEA3178544; Tue, 7 Jun 2022 19:42:45 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1382028AbiFGWW2 (ORCPT + 99 others); Tue, 7 Jun 2022 18:22:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54912 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1380670AbiFGVQk (ORCPT ); Tue, 7 Jun 2022 17:16:40 -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 F0EC621F99D; Tue, 7 Jun 2022 11:55:58 -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 3DBD5CE244E; Tue, 7 Jun 2022 18:55:57 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 41CCFC385A2; Tue, 7 Jun 2022 18:55:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1654628155; bh=XHRtkpxftbgTm/PySu+8nLF6MiAvmFtE9vRGXyrzS1U=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kta9bq+MQSo4wGAbJpUrUUWT824c8gfr6NO5dj1Wn7rQnUCP0TD4XrkVmVcMWulcw r2sNA8MusyeS/iUNcgnSoVmtkvbZ5TzTRsus2BwpFf6KI7GVBLF0Pr3LgwY8v1VO/r I/3NBu8fTInuCPX1DDcPmixHH3zKMhcrsrWHazYg= 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 5.18 225/879] ARM: OMAP1: clock: Fix UART rate reporting algorithm Date: Tue, 7 Jun 2022 18:55:43 +0200 Message-Id: <20220607165009.385151259@linuxfoundation.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220607165002.659942637@linuxfoundation.org> References: <20220607165002.659942637@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=-3.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 9d4a0ab50a46..d63d5eb8d8fd 100644 --- a/arch/arm/mach-omap1/clock.c +++ b/arch/arm/mach-omap1/clock.c @@ -41,7 +41,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