Received: by 2002:ab2:3350:0:b0:1f4:6588:b3a7 with SMTP id o16csp1485269lqe; Mon, 8 Apr 2024 10:06:05 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCURa7PJ3yqluHmn+kXpgUAkz1aSqLu2HCb3yevt2TnwDjvHWnYq7P4r+377kS7uN4ZGH0DnDp7/DzaoOQk1+5saM0AT8NZ/+ljvTUpB0w== X-Google-Smtp-Source: AGHT+IErSOOSy65sO+ssIE3OJLo5FTyQrUeQWNCAZIi5S9t5KJHj7vrcq2XP5lyAOg+ayzpiQ0X5 X-Received: by 2002:a05:620a:e01:b0:78a:3d2a:e0c with SMTP id y1-20020a05620a0e0100b0078a3d2a0e0cmr9559385qkm.8.1712595964776; Mon, 08 Apr 2024 10:06:04 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712595964; cv=pass; d=google.com; s=arc-20160816; b=zqtYPz9vQdyizBxiMtGmw/lBgYLsk/h1uMoQbPrx9mLX8JvaHV/hFks360639zrN56 nrYGfUfh/vEX4nTKqr33vOFELCiJRAG4E1Jfhp9Y2GT2Mgpz+AXwvm87D3pyctvR6dMk C9OPCh36oDuWbc4vnl2YVVAO8Ys8Sj4WdWX6mS/TddQWKgvm7KQtW7qppC6xHOs+K68y 0ooFn/jlgTHKLy4cCILl545c3weccINBiIulJSWJwg1o6USZjQvMhPvw7funjSxE9+cT yP5r3BOwwXGuBmwWZQgu8PlHnJnxSH/MPZC6ogCGiLfKNjMYTF2gpuNG0klU5GxpeUT3 TPzA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=N9mKisc7kUAlfuj0tQyymnxAGu/44U+CyciFpi92qvs=; fh=H1mbTwggVOL5LlL0HvS0rvzoiG0hyUoRjtoWweilSAs=; b=u0I+xjeb2KHZyIkT3kciEyePjhwqbo+ECSkpY9WCB1e7HQjW2vZmbjZ+1OMrCjaAjM A/XV/Ih6bqBIyOLDJZir0+86Ok30RGDxG/e4DiDJCTK4AvWDNEqFXtDc4cpmuaIVfAUX Jal2jpjQNFPRkvvC19Gjg4auRDtovfhs5xA9pGAEf96FrwNvTeS7dr9lS0m0YRecWThw MpwLeTedrU7FN6Xtlfq5S7IaquMELgIWMS0yd/zW/BkI/7ApSdPMnV8p1ccMEJccczA6 uqbG0WgkGTT56guaGo5XvnwKRXw+yG1FEnr46lLFxWsc3STfJLm33xw8PptFUtUjVNLO l5Uw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="aQnKFwi/"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-135724-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-135724-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id dy34-20020a05620a60e200b0078a39dc1566si8501436qkb.62.2024.04.08.10.06.04 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Apr 2024 10:06:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-135724-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="aQnKFwi/"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-135724-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-135724-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 3B4BC1C242B7 for ; Mon, 8 Apr 2024 17:06:04 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B59DB143876; Mon, 8 Apr 2024 17:05:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="aQnKFwi/" 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 D35B563CB; Mon, 8 Apr 2024 17:05:56 +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=1712595956; cv=none; b=cjHJylW6yxErerPOCs9N4Z2R4x0N/FcL6+TAJuq57xiBLqpadG5ebO4C7neBA8XKM2v/6pEHMgf97XtRZ+8G3uxs8C/QLfB13mBAFUh4lThqmNDEyEeuL0mi7pYoL1Om+yU7W432QpUw705ivUKXooCOtybtuAy8Gmt6twX2L2o= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712595956; c=relaxed/simple; bh=N9mKisc7kUAlfuj0tQyymnxAGu/44U+CyciFpi92qvs=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=pt6kPTFwfJwHd7x0LVV6ysmXO0/4YFNkk/XxQobnCC/9bbEOisZnLrAsJH6FlpDgiwuFuKgzAxYwjzQlg4kUEjGPynA8Acb1H7kFY+fTwWNKYNWhp1eKyMInPUVT1Ssle/rZVLn7qI0nFA0Lyo3OdNkYxUnceZk2q/KZy4k7w4s= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=aQnKFwi/; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 58149C43394; Mon, 8 Apr 2024 17:05:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1712595956; bh=N9mKisc7kUAlfuj0tQyymnxAGu/44U+CyciFpi92qvs=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=aQnKFwi/w1g3wdmNyQhIpuGFLXcUmr6oVZhG5pX06fCYUXGm42RPdOs3fIkTm9FJB 2oWpOlmpHd61jYuTxH90FtJvYt2ZY6GnJSYtMdrmmabJopcveQ/0QGAG4VSlDOUtiH LTfRD+HKuLVDiQw13H2BdUbBVReV3ZojEeh4pY9ANGnzQBH9XkXBUcU0Ai1NiAnrmK S7o2O5Dmj4vZuM9KoflqlL7b2KJ0tnAzevtzQQiAX2qmJr9Lq7gvjeK6/EhbJ3OuR0 87+IkiYe6wLYBwKmriNOgCo8r3he9usNatFiYjMwDmDxzczxwgTS4jlARt4FgKmTPX 28Jy7Df7xi3vg== Date: Mon, 8 Apr 2024 18:05:51 +0100 From: Conor Dooley To: Stephen Boyd Cc: Jan Dakinevich , Jerome Brunet , Philipp Zabel , Neil Armstrong , Michael Turquette , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Kevin Hilman , Martin Blumenstingl , linux-amlogic@lists.infradead.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [RFC PATCH v2 1/5] clk: meson: axg: move reset controller's code to separate module Message-ID: <20240408-numerator-escargot-a642507a598e@spud> References: <20240328010831.884487-1-jan.dakinevich@salutedevices.com> <20240328010831.884487-2-jan.dakinevich@salutedevices.com> <1j7chfiz8e.fsf@starbuckisacylon.baylibre.com> <13617b7a892424d2b024c725505a6f4f.sboyd@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="NSVO+VttCpAhjGMi" Content-Disposition: inline In-Reply-To: <13617b7a892424d2b024c725505a6f4f.sboyd@kernel.org> --NSVO+VttCpAhjGMi Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Apr 08, 2024 at 02:52:37AM -0700, Stephen Boyd wrote: > Quoting Philipp Zabel (2024-04-08 01:21:47) > > On So, 2024-04-07 at 19:39 -0700, Stephen Boyd wrote: > > > Quoting Jerome Brunet (2024-04-02 07:52:38) > > > >=20 > > > > On Thu 28 Mar 2024 at 04:08, Jan Dakinevich wrote: > > > >=20 > > > > > This code will by reused by A1 SoC. > > > >=20 > > > > Could expand a bit please ? > > > >=20 > > > > >=20 > > > > > Signed-off-by: Jan Dakinevich > > > >=20 > > > > In general, I like the idea. > > > >=20 > > > > We do have a couple a reset registers lost in middle of clocks and = this > > > > change makes it possible to re-use the code instead duplicating it. > > > >=20 > > > > The exported function would be used by audio clock controllers, but= the > > > > module created would be purely about reset. > > > >=20 > > > > One may wonder how it ended up in the clock tree, especially since = the > > > > kernel as a reset tree too. > > > >=20 > > > > I'm not sure if this should move to the reset framework or if it wo= uld > > > > be an unnecessary churn. Stephen, Philipp, do you have an opinion on > > > > this ? > > > >=20 > > >=20 > > > I'd prefer it be made into an auxiliary device and the driver put in > > > drivers/reset/ so we can keep reset code in the reset directory. > >=20 > > Seconded, the clk-mpfs/reset-mpfs and clk-starfive-jh7110-sys/reset- > > starfive-jh7110 drivers are examples of this. > >=20 > > > The auxiliary device creation function can also be in the > > > drivers/reset/ directory so that the clk driver calls some function > > > to create and register the device. > >=20 > > I'm undecided about this, do you think mpfs_reset_controller_register() > > and jh7110_reset_controller_register() should rather live with the > > reset aux drivers in drivers/reset/ ? >=20 > Yes, and also mpfs_reset_read() and friends. We should pass the base > iomem pointer and parent device to mpfs_reset_adev_alloc() instead and > then move all that code into drivers/reset with some header file > exported function to call. That way the clk driver hands over the data > without having to implement half the implementation. I'll todo list that :) --NSVO+VttCpAhjGMi Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCZhQj7wAKCRB4tDGHoIJi 0gFIAQD54FHoGcK4A8nGbf3dqzWlaU2n5wMolumXHO/fSI4UwwEAk8OApAyTnQ1X FyTcLhrKypXfSlUop6vr4TG64K+fwgY= =6FkH -----END PGP SIGNATURE----- --NSVO+VttCpAhjGMi--