Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp3713875ybl; Mon, 3 Feb 2020 05:16:11 -0800 (PST) X-Google-Smtp-Source: APXvYqzDJ474TKjYmGIrffLIcJOStMEE0+u1Q45RtmkpCQE1d6CCuc/Gi6L3gHcBQ89oEw/QHjgc X-Received: by 2002:a54:4396:: with SMTP id u22mr14847247oiv.128.1580735771386; Mon, 03 Feb 2020 05:16:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1580735771; cv=none; d=google.com; s=arc-20160816; b=o6whkA8D1oLcCMmJyPHYfP1i9eUAZXmhThER8JfkpgodmGbI6CnEX6RQ7p0g9ieiUQ 0s6QJKwGQ83S5lyGmxXWDtQfYrRwa/CSB9wCR1fZ8mt+gGAtozrRCkuo6/wKrp7O7yIE u0t2e0VA/yApK6NioI7UHm7bGduPhlSWx7GAh2sOCXLhceJxMlwHag73cMMtsGg1du5K UULveoNGqs13+X0kGncMPMbF55KPguZBC7E+glJOHs74ow+KrzJvG8s9qUYVcNpyrjqm kjA4+vMS3uoSEgpwX26gODqYjbHpmjQDjYg90qTNnvaIAH7zs3M36jOBgCHB+AgE96As FuQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=uHq9fhw7QNVJhklhNpOI/KW9hh/uLCqY6eBhnwNF2yI=; b=mfgIEzcih+bCH97Xf/RWjHXw7rhDYppgl3u8B5XtIZCIy/F2CEtDaBCQGtiCiOFQ7H hqazJB8ddTYVXHacijfj+QCQ3l22nc0bS29zqJdA9DJYGK2zWDCkjiKpeCxkDhPonHXy /d+nuiuQBezIo2va+Eqb/jE8m1Xbj4CSKBu0it45tuke6arGSIswOdErx0rqaXnP/e0T EeTWyLNphsQD7+57wwYrfF/t8cPM4GNP/tmh7FXN9cK04zPcYVMwbdUK/lnlP95KMYkL lxSG8kxQLhrgUs0EnorFmL/ztiu8QqnB5dZpwqu0Vq9cpsZAtPh8+noI5LF3rmpXGe5a uPNQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=odfOm9jP; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=mediatek.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w13si9058986oti.291.2020.02.03.05.15.45; Mon, 03 Feb 2020 05:16:11 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=odfOm9jP; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=mediatek.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728096AbgBCLk6 (ORCPT + 99 others); Mon, 3 Feb 2020 06:40:58 -0500 Received: from mailgw01.mediatek.com ([210.61.82.183]:54147 "EHLO mailgw01.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1727999AbgBCLky (ORCPT ); Mon, 3 Feb 2020 06:40:54 -0500 X-UUID: 4cf3cf16e04a4cb7b29aced3b8fe21c7-20200203 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=uHq9fhw7QNVJhklhNpOI/KW9hh/uLCqY6eBhnwNF2yI=; b=odfOm9jP1R0A0Mfx93Jb9G20p1nQNn7wCBpYiD5/ks814DMxJuB4IcJVZs78g4ApNe1C24k0oOdui29096JMZSCIYdhnD7XWEexj2N58fslZDJCHv6Q+/N12GsBetROokam0Y3SBa+gTQD2SGC9MF5FbQR1gABjl88D3lMBq9AE=; X-UUID: 4cf3cf16e04a4cb7b29aced3b8fe21c7-20200203 Received: from mtkexhb01.mediatek.inc [(172.21.101.102)] by mailgw01.mediatek.com (envelope-from ) (Cellopoint E-mail Firewall v4.1.10 Build 0809 with TLS) with ESMTP id 2115809011; Mon, 03 Feb 2020 19:40:47 +0800 Received: from mtkcas07.mediatek.inc (172.21.101.84) by mtkmbs05n2.mediatek.inc (172.21.101.140) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Mon, 3 Feb 2020 19:40:01 +0800 Received: from mtksdaap41.mediatek.inc (172.21.77.4) by mtkcas07.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1395.4 via Frontend Transport; Mon, 3 Feb 2020 19:40:30 +0800 From: Hsin-Hsiung Wang To: Lee Jones , Rob Herring , Alexandre Belloni , Matthias Brugger CC: Mark Rutland , Eddie Huang , Sean Wang , Alessandro Zummo , Hsin-Hsiung Wang , Richard Fontana , Greg Kroah-Hartman , Josef Friedl , Thomas Gleixner , Ran Bi , Frank Wunderlich , , , , , , Subject: [PATCH v8 4/5] rtc: mt6397: Add support for the MediaTek MT6358 RTC Date: Mon, 3 Feb 2020 19:40:43 +0800 Message-ID: <1580730044-30501-5-git-send-email-hsin-hsiung.wang@mediatek.com> X-Mailer: git-send-email 2.6.4 In-Reply-To: <1580730044-30501-1-git-send-email-hsin-hsiung.wang@mediatek.com> References: <1580730044-30501-1-git-send-email-hsin-hsiung.wang@mediatek.com> MIME-Version: 1.0 Content-Type: text/plain X-MTK: N Content-Transfer-Encoding: base64 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org RnJvbTogUmFuIEJpIDxyYW4uYmlAbWVkaWF0ZWsuY29tPg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