Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp4099668imm; Mon, 30 Jul 2018 08:39:46 -0700 (PDT) X-Google-Smtp-Source: AAOMgpe2zya2tpQ6NRb5UJ5epN/ASfQXPP+jbDXkvpns3PVWP8/14qVSrhgT4UAHOE3m9C7e2SBW X-Received: by 2002:a63:d613:: with SMTP id q19-v6mr16808324pgg.327.1532965186917; Mon, 30 Jul 2018 08:39:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532965186; cv=none; d=google.com; s=arc-20160816; b=i0Q4YW2MFu6NoZYcMiorKteFmZwS1OwBI8A8+JaQRPL0+Ve0i50vbpBe0/Dqg821iM aR4n6eVvi4oyx2mQ8g4I1XekVn15uRgdAbevJ6Mcp+Z8NWzaD89J1WxjhQeKrDypAI34 oiaVa60GgIz7lWPBX3OPxcdzsfN1y/9SIrfNfGo0pr/0BY2ySuYGv322wPX8DAYXohUZ fDYJFcZaDuMvhNmGrYSACHqzBCEA1upmJ/BJG38n/sR1wygXLOQaW1QYkzA7GpGY8Aba sPm3WWKgnhxRLkzTbh7H++5gwLUjNq1FUaWp0lgGjfAhmViIeNDkzKXWZJAL30qb9jgy 0mUg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:date:cc:to:from:subject:message-id :arc-authentication-results; bh=MJrpMncK2GU9rax7L4OF32AfivllDe+oMXcGUSeiNtE=; b=nzjqSwgHpGkh9TfgYHJyH0IDXGfLP9+rptbOdhcpNx9oqT8WPXwksxfqZ4P5ExhqFX 1k8QVMRVVuXdHq6zn0GUAZ5KVat31d+rroPX3L/UkgLD9NwPJczFxni+iFItYEBVnDjG zzX7T6kgvDZ4espCOKGgweKW16JQdglCqDHWSRBsUwp+/thaaVWiOmnjyFUhU8MNXBom GT4418TXcnKdeQ3Gre0EKfxL77aWQOcOvUsYojCyZW4RdvMRimbM+V3Ocv8KlcaPSY6J w9+7O/sJDuQwYDxXqeLZe/wPDzKjh6ZOGcZVGh37qdNMQN3fB4duOk2uGXNIyDH+q+DT ZpNw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t5-v6si11503510pgs.52.2018.07.30.08.39.32; Mon, 30 Jul 2018 08:39:46 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727119AbeG3ROT (ORCPT + 99 others); Mon, 30 Jul 2018 13:14:19 -0400 Received: from metis.ext.pengutronix.de ([85.220.165.71]:49763 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726663AbeG3ROT (ORCPT ); Mon, 30 Jul 2018 13:14:19 -0400 Received: from lupine.hi.pengutronix.de ([2001:67c:670:100:3ad5:47ff:feaf:1a17] helo=lupine) by metis.ext.pengutronix.de with esmtp (Exim 4.89) (envelope-from ) id 1fkAFo-0002iT-QV; Mon, 30 Jul 2018 17:38:36 +0200 Message-ID: <1532965111.3471.14.camel@pengutronix.de> Subject: Re: [PATCH 0/9] Add Reset Controller support for Actions Semi Owl SoCs From: Philipp Zabel To: Manivannan Sadhasivam , Andreas =?ISO-8859-1?Q?F=E4rber?= Cc: mturquette@baylibre.com, sboyd@kernel.org, robh+dt@kernel.org, linux-clk@vger.kernel.org, liuwei@actions-semi.com, mp-cs@actions-semi.com, 96boards@ucrobotics.com, devicetree@vger.kernel.org, daniel.thompson@linaro.org, amit.kucheria@linaro.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, hzhang@ucrobotics.com, bdong@ucrobotics.com, manivannanece23@gmail.com, thomas.liau@actions-semi.com, jeff.chen@actions-semi.com, pn@denx.de, edgar.righi@lsitec.org.br, sravanhome@gmail.com Date: Mon, 30 Jul 2018 17:38:31 +0200 In-Reply-To: <20180730151131.GA28633@mani> References: <20180727184527.13287-1-manivannan.sadhasivam@linaro.org> <20180730151131.GA28633@mani> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.22.6-1+deb9u1 Mime-Version: 1.0 Content-Transfer-Encoding: 8bit X-SA-Exim-Connect-IP: 2001:67c:670:100:3ad5:47ff:feaf:1a17 X-SA-Exim-Mail-From: p.zabel@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2018-07-30 at 20:41 +0530, Manivannan Sadhasivam wrote: > Hi Andreas, > > On Mon, Jul 30, 2018 at 12:26:07PM +0200, Andreas Färber wrote: > > Hi Mani, > > > > Am 27.07.2018 um 20:45 schrieb Manivannan Sadhasivam: > > > This patchset adds Reset Controller (RMU) support for Actions Semi > > > Owl SoCs, S900 and S700. For the Owl SoCs, RMU has been integrated into > > > the clock subsystem in hardware. Hence, in software we integrate RMU > > > support into common clock driver inorder to maintain compatibility. > > > > Can this not be placed into drivers/reset/ by using mfd-simple with a > > sub-node in DT? > > > > Actually I was not sure where to place this reset controller driver. When I > looked into other similar ones such as sunxi, they just integrated into the > clk subsystem. So I just chose that path. But yeah, this is hacky! > > But this RMU is not MFD by any means. Since the CMU (Clock) and RMU (Reset) > are two separate IPs inside SoC, we shouldn't describe it as a MFD driver. Since > RMU has only 2 registers, the HW designers decided to use up the CMU memory > map. So, maybe syscon would be best option I think. What is your opinion? Using syscon seems cleaner than stuffing the regmap into owl_clk_desc. > Even if we go for syscon, we should place the reset driver within clk > framework as I can see other SoCs like Mediatek are doing the same. But again > I'm not sure! Me neither. If the CMU and RMU are really separate and only share the memory map, a syscon driver could live in drivers/reset without problems. It's only when there are interactions between clocks and resets that you really want to have the reset driver integrated with clk. regards Philipp