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 662CFCF6D25 for ; Wed, 2 Oct 2024 13:24:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type:MIME-Version: Message-ID:Date:References:In-Reply-To:Subject:Cc:To:From:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=lFcpWszJZ1PatGkbcS9TyyzC+Vcri7WA2fnl3Lvu/mU=; b=GuXxiksqF8o8tfKO21btvwmQqN zLwejZZvNRFR0LwV4zobYrmbJ67z8/ygl4FCMmPqMwnVYhKVcC/swIsBXmIOXE0lMgqr5D/iSu8vc pqIoEaWBqnWPVPahY+azd/qFBTwLGrsuXp4IQ03we2nKoIGDJH7wWpLMmUE+8akWZJ/0tYu/c9XTD GVm4QX61J7onCrwb8TaT7h7sq7HmCK45Jq+fGeJjzWYMKHxDZVt2YrJ1Gq7RXL+D57k01p33r1+HY RCcl79qRg2tHX/OC0Uu12gQouXCuMB7JzRibEa3iB74Gu1DIN3pCG0F660RPtLD1+2IE3mjK8F+PK KQ4ikXOw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1svzKh-000000066dA-20bx; Wed, 02 Oct 2024 13:23:59 +0000 Received: from mail-wr1-x42c.google.com ([2a00:1450:4864:20::42c]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1svzI7-000000065yU-1RXI for linux-arm-kernel@lists.infradead.org; Wed, 02 Oct 2024 13:21:22 +0000 Received: by mail-wr1-x42c.google.com with SMTP id ffacd0b85a97d-37cd8a5aac9so2581441f8f.2 for ; Wed, 02 Oct 2024 06:21:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1727875277; x=1728480077; darn=lists.infradead.org; h=mime-version:message-id:date:references:in-reply-to:subject:cc:to :from:from:to:cc:subject:date:message-id:reply-to; bh=lFcpWszJZ1PatGkbcS9TyyzC+Vcri7WA2fnl3Lvu/mU=; b=14/7jBQ1eMmPJMykKeIQUxlyABWQFCS/3T0uaoiV+LE06ii+v0/7A8T5uDs1fJbaQu v2bWYdC8xCya+u9duO5r184NcHEDaZSWgse3T1o25uKZYnK7sdy3I+QnKB/c0KHugZhq x7+YRt7yQWH+ziLTyUyyL/bk1WoWcjdgQS+6Qmm7nRrLYacyVw60LO4gaYrSYpfMMtWE sJUtfYBh0CmoWC96KybItCBqEer/3sYMgHM7xxLXb/dcElxufvXREZk8IL5jf5YzVQpU vlblxJ7vfZmA3QGqO/TvixP9xfSB7O5EeC86txGiUP429db5E/KsnDUTOaZyXNYbdpKv +iSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1727875277; x=1728480077; h=mime-version:message-id:date:references:in-reply-to:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=lFcpWszJZ1PatGkbcS9TyyzC+Vcri7WA2fnl3Lvu/mU=; b=WQ2C3oX0FyCqjQFv1q2zpn8PatRyys+bz+/IB1FHRbTYwobWUjzDl0Z74L3vnadBy4 HT42NQtBsGQskWL+lOOvUxhznWRuGHss5LW/yi5TVkcSikzcY0nklainCagr3jS2sG+z O5nrNizgBPRKTanEhwnHgnP6psxmPa//8KXrfjUFfxXh6lLNm7gCLBmn5N/DVunBLBGb asDHYM8C6iWcg+e6Fo/H5yID0h39YGWsSlWfvJ6RxkZx8V+Q6v7iFOgBwpJpUi2oCc2W YUfFtjVpV1LS09afObogWH4aFTXzzQgKGefPk0n54IbuI1fJHNH/tCL1V341NZwNublc /oVw== X-Forwarded-Encrypted: i=1; AJvYcCWIboNWANpiBk7va1UK+NM7OV9WJSw6t0UFQkyshy8/7QVWJ5vEC21E7iGfeVGqCg7T41WKGWlwiZun6pj2+r3O@lists.infradead.org X-Gm-Message-State: AOJu0Yz479ykg/8tmWbacN+eI/NkInwjF79DhvKS9GjIEk7SLkxBImTJ 7usOSYrq5OXkpOFo9BMdJwAafJKPBuIme/Ky4atg70TxqLu+oLALb5jJXJFh2gs= X-Google-Smtp-Source: AGHT+IGtesUnwfGBBqJcevG7GXZS5uKes3Sg3LCKiml2f2atNex2ZhNMu7Ko3bo7Z2LB1PvLr1K3nw== X-Received: by 2002:a05:6000:e4e:b0:37c:c9b5:5573 with SMTP id ffacd0b85a97d-37cfb8b57d6mr1834260f8f.17.1727875277309; Wed, 02 Oct 2024 06:21:17 -0700 (PDT) Received: from localhost ([2a01:e0a:3c5:5fb1:eced:891a:c2b9:3db5]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-37cd575de73sm13842727f8f.115.2024.10.02.06.21.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 02 Oct 2024 06:21:16 -0700 (PDT) From: Jerome Brunet To: Neil Armstrong Cc: Conor Dooley , linux-kernel@vger.kernel.org, Conor Dooley , Daire McNamara , pierre-henry.moussay@microchip.com, valentina.fernandezalanis@microchip.com, Michael Turquette , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Jassi Brar , Lee Jones , Paul Walmsley , Palmer Dabbelt , Albert Ou , Kevin Hilman , Martin Blumenstingl , Philipp Zabel , linux-riscv@lists.infradead.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v1 08/11] clk: move meson clk-regmap implementation to common code In-Reply-To: <2b49c4df-a34a-42c5-8d44-9e47da630fe8@linaro.org> (Neil Armstrong's message of "Wed, 2 Oct 2024 13:20:44 +0200") References: <20241002-private-unequal-33cfa6101338@spud> <20241002-hula-unwashed-1c4ddbadbec2@spud> <2b49c4df-a34a-42c5-8d44-9e47da630fe8@linaro.org> Date: Wed, 02 Oct 2024 15:21:16 +0200 Message-ID: <1jwmiqsks3.fsf@starbuckisacylon.baylibre.com> MIME-Version: 1.0 Content-Type: text/plain X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241002_062119_540526_3F27E0FB X-CRM114-Status: GOOD ( 20.87 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Wed 02 Oct 2024 at 13:20, Neil Armstrong wrote: > On 02/10/2024 12:48, Conor Dooley wrote: >> From: Conor Dooley >> I like this one better than qualcomms and wish to use it for the >> PolarFire SoC clock drivers. >> Signed-off-by: Conor Dooley >> --- >> drivers/clk/Kconfig | 4 ++ >> drivers/clk/Makefile | 1 + >> drivers/clk/{meson => }/clk-regmap.c | 2 +- >> drivers/clk/meson/Kconfig | 46 +++++++++---------- >> drivers/clk/meson/Makefile | 1 - >> drivers/clk/meson/a1-peripherals.c | 2 +- >> drivers/clk/meson/a1-pll.c | 2 +- >> drivers/clk/meson/axg-aoclk.c | 2 +- >> drivers/clk/meson/axg-audio.c | 2 +- >> drivers/clk/meson/axg.c | 2 +- >> drivers/clk/meson/c3-peripherals.c | 2 +- >> drivers/clk/meson/c3-pll.c | 2 +- >> drivers/clk/meson/clk-cpu-dyndiv.c | 2 +- >> drivers/clk/meson/clk-dualdiv.c | 2 +- >> drivers/clk/meson/clk-mpll.c | 2 +- >> drivers/clk/meson/clk-phase.c | 2 +- >> drivers/clk/meson/clk-pll.c | 2 +- >> drivers/clk/meson/g12a-aoclk.c | 2 +- >> drivers/clk/meson/g12a.c | 2 +- >> drivers/clk/meson/gxbb-aoclk.c | 2 +- >> drivers/clk/meson/gxbb.c | 2 +- >> drivers/clk/meson/meson-aoclk.h | 2 +- >> drivers/clk/meson/meson-eeclk.c | 2 +- >> drivers/clk/meson/meson-eeclk.h | 2 +- >> drivers/clk/meson/meson8-ddr.c | 2 +- >> drivers/clk/meson/meson8b.c | 2 +- >> drivers/clk/meson/s4-peripherals.c | 2 +- >> drivers/clk/meson/s4-pll.c | 2 +- >> drivers/clk/meson/sclk-div.c | 2 +- >> drivers/clk/meson/vclk.h | 2 +- >> drivers/clk/meson/vid-pll-div.c | 2 +- >> .../meson => include/linux/clk}/clk-regmap.h | 0 >> 32 files changed, 53 insertions(+), 53 deletions(-) >> rename drivers/clk/{meson => }/clk-regmap.c (99%) >> rename {drivers/clk/meson => include/linux/clk}/clk-regmap.h (100%) >> > > > I don't have objections, but I think Stephen didn't like the idea > a few years ago, but perhaps it has changed... > > Anyway, take my: > Acked-by: Neil Armstrong We had a similar discussion 3y ago indeed: https://lore.kernel.org/linux-clk/162734682512.2368309.12015873010777083014@swboyd.mtv.corp.google.com/ There are needs for a common regmap backed clocks indeed, but allowing meson flavored regmap clocks to spread in the kernel was not really the prefered way to do it. IIRC, Stephen's idea was more the bring regmap support in clk-gate.c, clk-mux, etc ... I'm not quite sure how make iomem and regmap co-exist in a manageable/maintainable way within those drivers (without adding yet another level of abstraction I mean) ? Silently creating a regmap maybe ? but that's probably a bit heavy. I did not really had time to dig more on this, I guess no one did. I don't really have a preference one way or the other but if it is going to be exposed in 'include/linux', we need to be sure that's how we want to do it. With clocks poping in many driver subsystems, it will difficult to change afterward. > > Thanks, > Neil -- Jerome