From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D47AD39FCE; Fri, 1 Mar 2024 01:33:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709256793; cv=none; b=dPW1Va2j+QeUXvK0YWj+mvRDOyBETbV+ruHf9xHGrXWGNp+p12Ai/PyUo/e2NhoqN/nB4QWyHk0FM5PKUxYHD5zJqHu3TfV2hsS8AXf3oRD2oRNk80VH7aLNrBYvjh7+fqMmr8VFQ9wpepaB7vALp1rBdwRp34u2jbGxOmFiU+Q= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709256793; c=relaxed/simple; bh=EPalguZMNI5Njq+cA0Z5vHIwAsvdVkw9Z6GsK4GJQw4=; h=Message-ID:Content-Type:MIME-Version:In-Reply-To:References: Subject:From:Cc:To:Date; b=kZxJMcbUL5KqgOb1h60k6G6iW1+qkAnU8vF38V8Xdp+deL8b0FVpXlussYuIsJXaWz6/+3EEqxrx+7LbzBhIhkfc88qOZ+6jEkfUMKJy3l7jxkQDWWk2ZmoE3L6GEbUDyIL26z6NbajTxLhODReg/32RYSHBANzvyuNeLEAeRMQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=sQdmN5Xf; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="sQdmN5Xf" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9C741C433C7; Fri, 1 Mar 2024 01:33:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1709256792; bh=EPalguZMNI5Njq+cA0Z5vHIwAsvdVkw9Z6GsK4GJQw4=; h=In-Reply-To:References:Subject:From:Cc:To:Date:From; b=sQdmN5XfBeohDiRuXg5jE9JTzQsZoaXW1+rWjcvDXhcqo0t0yVw0gar/D1ZB3nu26 cxMusPCGjm08abajYAE0U4MgNR/V1Pmdi6uNjsxzyN8Dvmd5v1OKTv8Mgn4oPmRvfY cvjHN8ZXEuY+1TRGf4c3uJXbrWDefmvYHzsal6HdPNkTd8tjf+5QLYwLgisTBAj8ZO zjE02xJbtMd+6zJ4HnXG+ifBOHEICZqbQ5+CqgFTI6n/2DO6bC9Of+e5wmBaoP7ljc 3DT7VI6hBdI1CPLWeH7NBcTakqp2ujqHIn6kmrYFNCRR56K4MdAY7f2PvhQOQiHn6s fNisvaChiDmVg== Message-ID: Content-Type: text/plain; charset="utf-8" Precedence: bulk X-Mailing-List: linux-mips@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable In-Reply-To: References: <20240227-mbly-clk-v8-0-c57fbda7664a@bootlin.com> <20240227-mbly-clk-v8-3-c57fbda7664a@bootlin.com> Subject: Re: [PATCH v8 03/10] clk: eyeq5: add platform driver, and init routine at of_clk_init() From: Stephen Boyd Cc: Gregory CLEMENT , Michael Turquette , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Thomas Bogendoerfer , Linus Walleij , =?utf-8?q?Rafa=C5=82_Mi=C5=82ecki?= , Philipp Zabel , Vladimir Kondratiev , linux-mips@vger.kernel.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Thomas Petazzoni , Tawfik Bayouk , linux-gpio@vger.kernel.org To: Andy Shevchenko , =?utf-8?q?Th=C3=A9o?= Lebrun Date: Thu, 29 Feb 2024 17:33:10 -0800 User-Agent: alot/0.10 Quoting Th=C3=A9o Lebrun (2024-02-29 07:40:25) > Hello, >=20 > On Thu Feb 29, 2024 at 3:59 PM CET, Andy Shevchenko wrote: > > On Thu, Feb 29, 2024 at 03:27:01PM +0100, Th=C3=A9o Lebrun wrote: > > > On Wed, Feb 28, 2024 at 03:33:29PM +0100, Th=C3=A9o Lebrun wrote: > > > > On Tue Feb 27, 2024 at 6:11 PM CET, Andy Shevchenko wrote: > > > > > On Tue, Feb 27, 2024 at 03:55:24PM +0100, Th=C3=A9o Lebrun wrote: >=20 > > 2) Still I see a benefit from using lo_hi_readq() and friends directly. >=20 > So it is: >=20 > u32 r0 =3D readl(base_plls + pll->reg64); > u32 r1 =3D readl(base_plls + pll->reg64 + sizeof(r0)); >=20 > vs: >=20 > u64 r =3D lo_hi_readq(base_plls + pll->regs64); > u32 r0 =3D r; > u32 r1 =3D r >> 32; >=20 > One is straight forward, the other uses an obscure helper that code > readers must understand and follows that with bit manipulation. >=20 Just use readq() and include the correct header please. We know what readq() is in the kernel.