Message ID | 20240716103025.1198495-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 23EA5C3DA59 for <linux-arm-kernel@archiver.kernel.org>; Tue, 16 Jul 2024 10:31:10 +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=N2oAUOUIr8Inm5CAOgiH6h0kthoIy+ddKKLth4dhl9c=; b=hCRvwluk7+08Z4ZzuHdp1X6P0n HRrc9wW3UYhOUJrK42Eu5awSX4wnXpFp6aWtwaytY2dYAr/URa2Hkfw2qq7hx83C1RO3W5yXz2GYZ N2B5XH4cEwEg2ZPYFaDxMGx2Q9JhQZIAR2qf/w75XXl/8VB2oADTElvRTUrswzwUNWFOKxA0qKcpT wI/te5qvWteZVA3iuGyBBj88IHsplDqN/YReGqsVHyNiHm5Y8Jr0ZHCnKlzkOvEJ19vqNd2Hmx+xW JqakxORBvTtOr6MBEBSJRMigFClCh4RYGHRMhC0ljs5H4FWwPcw/vdybzFrWkDF1oXSlLP/rA3M6m kej4d/Rg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sTfSW-0000000A2aW-0og7; Tue, 16 Jul 2024 10:31:00 +0000 Received: from mail-wr1-x42f.google.com ([2a00:1450:4864:20::42f]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sTfS9-0000000A2Pe-33wK for linux-arm-kernel@lists.infradead.org; Tue, 16 Jul 2024 10:30:39 +0000 Received: by mail-wr1-x42f.google.com with SMTP id ffacd0b85a97d-368255de9ebso359699f8f.1 for <linux-arm-kernel@lists.infradead.org>; Tue, 16 Jul 2024 03:30:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tuxon.dev; s=google; t=1721125836; x=1721730636; 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=N2oAUOUIr8Inm5CAOgiH6h0kthoIy+ddKKLth4dhl9c=; b=ZuUbp3TyVPmGfqopRHCXXWFqvNmst4r6XZTSjaiPMRlQReNA89bND1xuqxaBH6s1y+ KswpSsNW/SzFDR9zrTEIc9y+0nN6pNxc9Tx3+rCD7a5VAnnR2fcZxzE9WrZI4b9MJ0mX 7+m9UlXEkKimZz9hvmf0l5HcwhsFyRi5oolW6wsspmynGDHey103bseZIDRsKUuOH+sK NekuxrzAZt56f0LlVOlBTjAwsIrC/asdDVhduPXfNpl9mPKPx5C50DumV6alf6guOY12 Zt6hBnz1xUjEX3GF5TmokUxdzAuX3ZHw2fWV1WZWcdYYRx+yRicfIvPPVLu3Vx/A0dda VrkA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721125836; x=1721730636; 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=N2oAUOUIr8Inm5CAOgiH6h0kthoIy+ddKKLth4dhl9c=; b=Zns56EnQsjiB4kkyamoctho4yRjHVAZWvBd62vdIyjLL6pc3nqIR0QnR1owyUqtGdW 2rAeTD9rIC/RZ+AnvzvLe6eprF0/FsLn1F6CzIe23Ko/zth65elKyznViBBeLlgKfWPl JvXe6g6SGb4CkC87RZha9TWZOjtma47+qlhCiZl1jk+HPG1TKg2mOemyLim6DmQB55uI VACKLJouxfTlD/f+wS8CFDTo93ZTUV5dv6wRNUmc57zjSZdHkuZVoiF5Fh+hc490IaQX lmEdtPUEIMDRVKvxSQqS5ov3gePslHu0B3HH7tsWXANAqBbg/LQn/ca7ISUbInzxancF wUIA== X-Forwarded-Encrypted: i=1; AJvYcCWRD0oDjtLLRt0ESAy9n/PWYH+8qsreYuxhcKpZKzc2Aq0eBUuZXx0oA0Oz3mPDC5vn7CPqIVVR4XDI/hU0OyDK7mE/k4xQiLFCCgrQsmhiZEADrts= X-Gm-Message-State: AOJu0YxUTtU9Ujk8++i6WcZiuhpxbRWswbkVZTinWxTuddb404yfLpHP lH6W4csUnoKL1owx1DsbI79mzrch9Tu36ZR0I20Ni7U7p5aJbhJh3LUpaiy8C0g= X-Google-Smtp-Source: AGHT+IFfQhmkb59uH7LLa18F1SN7rqCnC4h7YO13ztbZBrn/+rB64CFv3oFG71YVR5qVnFq44xDcDA== X-Received: by 2002:a5d:62c8:0:b0:366:ea4a:17ec with SMTP id ffacd0b85a97d-368273575b2mr1107731f8f.2.1721125835619; Tue, 16 Jul 2024 03:30:35 -0700 (PDT) Received: from claudiu-X670E-Pro-RS.. ([82.78.167.171]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-427a5e77488sm121546145e9.9.2024.07.16.03.30.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Jul 2024 03:30:35 -0700 (PDT) From: Claudiu <claudiu.beznea@tuxon.dev> X-Google-Original-From: Claudiu <claudiu.beznea.uj@bp.renesas.com> To: lee@kernel.org, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org, alexandre.belloni@bootlin.com, geert+renesas@glider.be, magnus.damm@gmail.com, mturquette@baylibre.com, sboyd@kernel.org, p.zabel@pengutronix.de Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-rtc@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org, claudiu.beznea@tuxon.dev, Claudiu Beznea <claudiu.beznea.uj@bp.renesas.com> Subject: [PATCH v2 00/11] Add RTC support for the Renesas RZ/G3S SoC Date: Tue, 16 Jul 2024 13:30:14 +0300 Message-Id: <20240716103025.1198495-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-20240716_033037_800115_430C937D X-CRM114-Status: GOOD ( 19.67 ) 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-03/11). Patches 04-05/11 add the RTC driver. Patches 06-09/11 update the device trees with proper nodes to enable RTC. Patches 10-11/11 enable proper config flags for RTC to work on RZ/G3S SoC. Thank you, Claudiu Beznea 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 (11): dt-bindings: mfd: renesas,r9a08g045-vbattb: Document VBATTB mfd: renesas-vbattb: Add a MFD driver for the Renesas VBATTB IP 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 clock arm64: dts: renesas: rzg3s-smarc-som: Enable RTC arm64: defconfig: Enable VBATTB arm64: defconfig: Enable Renesas RTCA-3 flag .../mfd/renesas,r9a08g045-vbattb.yaml | 136 +++ .../bindings/rtc/renesas,rz-rtca3.yaml | 69 ++ MAINTAINERS | 8 + arch/arm64/boot/dts/renesas/r9a08g045.dtsi | 43 + .../boot/dts/renesas/rzg3s-smarc-som.dtsi | 17 + arch/arm64/configs/defconfig | 3 + drivers/clk/renesas/Kconfig | 5 + drivers/clk/renesas/Makefile | 1 + drivers/clk/renesas/clk-vbattb.c | 212 +++++ drivers/mfd/Kconfig | 8 + drivers/mfd/Makefile | 1 + drivers/mfd/renesas-vbattb.c | 78 ++ drivers/rtc/Kconfig | 10 + drivers/rtc/Makefile | 1 + drivers/rtc/rtc-renesas-rtca3.c | 853 ++++++++++++++++++ 15 files changed, 1445 insertions(+) create mode 100644 Documentation/devicetree/bindings/mfd/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/mfd/renesas-vbattb.c create mode 100644 drivers/rtc/rtc-renesas-rtca3.c