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 7AE25D1F9D4 for ; Tue, 15 Oct 2024 21:14:11 +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:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date: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=1L+bz/3gjmWFZ4cYUg+/fV0wkJbeq2oELxyKeU0eEg0=; b=stTRJzp6Bb4Zw6vHERu154fhSz uHEd+gCRWKhmRzGtFUxPbxnM5rR4FQVywrpCbav7hbI6dRVrZOwZhneg5BozNspFuUjq8wh5U+s2d R3oD9E0vpqD+1zGxyLFhz5uZLG19byt82L3yYWmPbsWFS8LNy/JaTHpFtxy/y8cxqcJ35k1ouPgPs 0fsS21qSGeTWaW+iSQiNgatespx2Svwa8Atc9tTtj9Do5gHp514PeU5mqVwDSTCSOghU2Fq3sRMqs 7EN1XmdDbKcBH9afngQ+1whiolqjGDZ4VPR8hJ8L8n06IeQvobSKAiZHqcuby+jcDphYsFGSHOwFb QSvKwkvA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1t0ori-00000009beC-1OMr; Tue, 15 Oct 2024 21:14:02 +0000 Received: from nyc.source.kernel.org ([2604:1380:45d1:ec00::3]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1t0ois-00000009ZrH-3qXn for linux-arm-kernel@lists.infradead.org; Tue, 15 Oct 2024 21:04:56 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by nyc.source.kernel.org (Postfix) with ESMTP id E762FA434AB; Tue, 15 Oct 2024 21:04:44 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 63711C4CECF; Tue, 15 Oct 2024 21:04:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1729026293; bh=BUYL9DCxlqZBPQ7mv1XPuRWD5L3cs0jleTVBGzzkhXs=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=ttInMuNZhQyT9mQjpBo4HjV5z17nWbUD2dkhzKu3h2EinXQY2ATAebbICxfx/2YCN jAEZwj0XPLuLlgnqmUbIy4tOGdpdZkI2yGezk7iU3Sqrsu9R2L26xTRDOUh5yKvsPF 4Yh17X3w44S59uwHVfiRWnyuDwjNoMajzq5UrPNUy8fBy/BWug6K9Nzfa0m3uRlPU1 1iTw1uoysxPkNSnmApk6pglWHHrhNmNds/NLKI45iPoW/w2jtjR6BNJC/8+0HnCs8/ cdBhs7reBwKmaNPMeDhlaDJaLXbBDsn7KaHiKq8X7jD+7KfhgtJYvr61Azy2Iqm/Q/ vPBDqV8F5TzVg== Date: Tue, 15 Oct 2024 16:04:52 -0500 From: Rob Herring To: Ciprian Costea Cc: Alexandre Belloni , Krzysztof Kozlowski , Conor Dooley , Catalin Marinas , Will Deacon , linux-rtc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, NXP S32 Linux Team , Christophe Lizzi , Alberto Ruiz , Enric Balletbo , Bogdan Hamciuc , Ghennadi Procopciuc Subject: Re: [PATCH v2 2/4] rtc: s32g: add NXP S32G2/S32G3 SoC support Message-ID: <20241015210452.GA1942395-robh@kernel.org> References: <20241015105133.656360-1-ciprianmarian.costea@oss.nxp.com> <20241015105133.656360-3-ciprianmarian.costea@oss.nxp.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20241015105133.656360-3-ciprianmarian.costea@oss.nxp.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241015_140455_105968_612C93CD X-CRM114-Status: GOOD ( 19.94 ) 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 Tue, Oct 15, 2024 at 01:51:31PM +0300, Ciprian Costea wrote: > From: Ciprian Marian Costea > > Add a RTC driver for NXP S32G2/S32G3 SoCs. > > The RTC module is used to enable Suspend to RAM (STR) support > on NXP S32G2/S32G3 SoC based boards. > RTC tracks clock time during system suspend. > > RTC from S32G2/S32G3 is not battery-powered and it is not > kept alive during system reset. > > Co-developed-by: Bogdan Hamciuc > Signed-off-by: Bogdan Hamciuc > Co-developed-by: Ghennadi Procopciuc > Signed-off-by: Ghennadi Procopciuc > Signed-off-by: Ciprian Marian Costea > --- > drivers/rtc/Kconfig | 11 + > drivers/rtc/Makefile | 1 + > drivers/rtc/rtc-s32g.c | 778 +++++++++++++++++++++++++++++++++++++++++ > 3 files changed, 790 insertions(+) > create mode 100644 drivers/rtc/rtc-s32g.c > diff --git a/drivers/rtc/Makefile b/drivers/rtc/Makefile > index 8ee79cb18322..a63d010a753c 100644 > --- a/drivers/rtc/Makefile > +++ b/drivers/rtc/Makefile > @@ -158,6 +158,7 @@ obj-$(CONFIG_RTC_DRV_RX8025) += rtc-rx8025.o > obj-$(CONFIG_RTC_DRV_RX8111) += rtc-rx8111.o > obj-$(CONFIG_RTC_DRV_RX8581) += rtc-rx8581.o > obj-$(CONFIG_RTC_DRV_RZN1) += rtc-rzn1.o > +obj-$(CONFIG_RTC_DRV_S32G) += rtc-s32g.o > obj-$(CONFIG_RTC_DRV_S35390A) += rtc-s35390a.o > obj-$(CONFIG_RTC_DRV_S3C) += rtc-s3c.o > obj-$(CONFIG_RTC_DRV_S5M) += rtc-s5m.o > diff --git a/drivers/rtc/rtc-s32g.c b/drivers/rtc/rtc-s32g.c > new file mode 100644 > index 000000000000..d6502d8bf616 > --- /dev/null > +++ b/drivers/rtc/rtc-s32g.c > +static const struct of_device_id rtc_dt_ids[] = { > + { .compatible = "nxp,s32g2-rtc", .data = &rtc_s32g2_data}, > + { .compatible = "nxp,s32g3-rtc", .data = &rtc_s32g2_data}, Considering the data is the same and g3 has a fallback to g2 in the binding, you can drop this line. And really you don't need rtc_s32g2_data because there is only 1 possible value. But maybe you know some differences which are coming soon? Then it's probably okay. Up to the RTC maintainer though. Rob