Message ID | 20240830130218.3377060-1-claudiu.beznea.uj@bp.renesas.com (mailing list archive) |
---|---|
Headers | show
Return-Path: <linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org> 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 44D35CA0FEB for <linux-arm-kernel@archiver.kernel.org>; Fri, 30 Aug 2024 13:10:09 +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-Transfer-Encoding: MIME-Version:Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-Type: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=W6nGKHTlsaYnNPo28i56acvgAz+0LehleKY7G1KLCDM=; b=erkXodDEMeoz+UkYubUhWEsDdD rin6dswwG3RcV5m6w6C2zJpT4zlBj/dGFIE/QINuRgsfQgPKrtVkwGG/vae2jb4e/ngrhzdSlOh3N Va2sVf6p183ojFEZJ/DJSQvep1ISnsFbqM9bPSeZGpqWYjV3wyUa3A1SkmG7m/2gLTgRLdG7+xjDh RhfVjvKOJze7f/yjqzVhZaz6wlhO0reWBfIMgWgWAVyv8ozowfc1qjZE2qxquWm74VlPUJAFmvR5t vBc2urhGB0w2n6h279G1fzhWGl5ITHjLUwIWFCl2hm1ThIaHuNkIcdErjaIn4b8TIN2FAMchVcqDj a2tj/+iA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sk1O0-00000006MHi-44xy; Fri, 30 Aug 2024 13:09:56 +0000 Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sk1Gq-00000006JiD-2rul for linux-arm-kernel@lists.infradead.org; Fri, 30 Aug 2024 13:02:34 +0000 Received: by mail-wm1-x334.google.com with SMTP id 5b1f17b1804b1-428178fc07eso15110465e9.3 for <linux-arm-kernel@lists.infradead.org>; Fri, 30 Aug 2024 06:02:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tuxon.dev; s=google; t=1725022951; x=1725627751; darn=lists.infradead.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=W6nGKHTlsaYnNPo28i56acvgAz+0LehleKY7G1KLCDM=; b=KSn96+4JQHAL4Z36o35mDQETmZsWENyUt9OmjN34KF1N7gqmz5N2NreBnnq/8Twrko fKo83WHtM4ELbOMeYVTcHuhapZnjANGwMpOpwJOmzHqLTe8o+Qw/kYAlRzAfRSe2yLlA iWU68K+5+ZwKmWBKo7HikxwNvcfI8Q7XskE//bMv50KdIRqTG3/V4bbmW1Nz3zlNtic7 vMu60g19S3OLKWMOyDzO4g+K2QjaOMg1yqvrHbE7VHAmOheiSD/fhe0+5EHA9FvG2TLZ gmLwc7YRSOm85QfH5GYvlbG8o/X1lWNxhRTEEm50HeLaEvNlZq53IcpQYXYjUQxwDOX5 +eLQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1725022951; x=1725627751; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=W6nGKHTlsaYnNPo28i56acvgAz+0LehleKY7G1KLCDM=; b=pZThSEZmKVoVPW1si4HZEqxopEytQn1jMjt4JnuSJLHxZ09iugs4K/jFU0oKWViB8o p3hjHBCtPI4z9z5KM23dDJsQK/aGywB+WUkqMlDHimeXtOkdUEDyPne8aPmOPhnKlo/t pN1jP5TLD6drix5CbPFXgdgUVSw0hh37jZLkRW5V1qMFwlpsPgTJ/3H6n4fzZdchaHUQ 1wlCFYZBOVhcRb5Ws2yBeoXQRHS7owrTsqt0s3YjzI8enP4y1T0cl1V9H2Co2XODQTJN uWnfj56sHzpIc3iJxQM1eCXfVG8VovyYw+Mj2HP5yKLJnWExt/rE52srTBhzjp/DUme0 YR3g== X-Forwarded-Encrypted: i=1; AJvYcCXPizDV0ulCxT5aVOVebGbGIHOw1gnXd1kGXZDtGm34RyzSrtoAmqKilhFZ+NPdNbKD6pUEXlLQHqFXYHhQfqk1@lists.infradead.org X-Gm-Message-State: AOJu0YylvreOPTglmNMJB+aTgoPJ6OUCYFtLbXUhfh2HRKGMDeHOY/iS kyewTEHZ/tpEw65LDgJf0Xz9aDdscban5oZ3xj7MfWG1S4g5vSAMBR/nfXZMrPU= X-Google-Smtp-Source: AGHT+IFf90G7UI94oipmrsRGbRwetRqyjDJaZ1p7GkAjuXdmmZqJgfa2LrZRlu4lQdJfeM0ibK0EqQ== X-Received: by 2002:a05:600c:3b89:b0:426:6688:2421 with SMTP id 5b1f17b1804b1-42bb02ee44amr47400445e9.11.1725022950478; Fri, 30 Aug 2024 06:02:30 -0700 (PDT) Received: from claudiu-X670E-Pro-RS.. ([82.78.167.144]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba642594dsm80361785e9.47.2024.08.30.06.02.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 Aug 2024 06:02:30 -0700 (PDT) From: Claudiu <claudiu.beznea@tuxon.dev> X-Google-Original-From: Claudiu <claudiu.beznea.uj@bp.renesas.com> To: geert+renesas@glider.be, mturquette@baylibre.com, sboyd@kernel.org, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org, alexandre.belloni@bootlin.com, magnus.damm@gmail.com, p.zabel@pengutronix.de Cc: claudiu.beznea@tuxon.dev, linux-renesas-soc@vger.kernel.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-rtc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Claudiu Beznea <claudiu.beznea.uj@bp.renesas.com> Subject: [PATCH v3 00/12] Add RTC support for the Renesas RZ/G3S SoC Date: Fri, 30 Aug 2024 16:02:06 +0300 Message-Id: <20240830130218.3377060-1-claudiu.beznea.uj@bp.renesas.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240830_060232_905461_6A78702A X-CRM114-Status: GOOD ( 21.69 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: <linux-arm-kernel.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-arm-kernel/> List-Post: <mailto:linux-arm-kernel@lists.infradead.org> List-Help: <mailto:linux-arm-kernel-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=subscribe> Sender: "linux-arm-kernel" <linux-arm-kernel-bounces@lists.infradead.org> Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org |
Series |
Add RTC support for the Renesas RZ/G3S SoC
|
expand
|
From: Claudiu Beznea <claudiu.beznea.uj@bp.renesas.com> Hi, On the Renesas RZ/G3S SoC the RTC clock is provided by the VBATTB IP. A 32 KHz crystall oscillator could be connected to the VBATTB input pins. The logic to control this clock (and pass it to RTC) is inside the VBATTB IP. For this, the clk-vbattb driver was added (patches 01-04/12). Patches 05-06/12 add the RTC driver. Patches 07-10/12 update the device trees with proper nodes to enable RTC. Patches 11-12/12 enable proper config flags for RTC to work on RZ/G3S SoC. Merge strategy, if any: - clock patches (01-04/12) need to go though the same tree because of patch 04/12 using the devm_clk_hw_register_gate_parent_hw() introduced in patch 03/12 - RTC patches (03-04/12) can go though RTC tree - DTS and defconfig patches can go though Renesas tree Thank you, Claudiu Beznea Changes in v3: - dropped patches "mfd: renesas-vbattb: Add a MFD driver for the Renesas VBATTB IP" - added patches: -- dt-bindings: clock: r9a08g045-vbattb: Add clock IDs for the VBATTB controller -- clk: linux/clk-provider.h: Add devm_clk_hw_register_gate_parent_hw() - moved Documentation/devicetree/bindings/mfd/renesas,r9a08g045-vbattb.yaml to Documentation/devicetree/bindings/clock/renesas,r9a08g045-vbattb.yaml - addressed review comments - per patch changes are listed in individual patches Changes in v2: - dropped patch "clk: renesas: r9a08g045: Add clock, reset and power domain support for the VBATTB IP" as it was already integrated - kept only a documentation file for both VBATT MFD and clock drivers as suggested - addressed review comments - used cleanup.h lock helpers - update startup sequence for the RTC driver - switch to 24 hours mode on the RTC driver - fixed range for the RTC driver - added a generic compatible for the RTC driver as this will also be used by RZ/V2H - used clkin/xin clock names for the VBATTB clock driver to determine if bypass should be configured on registers instead of having dedicated DT property - added mfd driver for VBATTB - updated Kconfig flag names to include vendor name - removed DT node labels from Documentation files - used items to describe the interrupts and clocks Claudiu Beznea (12): dt-bindings: clock: renesas,r9a08g045-vbattb: Document VBATTB dt-bindings: clock: r9a08g045-vbattb: Add clock IDs for the VBATTB controller clk: linux/clk-provider.h: Add devm_clk_hw_register_gate_parent_hw() clk: renesas: clk-vbattb: Add VBATTB clock driver dt-bindings: rtc: renesas,rzg3s-rtc: Document the Renesas RTCA-3 IP rtc: renesas-rtca3: Add driver for RTCA-3 available on Renesas RZ/G3S SoC arm64: dts: renesas: r9a08g045: Add VBATTB node arm64: dts: renesas: r9a08g045: Add RTC node arm64: dts: renesas: rzg3s-smarc-som: Enable VBATTB arm64: dts: renesas: rzg3s-smarc-som: Enable RTC arm64: defconfig: Enable VBATTB clock arm64: defconfig: Enable Renesas RTCA-3 flag .../clock/renesas,r9a08g045-vbattb.yaml | 81 ++ .../bindings/rtc/renesas,rz-rtca3.yaml | 86 ++ MAINTAINERS | 8 + arch/arm64/boot/dts/renesas/r9a08g045.dtsi | 36 + .../boot/dts/renesas/rzg3s-smarc-som.dtsi | 13 + arch/arm64/configs/defconfig | 2 + drivers/clk/renesas/Kconfig | 4 + drivers/clk/renesas/Makefile | 1 + drivers/clk/renesas/clk-vbattb.c | 204 ++++ drivers/rtc/Kconfig | 10 + drivers/rtc/Makefile | 1 + drivers/rtc/rtc-renesas-rtca3.c | 892 ++++++++++++++++++ include/dt-bindings/clock/r9a08g045-vbattb.h | 13 + include/linux/clk-provider.h | 18 + 14 files changed, 1369 insertions(+) create mode 100644 Documentation/devicetree/bindings/clock/renesas,r9a08g045-vbattb.yaml create mode 100644 Documentation/devicetree/bindings/rtc/renesas,rz-rtca3.yaml create mode 100644 drivers/clk/renesas/clk-vbattb.c create mode 100644 drivers/rtc/rtc-renesas-rtca3.c create mode 100644 include/dt-bindings/clock/r9a08g045-vbattb.h