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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2ECBAC64EC7 for ; Tue, 14 Feb 2023 20:28:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230511AbjBNU2V (ORCPT ); Tue, 14 Feb 2023 15:28:21 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41594 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229519AbjBNU2Q (ORCPT ); Tue, 14 Feb 2023 15:28:16 -0500 Received: from gate2.alliedtelesis.co.nz (gate2.alliedtelesis.co.nz [IPv6:2001:df5:b000:5::4]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EF15A2117 for ; Tue, 14 Feb 2023 12:28:11 -0800 (PST) Received: from svr-chch-seg1.atlnz.lc (mmarshal3.atlnz.lc [10.32.18.43]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by gate2.alliedtelesis.co.nz (Postfix) with ESMTPS id 34C5F2C049F; Wed, 15 Feb 2023 09:28:07 +1300 (NZDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alliedtelesis.co.nz; s=mail181024; t=1676406487; bh=TWH7FnO5GnYIvoj94ZOGxzzer8JFIRkc8T6x0kyy7os=; h=From:To:CC:Subject:Date:References:In-Reply-To:From; b=eD/DWdoc7cszNp8qplT8WIQuTK6mckY1ClQBTlacUVrSwYUn5SQ2CGmFAo8xt+JCD TbKJ3Nl0Pkc4f89hOWMxUGWZHopI/VhDIeDl3z4y2Dkt5Xhg9tN7fehhQNcl80H5+E Q/sK82YcxortpPvCgk8S7DLvLMR7XhOMTD8JSPMari1DLlIT9hhOBRWO/cVxPWY1Zq jLQc1H7NRvks1guW8E6HwSNIU9b7HAUgFh09OpGcO3oniR5GUkUPdhnqUSc0i068Uh D6cIshb44FDkooCb4nKrF+5yzq1KtpYQNX9HN1/Qsm9luHjD188TkCPo7h68+5z+38 RnediwpHWVlHg== Received: from svr-chch-ex1.atlnz.lc (Not Verified[2001:df5:b000:bc8::77]) by svr-chch-seg1.atlnz.lc with Trustwave SEG (v8,2,6,11305) id ; Wed, 15 Feb 2023 09:28:07 +1300 Received: from svr-chch-ex1.atlnz.lc (2001:df5:b000:bc8::77) by svr-chch-ex1.atlnz.lc (2001:df5:b000:bc8::77) with Microsoft SMTP Server (TLS) id 15.0.1497.45; Wed, 15 Feb 2023 09:28:06 +1300 Received: from svr-chch-ex1.atlnz.lc ([fe80::409d:36f5:8899:92e8]) by svr-chch-ex1.atlnz.lc ([fe80::409d:36f5:8899:92e8%12]) with mapi id 15.00.1497.045; Wed, 15 Feb 2023 09:28:06 +1300 From: Chris Packham To: Ibrahim Tilki , "a.zummo@towertech.it" , "alexandre.belloni@bootlin.com" , "jdelvare@suse.com" , "linux@roeck-us.net" , "robh+dt@kernel.org" , "krzysztof.kozlowski+dt@linaro.org" CC: "linux-rtc@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-hwmon@vger.kernel.org" , "devicetree@vger.kernel.org" , "Zeynep Arslanbenzer" Subject: Re: [PATCH v3 1/2] drivers: rtc: add max313xx series rtc driver Thread-Topic: [PATCH v3 1/2] drivers: rtc: add max313xx series rtc driver Thread-Index: AQHZQLLY3ijYBbo43E6McZa87qvtIQ== Date: Tue, 14 Feb 2023 20:28:05 +0000 Message-ID: <68ddb833-f38e-a05b-82c4-ce12330410a5@alliedtelesis.co.nz> References: <20221108122254.1185-1-Ibrahim.Tilki@analog.com> <20221108122254.1185-2-Ibrahim.Tilki@analog.com> In-Reply-To: <20221108122254.1185-2-Ibrahim.Tilki@analog.com> Accept-Language: en-NZ, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-messagesentrepresentingtype: 1 x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [10.32.1.11] Content-Type: text/plain; charset="utf-8" Content-ID: Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-SEG-SpamProfiler-Analysis: v=2.3 cv=Iuhgj43g c=1 sm=1 tr=0 a=Xf/6aR1Nyvzi7BryhOrcLQ==:117 a=xqWC_Br6kY4A:10 a=oKJsc7D3gJEA:10 a=IkcTkHD0fZMA:10 a=m04uMKEZRckA:10 a=gAnH3GRIAAAA:8 a=EUnS9iOibDHuwtM9isgA:9 a=QEXdDO2ut3YA:10 a=oVHKYsEdi7-vN-J5QA_j:22 X-SEG-SpamProfiler-Score: 0 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org SGkgSWJyYWhpbSwNCg0KT24gOS8xMS8yMiAwMToyMiwgSWJyYWhpbSBUaWxraSB3cm90ZToNCj4g QWRkaW5nIHN1cHBvcnQgZm9yIEFuYWxvZyBEZXZpY2VzIE1BWDMxM1hYIHNlcmllcyBSVENzLg0K Pg0KPiBTaWduZWQtb2ZmLWJ5OiBJYnJhaGltIFRpbGtpIDxJYnJhaGltLlRpbGtpQGFuYWxvZy5j b20+DQo+IFNpZ25lZC1vZmYtYnk6IFpleW5lcCBBcnNsYW5iZW56ZXIgPFpleW5lcC5BcnNsYW5i ZW56ZXJAYW5hbG9nLmNvbT4NCj4gLS0tDQo+ICAgZHJpdmVycy9ydGMvS2NvbmZpZyAgICAgICAg fCAgIDExICsNCj4gICBkcml2ZXJzL3J0Yy9NYWtlZmlsZSAgICAgICB8ICAgIDEgKw0KPiAgIGRy aXZlcnMvcnRjL3J0Yy1tYXgzMTN4eC5jIHwgMTA3MCArKysrKysrKysrKysrKysrKysrKysrKysr KysrKysrKysrKysNCj4gICAzIGZpbGVzIGNoYW5nZWQsIDEwODIgaW5zZXJ0aW9ucygrKQ0KPiAg IGNyZWF0ZSBtb2RlIDEwMDY0NC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