From patchwork Wed May 17 14:41:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Romain Perier X-Patchwork-Id: 13245130 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 50C30C77B75 for ; Wed, 17 May 2023 14:42:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=nGQD2u9UKBeGS0xS/aMjHoMOGetPQf2t+gY4zWfju2Y=; b=4rERgOXB2IMofB Z0hD9uk/8gkhV1sjQ2ADgofgCpMVSzwITCHRC0DiEaqXIcJd+OuPNpJqphCU+qkOhIr4ZqwqhWlE8 dzrzBoi4mIlbOXYl6zltGXS4SsgXS0iYBaLGc3pQTgcsf5aX3n08SM+wwbJojmhAxBMY6bu6c8v6Z 3HgzjA9sjmwe/OC3HSLSLzDmSpEP3al7q27YsLbuUY37risGNt3HlMihSHUrRUH9a3cxlYpqpfinJ gRQkntdWUsvX8rQrTvedF/EPx1uDXfzc/HSaTvrf+Xx9lSrnlyk0XqklMPPK3TPDNjMgqQwSlCEkl awf9EQX1/iTNQeZAjn2g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pzILi-00AA5l-0Y; Wed, 17 May 2023 14:41:54 +0000 Received: from mail-wm1-x331.google.com ([2a00:1450:4864:20::331]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pzILf-00AA44-1m for linux-arm-kernel@lists.infradead.org; Wed, 17 May 2023 14:41:52 +0000 Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-3f42ba32e24so6183635e9.3 for ; Wed, 17 May 2023 07:41:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1684334508; x=1686926508; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=H+KC9aWhk9Nue79yWDp+sL63hK9fCcCnZcN242M9Snc=; b=Z7rx8NP8zxZZplHp9JQsq2SOrjhFUCJitdu6cYUYl/XuMw/gP2F8PdmUFww8IXUfN3 7sLXACqEfM48cfFpUGiQkUvCSEcGwjRhiv7Cjm4b9vTa8tuocSll8b3BAc0XPgWCMXsP Lem7kRo0en6+L6oScQiUVFRBwxS53wtDucriSCEF5EymACkM0VM933RuOyLZSMKena7I rwR7WRaBBvaSFMV0/0YOUUdg7qZT58/YKJtaPwvF3A/ww0IWz8t+7hzKtkDDICdTRrwo z7ctu/OczDbLtrZGEy8vcrhACOJ6/Q86Jp75A0KKa3MDFwDLnPM66ZmEOI6Pu4XV9xwA uinA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684334508; x=1686926508; 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=H+KC9aWhk9Nue79yWDp+sL63hK9fCcCnZcN242M9Snc=; b=AV6ksY6cgOU0E1qNgkr38IBxxDklz1aUSoQ7tDKAV8bXoe+miSZm518aoggH64AX0Q Pov3aanl5DIyRCA/mhnytA60I+U2/InC4v5lTdhg7YHKCA9GJ9iKn5pXAHuguEPism4Z kQ1sKDWqKc3Zqzeia7ymf0+w4rBzzfy//CLldAflHKl3uw/Hy49D5UlcRAAsE58LRVVD F90OfBOq8VTTQ1GvRaWMku4f6/Kh2kHRQ0y6u1w8CNUmvsJGmX7I7N9O+mu2i0bAr5c/ Tuc0ovTOuS9gRI+975jhCWMUTwF/j5qoLzcVzF/PDKcti5p12UVKXAjyTWoJy2flbgy7 LO8A== X-Gm-Message-State: AC+VfDyaWcsBR1zxk0nzyI4zfevN3Vrd8v/Y+BONHqon8Z09gMG0Zfsv Jr1eQDq8OrBhV3uTCHU+9ibqb0lX7zk= X-Google-Smtp-Source: ACHHUZ6r9JnZAqQ1Oxz0SzV4SQL/kRkz/ekqEeAXzPzAT7mGp3tOFwEX8x4W11EssaMrKUixYQ/2cQ== X-Received: by 2002:a7b:cd04:0:b0:3f5:d0ba:3c1a with SMTP id f4-20020a7bcd04000000b003f5d0ba3c1amr1387505wmj.4.1684334507898; Wed, 17 May 2023 07:41:47 -0700 (PDT) Received: from debby ([2a01:e0a:a6d:a8d0:7ff4:8f61:5574:9f95]) by smtp.gmail.com with ESMTPSA id v18-20020a1cf712000000b003edc4788fa0sm2536739wmh.2.2023.05.17.07.41.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 May 2023 07:41:47 -0700 (PDT) From: Romain Perier To: Alessandro Zummo , Alexandre Belloni , Daniel Palmer , Romain Perier , Rob Herring Cc: linux-rtc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH 0/3] Add RTC for MStar SSD20xD SoCs Date: Wed, 17 May 2023 16:41:41 +0200 Message-Id: <20230517144144.365631-1-romain.perier@gmail.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230517_074151_611691_C63CE65E X-CRM114-Status: GOOD ( 14.21 ) 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 This patches series adds a new driver for the RTC found in the Mstar SSD20xD SoCs. It adds a basic rtc driver, the corresponding devicetree bindings and its documentation. The rtctest (from selftests) has been passed on this driver, with the following output: # rtctest TAP version 13 1..8 # Starting 8 tests from 1 test cases. # RUN rtc.date_read ... # rtctest.c:52:date_read:Current RTC date/time is 17/05/2023 15:58:12. # OK rtc.date_read ok 1 rtc.date_read # RUN rtc.date_read_loop ... # rtctest.c:95:date_read_loop:Continuously reading RTC time for 30s (with 11ms breaks after every read). # rtctest.c:122:date_read_loop:Performed 888 RTC time reads. # OK rtc.date_read_loop ok 2 rtc.date_read_loop # RUN rtc.uie_read ... # rtctest.c:137:uie_read:skip update IRQs not supported. # OK rtc.uie_read ok 3 rtc.uie_read # RUN rtc.uie_select ... # rtctest.c:166:uie_select:skip update IRQs not supported. # OK rtc.uie_select ok 4 rtc.uie_select # RUN rtc.alarm_alm_set ... # rtctest.c:214:alarm_alm_set:skip alarms are not supported. # OK rtc.alarm_alm_set ok 5 rtc.alarm_alm_set # RUN rtc.alarm_wkalm_set ... # rtctest.c:274:alarm_wkalm_set:skip alarms are not supported. # OK rtc.alarm_wkalm_set ok 6 rtc.alarm_wkalm_set # RUN rtc.alarm_alm_set_minute ... # rtctest.c:324:alarm_alm_set_minute:skip alarms are not supported. # OK rtc.alarm_alm_set_minute ok 7 rtc.alarm_alm_set_minute # RUN rtc.alarm_wkalm_set_minute ... # rtctest.c:384:alarm_wkalm_set_minute:skip alarms are not supported. # OK rtc.alarm_wkalm_set_minute ok 8 rtc.alarm_wkalm_set_minute # PASSED: 8 / 8 tests passed. # Totals: pass:8 fail:0 xfail:0 xpass:0 skip:0 error:0 Romain Perier (3): rtc: Add support for the SSD20xD RTC dt-bindings: rtc: Add Mstar SSD20xD RTC devicetree bindings documentation ARM: dts: mstar: Enable rtc for SSD20xD .../bindings/rtc/mstar,ssd20xd-rtc.yaml | 37 +++ arch/arm/boot/dts/mstar-infinity2m.dtsi | 5 + drivers/rtc/Kconfig | 11 + drivers/rtc/Makefile | 1 + drivers/rtc/rtc-ssd20xd.c | 249 ++++++++++++++++++ 5 files changed, 303 insertions(+) create mode 100644 Documentation/devicetree/bindings/rtc/mstar,ssd20xd-rtc.yaml create mode 100644 drivers/rtc/rtc-ssd20xd.c