From mboxrd@z Thu Jan 1 00:00:00 1970 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 22236C9EC93 for ; Mon, 12 Jan 2026 13:49:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=J6TRzVxMIT9tZBiZFkXn1MifDLvVYg4muxDLqjFnHKE=; b=0wLTY7nCbs0cG2 mZCIAPwcTmZn2oPlNBT1xn7prE9IFiNiqwT6tDuYU1gzC3WaUS796ox88SIJmS4i7i5NNnYopBlBq PpxJsPi54UX4RmsIexZIkVevIfqqe+VzdnIrqelZm9uJh4mxfOZd0Av5Q6ZqnHFAgxW2gnwn0+qBj pBxBZYFtJO6YTm5RFHODuSeVHIjWRjRxKnVsVHEXu5n5o3E51lfKjFrBd1dTQv2XGj6al5VXF7wQX b6KiysH7rzHxtw2edCaUvq7Vx0k/3g6ZbU8+Abq19D9gvv+bs5eqzfC6ocMT2cl22pVji/IKPfPbb l1odqq3B2UkqZMVBvdUg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98.2 #2 (Red Hat Linux)) id 1vfIIQ-00000005RjG-1lRt; Mon, 12 Jan 2026 13:49:26 +0000 Received: from mgamail.intel.com ([198.175.65.13]) by bombadil.infradead.org with esmtps (Exim 4.98.2 #2 (Red Hat Linux)) id 1vfIIF-00000005RSK-4Akp; Mon, 12 Jan 2026 13:49:17 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1768225756; x=1799761756; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=ZqRF2S+uC/la4xASlNwAVf8XwHR045VHyV+nkWo2bqE=; b=oHhFFFOVUZsc288H224CdO9qpTWUTitU832Nyqjela4CxSx+4uHNo+0s uaw2CKXwUc4+O621IXOvAy7OYxI/lJWGyU06gsc2Xl1XhORTS4XrdYECa eRDKrX2/dJpGRBAKShOVsvXdAV6LDR1PB3w+zQd2bPjWWNk/H/TLx7BSu JZ+wL4cPrwx1cntcmLZqxYD4qwuGV0BbF5rR/VRew904b40H4ZYIgpqLb EBEeZIAp+Yp4ptDor1hmqEobAWyXXcDzp5C0o2cXVgIh7QIIfoVc8Pf3t F1VW1UdKcFK45PDUEYy1cC9y2zbXbSZDiaUrIQjE2k8B9H33ZjCOlyMao g==; X-CSE-ConnectionGUID: +hR+iq0RTp2kt971Shn+rA== X-CSE-MsgGUID: MqmKGRKVRv6KYi/cKspoIQ== X-IronPort-AV: E=McAfee;i="6800,10657,11669"; a="80604534" X-IronPort-AV: E=Sophos;i="6.21,221,1763452800"; d="scan'208";a="80604534" Received: from fmviesa005.fm.intel.com ([10.60.135.145]) by orvoesa105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Jan 2026 05:49:16 -0800 X-CSE-ConnectionGUID: 09zSswo8RW2YuLa4zP79hA== X-CSE-MsgGUID: iW3vkA1mTMqjQfUAGX7uIg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.21,221,1763452800"; d="scan'208";a="208568103" Received: from black.igk.intel.com ([10.91.253.5]) by fmviesa005.fm.intel.com with ESMTP; 12 Jan 2026 05:49:12 -0800 Received: by black.igk.intel.com (Postfix, from userid 1003) id CA8B5A2; Mon, 12 Jan 2026 14:49:06 +0100 (CET) From: Andy Shevchenko To: Andi Shyti , Andy Shevchenko , Wolfram Sang , Qianfeng Rong , linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-rockchip@lists.infradead.org Cc: Khalil Blaiech , Asmaa Mnebhi , Andi Shyti , Qii Wang , Matthias Brugger , AngeloGioacchino Del Regno , Linus Walleij , Heiko Stuebner , Patrice Chotard , Ard Biesheuvel Subject: [PATCH v1 6/7] i2c: st: Use HZ_PER_GHZ constant instead of plain number Date: Mon, 12 Jan 2026 14:46:14 +0100 Message-ID: <20260112134900.4142954-7-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.50.1 In-Reply-To: <20260112134900.4142954-1-andriy.shevchenko@linux.intel.com> References: <20260112134900.4142954-1-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20260112_054916_092976_52A3EE0F X-CRM114-Status: GOOD ( 10.51 ) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org Use defined constant to avoid the possible mistakes and to provide an additional information on the units. Signed-off-by: Andy Shevchenko --- drivers/i2c/busses/i2c-st.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/i2c/busses/i2c-st.c b/drivers/i2c/busses/i2c-st.c index 97d70e667227..751ea421caaf 100644 --- a/drivers/i2c/busses/i2c-st.c +++ b/drivers/i2c/busses/i2c-st.c @@ -20,6 +20,7 @@ #include #include #include +#include /* SSC registers */ #define SSC_BRG 0x000 @@ -285,7 +286,7 @@ static void st_i2c_hw_config(struct st_i2c_dev *i2c_dev) writel_relaxed(val, i2c_dev->base + SSC_CTL); rate = clk_get_rate(i2c_dev->clk); - ns_per_clk = 1000000000 / rate; + ns_per_clk = HZ_PER_GHZ / rate; /* Baudrate */ val = rate / (2 * t->rate); -- 2.50.1 _______________________________________________ Linux-rockchip mailing list Linux-rockchip@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-rockchip